Author Topic: New message editor always sets a font size  (Read 14484 times)

Tblue

  • Newbie
  • *
  • Posts: 9
New message editor always sets a font size
« on: April 01, 2018, 01:13:53 am »
Hi,

I am using AquaMail 1.14.2-840 on Android 7.1.1.

I noticed that when using the "new message editor" to compose rich text messages, AquaMail always sets a font size, even if configured not to:



That is, the HTML generated by the new editor erroneously contains an explicit font size:

Code: [Select] [nofollow]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
</head>
<body style="font-family: Arial, Myriad, 'Liberation Sans', sans-serif; font-size: 12pt;">
Rich text&nbsp;</body>
</html>

Clearing the formatting using the appropriate button in the editor does not help.

In contrast, the "old editor" (that you get when you uncheck the "New message editor" option) generates the following correct HTML, without any font size specifications, as configured:

Code: [Select] [nofollow]
<html>
<head>
<meta http-equiv="Content-Type" content="text/html"/>
</head>
<body>
<div style="color: black;">
<p style="margin: 0 0 1em 0; color: black;">Rich text </p>
</div>
</body>
</html>

It would be nice if this bug could be fixed. :) I'm currently working around it by using the old editor.

Thanks!

Kostya Vasilyev

  • Hero Member
  • *****
  • Posts: 12740
Re: New message editor always sets a font size
« Reply #1 on: April 01, 2018, 12:48:46 pm »
Yes it does, and font name too - without that, the formatting when replying would be inconsistent ("bug bug please fix").

"other apps" - e.g. Outlook - also set a default font name (not sure about size).

Consider:

<html><body>
Your new text
<div font name = Arial, font size = 12pt>
Original message
Perhaps more styling here
Different font sizes, styles, colors, etc.
</div>

The part with "your new text" would be rendered using browser's (or mail apps) default HTML styling. This varies from app to app, not just font name but also size.

And so we set our defaults so your message looks consistent.

I actually saw this issue comparing Office 365 web mail, Outlook for Windows, and another mail provider's web mail.

---

You called what the old editor does "correct" and called our current behavior "a bug".

Why?

What trouble does this cause you?

12 pt is pretty "standard" for "default font size".
Sans serif is pretty "standard" for "default typeface".

Creating debug logs for diagnostics: https://www.aqua-mail.com/troubleshooting/

The official FAQ: https://www.aqua-mail.com/faq/

Лог-файлы для диагностики: https://www.aqua-mail.com/ru/troubleshooting/

Вопросы и ответы: https://www.aqua-mail.com/ru/faq/

Tblue

  • Newbie
  • *
  • Posts: 9
Re: New message editor always sets a font size
« Reply #2 on: April 03, 2018, 01:22:56 am »
Thanks for your quick reply.

You called what the old editor does "correct" and called our current behavior "a bug".

Why?

What trouble does this cause you?

12 pt is pretty "standard" for "default font size".
Sans serif is pretty "standard" for "default typeface".

In my case, the issue is that Google Mail does not set a font size by default. So when somebody sends me a message written using GMail's web interface and I reply using AquaMail, then while the font size in my reply itself is consistent, it still is bigger than the font size of the message that I replied to. When viewing the mail thread in GMail, then my messages have a bigger font size than the others:



Also, I set the AquaMail setting "Rich text font size (when sending)" to "Default (do not set)". However, AquaMail still sets a font size. To me, that is a bug; if I choose "Do not set", then I do not expect AquaMail to set a font size.

If this is about sensible defaults, then why not set the "Rich text font size (when sending)" option to "12 pt" by default? Then users like me can still set it to "Default (do not set)" -- assuming that this really does not set a font size -- and be happy. :)

Kostya Vasilyev

  • Hero Member
  • *****
  • Posts: 12740
Re: New message editor always sets a font size
« Reply #3 on: April 03, 2018, 09:34:47 pm »
Because 12pt is a perfectly reasonable default.

Same with a sans serif font.

Didn't know about GMail's default font size - but then what about Outlook for Windows? Also a popular mail app.

Thunderbird? EmClient? Outlook for Mac? Mac Mail? IncrediMail? MailBird?

How confident are you that all these apps (just "desktop" apps) use the same default font size (or lack of) and default font name(s)?

And if not which one do we need to match?

---

Still, I did make the change to *not* set default size or typeface on our current 1.15-dev.

Not sure when I'm going to post this, but should be fairly soon (please keep an eye under "Development builds" here on the forum).

However if there are any issues with this, I'll revert the change and we'll set a font size / name again by default.
Creating debug logs for diagnostics: https://www.aqua-mail.com/troubleshooting/

The official FAQ: https://www.aqua-mail.com/faq/

Лог-файлы для диагностики: https://www.aqua-mail.com/ru/troubleshooting/

Вопросы и ответы: https://www.aqua-mail.com/ru/faq/

Tblue

  • Newbie
  • *
  • Posts: 9
Re: New message editor always sets a font size
« Reply #4 on: April 16, 2018, 12:06:43 am »
How confident are you that all these apps (just "desktop" apps) use the same default font size (or lack of) and default font name(s)?

And if not which one do we need to match?

I am not, and of course there is no way to know which font family or font size AquaMail needs to match (as we just saw with GMail).

I am completely fine with the default being 12 pt, though -- I would just like to have an option to not set any font size. That option does not need to be the default. Sorry if I was not being clear.

Quote
Still, I did make the change to *not* set default size or typeface on our current 1.15-dev.

Not sure when I'm going to post this, but should be fairly soon (please keep an eye under "Development builds" here on the forum).

However if there are any issues with this, I'll revert the change and we'll set a font size / name again by default.

Thanks! I will try it.
« Last Edit: April 16, 2018, 12:27:03 am by Tblue »

Kostya Vasilyev

  • Hero Member
  • *****
  • Posts: 12740
Re: New message editor always sets a font size
« Reply #5 on: April 17, 2018, 07:35:33 pm »
Since the change was made about two weeks ago - the current 1.15.0-dev builds should have it.
Creating debug logs for diagnostics: https://www.aqua-mail.com/troubleshooting/

The official FAQ: https://www.aqua-mail.com/faq/

Лог-файлы для диагностики: https://www.aqua-mail.com/ru/troubleshooting/

Вопросы и ответы: https://www.aqua-mail.com/ru/faq/

Tblue

  • Newbie
  • *
  • Posts: 9
Re: New message editor always sets a font size
« Reply #6 on: April 22, 2018, 02:59:38 pm »
I finally got a chance to test the change -- sorry that it took so long!

The message text itself now does not have a font size set anymore (thanks!), but AquaMail still sets a font size for the quoted text:


Kostya Vasilyev

  • Hero Member
  • *****
  • Posts: 12740
Re: New message editor always sets a font size
« Reply #7 on: April 22, 2018, 03:58:47 pm »
Yes it sets font size = 10pt on the "who wrote what and when" (just some styling so it's predictable) and and also a "style reset" around the whole original block, again so it has predictable styling (this includes size = 12pt).
Creating debug logs for diagnostics: https://www.aqua-mail.com/troubleshooting/

The official FAQ: https://www.aqua-mail.com/faq/

Лог-файлы для диагностики: https://www.aqua-mail.com/ru/troubleshooting/

Вопросы и ответы: https://www.aqua-mail.com/ru/faq/

mikeone

  • Hero Member
  • *****
  • Posts: 2767
Re: New message editor always sets a font size
« Reply #8 on: April 22, 2018, 04:33:07 pm »
Yes it sets font size = 10pt on the "who wrote what and when" (just some styling so it's predictable) and and also a "style reset" around the whole original block, again so it has predictable styling (this includes size = 12pt).
Is the information on the font size a contradiction or have I misunderstood something.

Kostya Vasilyev

  • Hero Member
  • *****
  • Posts: 12740
Re: New message editor always sets a font size
« Reply #9 on: April 24, 2018, 07:59:36 pm »
10pt for the "On April 22, John Smith wrote:"

And 12pt (by default) around the quoted / original text.

Why reset at all?

Because if a user has set a specific font size / color / typeface - he/she would not be expecting *original* messages (when replying / forwarding) to also take on those appearance settings.

And so, we wrap the original / quoted message in a div that resets the style to reasonable defaults.
Creating debug logs for diagnostics: https://www.aqua-mail.com/troubleshooting/

The official FAQ: https://www.aqua-mail.com/faq/

Лог-файлы для диагностики: https://www.aqua-mail.com/ru/troubleshooting/

Вопросы и ответы: https://www.aqua-mail.com/ru/faq/

mikeone

  • Hero Member
  • *****
  • Posts: 2767
Re: New message editor always sets a font size
« Reply #10 on: April 24, 2018, 09:55:40 pm »
Thanks for your brief explanation Kostya  :)

Tblue

  • Newbie
  • *
  • Posts: 9
Re: New message editor always sets a font size
« Reply #11 on: May 03, 2018, 12:55:45 am »
Yes, thanks for the explanation and for implementing the change! :)