Closed Bug 1648987 Opened 6 years ago Closed 5 years ago

Incorrect scaling of window chrome in mixed DPI setup with font scale factor

Categories

(Core :: Widget: Gtk, defect, P3)

77 Branch
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: jeb, Unassigned, NeedInfo)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:77.0) Gecko/20100101 Firefox/77.0

Steps to reproduce:

Plugged in external monitor, the firefox dropdown menu is incorrectly scaled

Software:
Linux with Wayland
Fedora 32, Gnome Shell 3.36
Firefox 77.0.1 from official fedora repo's

Hardware:
Dell XPS 9300
Primary display: USB C 4k external monitor running at @ 100% (not 200%)
Secondary display: Built in laptop 4k panel @ 200%
Font scale factor = 1.2

Note:
On login the laptop panel is initially the primary display for a second (since thats how defaults to GDM) before apply the user settings and switching the external monitor to the primary display and the laptop panel to be the secondary display.

Actual results:

The dropdown firefox menu used the scaling (200%) from a secondary display (ie. the laptop screen).

Also select boxes 'in page' show correctly, but when clicking on them them dropdown itself is shown double sized the same as the firefox menu.

Selecting a file to attach (using the Gtk File open dialog) is shown correctly.

Expected results:

The firefox menu, and the dropdown select meu should have used the scaling from the monitor the window is on (ie 100%).

Also note, I've enabled WebRender via about:config - not sure if thats relevant?

Also just found right-click menu has the same issue?

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Widget: Gtk
Product: Firefox → Core
Attached image File Save dialog —

Looks like its also affecting the save dialog that pops up when you download a file

Priority: -- → P3

I think the Font scale factor = 1.2 and 100/200% screen scale may be the factor here.

Summary: Incorrect scaling of window chrome in mixed DPI setup → Incorrect scaling of window chrome in mixed DPI setup with font scale factor

Can you please try latest nightly from Mozilla? How-to is here:
https://fedoraproject.org/wiki/How_to_debug_Firefox_problems?rd=Bug_info_Firefox#Testing_Mozilla_binaries
Thanks.

Flags: needinfo?(jeb)

Nightly:
Ok, tried with nightly (./firefox from the downloaded tar?) and I cannot replicate it.

v77:
I've also created a new profile in v77 - this profile running with Basic compositor. Interestingly it was initially showing the correct scaling. If I maximise the window it is still correct. If I then fill half the screen, the scaling issue occurs.

The issue goes away again if I re-maximise, and re-appears if I go back to half width.

Presumably this is something which has already been fixed on master then?

Flags: needinfo?(jeb)

Just been trying nightly with WebRender enabled as well and cannot replicate the issue.

Can you please test latest nightly under Wayland? A new popup handling code landed there.
Thanks.

Please re-test with new nightly as it gets another popup fixes.
Thanks.

It'll be a few days before I can test this - I'll retest with nightly start of next week.

Ok, just tried the nightly - scaling of drop down menu(s), hover overs, and dialogs looks correct in both X11 and Wayland (though half size on HiDPI monitor) - thanks

Spoke to soon - the inspector appears to be scaling differently - guessing its not longer taking text scaling into account? Left hand window is the nightly

left hand is nightly with smaller inspector

Can you please re-test with latest nightly?
Thanks.

Flags: needinfo?(jeb)
Status: UNCONFIRMED → RESOLVED
Closed: 5 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: