Closed Bug 1655279 Opened 3 years ago Closed 3 years ago

Fixed Width not working - take 3

Categories

(MailNews Core :: Composition, defect, P1)

x86_64
All

Tracking

(thunderbird_esr78 fixed, thunderbird80 fixed)

RESOLVED FIXED
81 Branch
Tracking Status
thunderbird_esr78 --- fixed
thunderbird80 --- fixed

People

(Reporter: jorgk-bmo, Assigned: khushil324)

References

(Regression)

Details

(Keywords: regression)

Attachments

(3 files)

+++ This bug was initially created as a clone of Bug #1653545 +++
+++ This bug was initially created as a clone of Bug #1622231 +++

This is not fixed.

STR: Set "Fixed Width" as default composition font. Start a new e-mail.

Expected result:
E-Mail composed in "Fixed Width" <tt>.

Actual result:
"Fixed Width" is displayed, as soon as a character is entered, it jumps to "Variable Width". In tried in safe mode, there it jumps to "Variable Width" as soon as the body is focused.

Flags: needinfo?(khushil324)

(In reply to Jorg K (CEST = GMT+2) from comment #0)

+++ This bug was initially created as a clone of Bug #1653545 +++
+++ This bug was initially created as a clone of Bug #1622231 +++

This is not fixed.

STR: Set "Fixed Width" as default composition font. Start a new e-mail.

Expected result:
E-Mail composed in "Fixed Width" <tt>.

Actual result:
"Fixed Width" is displayed, as soon as a character is entered, it jumps to "Variable Width". In tried in safe mode, there it jumps to "Variable Width" as soon as the body is focused.

I am not able to reproduce this atleast on Trunk.

Flags: needinfo?(khushil324)

Video showing this is NOT working on Daily.

Maybe while you're here you can implement a test that sets the preference and then starts a composition, enters some text and checks for <tt> (or its future replacement). You can copy/paste such a test together out of existing pieces.

I can reproduce using 80.0a1 Build ID: 20200725105651 on Ubuntu 18.04.4 LTS.

Set Preferences > Composition, HTML Font to use Fixed Width.

Opened the composition window and as soon as I put the cursor into the body to start typing it switched to Variable Width. Typed a few letters and hit new line.

Selected Fixed Width for the next line, the text was typed in Fixed Width and all following text was typed in Fixed Width until I changed it again in the Formatting Bar.

HTH

Thanks, Walt, exactly what I observe. Starts working after manually selecting the font, well, <tt>.

#1 regression window(ux-mode-error : "Variable Width" is displayed in toolbar until you enter text in body of composition window. However, It changes to "Fixed Width" automatically after typing and the results is as expected)
https://hg.mozilla.org/comm-central/pushloghtml?fromchange=dd918656e4d7e4c79ebf44d9cb4e31eec406c1de&tochange=a96336115ce738cabc6bc86cb156067dd417e05f
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=b3ecb5aef45a8fb74764bb32e54567d57ed00383&tochange=6b93a83735ed3ab3b57b46c1b768814b1a1af5d6

#2 regression window(Even after you enter text in body of composition window, "Variable Width" is displayed in toolbar. And Bug 1622231 appears):
https://hg.mozilla.org/comm-central/pushloghtml?fromchange=f8a6cf1ee08f8223c36bb92414e29734d8d6c9d9&tochange=a9d1bbebb67f0407900127d2653e5d5656b0c4aa
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=e7163954456087c31980de0c22fba01096bfadd8&tochange=12d8255184b1015ff34f35c6fb040bbde6be2ed3

And after landing Bug 1622231, The behavior returns to state of #1 regression.

#3 regression window(#1 regression is unexpectedly fixed. however Bug 1653545 appears):
https://hg.mozilla.org/comm-central/pushloghtml?fromchange=b3eb5b294a0826a1843121fd21bd84a501863389&tochange=813ca5b455a81aa0d94b0ccc9e4d4f7261e45a8e
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=b2df79a80c0303df9d710800ae37dce56847eef5&tochange=590d76562067863dd840c9ff7cf85d5e8e2d6b4d

And after landing 1653545, we are facing the current behavior(i.e. Bug 1655279)

Assignee: nobody → khushil324
Attachment #9166172 - Flags: review?(mkmelin+mozilla)
Attachment #9166172 - Flags: feedback?(jorgk-bmo)

I have added the comment in the patch to highlight the problem.

Status: NEW → ASSIGNED
Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

Not 100% pretty, but works.

Please refer to bug 1590047 comment #4.
Attachment #9166172 - Flags: feedback?(jorgk-bmo) → feedback+
Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

Review of attachment 9166172 [details] [diff] [review]:
-----------------------------------------------------------------

Kind of works. 
But if I have a signature, I start and click that, then once clicking back to the first line I get variable width. 
Also seems if I delete everything on the first line, the menu pops back to variable, then when I start writing it does get the fixed width. But a bit odd behaviour.

(THis was tested with the preference of using body instead of p mode by default. Didn't check p mode yet)
Attachment #9166172 - Flags: review?(mkmelin+mozilla)

(In reply to Magnus Melin [:mkmelin] from comment #11)

But if I have a signature, I start and click that, then once clicking back
to the first line I get variable width.

That's "normal" behaviour. Clicking around the document loses the "type-in" state. Bug 1348750.

Also seems if I delete everything on the first line, the menu pops back to
variable, then when I start writing it does get the fixed width. But a bit
odd behaviour.

That's the Mozilla editor for you. Same in TB 68.

As far as I can see, the patch restores the previous behaviour. Unless someone has a better idea, we should take it.

Attachment #9166172 - Flags: review?(mkmelin+mozilla)
Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

Review of attachment 9166172 [details] [diff] [review]:
-----------------------------------------------------------------

I guess we can go with this for now, but make sure to rip it out going forwards.
Attachment #9166172 - Flags: review?(mkmelin+mozilla) → review+
Target Milestone: --- → 81 Branch

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/0dec1b640a4d
Fixed Width not working from the preferences setting. r=mkmelin DONTBUILD

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

[Approval Request Comment]
Regression caused by (bug #): 1582410
User impact if declined: User will not be able to set the fixed width font from the preferences.
Testing completed (on c-c, etc.): 
Risk to taking this patch (and alternatives if risky): Low.
Attachment #9166172 - Flags: approval-comm-esr78?

Any reason not to request beta uplift as well?

Sorry, missed it.

Attachment #9166172 - Flags: approval-comm-beta?
Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

[Triage Comment]
Approved for beta
Attachment #9166172 - Flags: approval-comm-beta? → approval-comm-beta+

Set Fixed Width in Composition preferences in the 80.0b2 release candidate on Ubuntu 18.04.4. Paragraph mode set.

Typed a line of text without a problem in Fixed Width.
Pressed Enter.
Selected Body Text and Variable Width for the next line.
Started typing and the Font selection changed back to Fixed Width.
I can select other fonts from the drop-down, just not able to change back to Variable width.
Is that expected?

Flags: needinfo?(rob)

Try TB 68 for comparison. I'll check it when I get back to my desk.

Blocks: 1658156

Thanks, Walt, this is not expected. I filed bug 1658156 for that. I didn't get regressed here, it's already broken in TB 78.1.1.

Flags: needinfo?(rob)

Comment on attachment 9166172 [details] [diff] [review]
Bug-1655279_fixed-width-not-working-from-pref-0.patch

[Triage Comment]
Approved for esr78

Attachment #9166172 - Flags: approval-comm-esr78? → approval-comm-esr78+

I'm using the fix in TB 78.1.? now. It's really quite wonky. If I start writing quickly into the body of a new message, I get the first few characters in variable width, and then it switches to fixed width.

For ESR, I think backing out bug 1582410 and all that came after would be the best bet, but then bug 1625218 will come back :-(

Blocks: 1658908
Blocks: 1658999
You need to log in before you can comment on or make changes to this bug.