jazzband / prettytable

Display tabular data in a visually appealing ASCII table format
https://pypi.org/project/PrettyTable/
Other
1.35k stars 154 forks source link

Sending a prettytable by email using Outlook doesn't keep format #239

Closed jifcon closed 1 year ago

jifcon commented 1 year ago

Hi everyone!

I'm trying to send a prettytable as email in outlook (through win32com package) and the table loses it's format (I send it as string using get_string()). I guess that the problem is that it's not using monospace but I'm not sure if it can be fixed.

I tried several options like ljust, center, rjust, using a fixed string length for every element but nothing works.

Do you have an idea on how to fix this?

I saw several posts about this issue with chinese chars but not with latin chars.

Thanks++!

JI

image

hugovk commented 1 year ago

Format it with a fixed-width font like Courier New.

But this is really a question for an Outlook forum, not PrettyTable :)