Closed Bug 1270954 Opened 4 years ago Closed 4 years ago

Multi-dpi: Title bar is very large on a low dpi secondary monitor

Categories

(Core :: Widget: Win32, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla50
Tracking Status
firefox50 --- fixed

People

(Reporter: overholt, Assigned: jfkthame)

References

Details

Attachments

(2 files)

Attached image illustrative screenshot
It seems like at least Sublime gets this right. See attached screenshot.
I think you'll find that Sublime is not supporting per-monitor dpi, it's rendering at the system dpi and then Windows up- or downscales the result on monitors with a different resolution.

Current Win32 APIs do not support proper scaling of the window title bar (and borders) on a secondary display. (There's new API coming in a future Windows update that will enable us to fix this.)
(In reply to Jonathan Kew (:jfkthame) from comment #1)
> I think you'll find that Sublime is not supporting per-monitor dpi, it's
> rendering at the system dpi and then Windows up- or downscales the result on
> monitors with a different resolution.

I see.

> Current Win32 APIs do not support proper scaling of the window title bar
> (and borders) on a secondary display. (There's new API coming in a future
> Windows update that will enable us to fix this.)

Oh, I'm surprised. Thanks for the info!

Do we have another bug I should dupe this to?
Flags: needinfo?(jfkthame)
I'm not sure we have an open bug about this, so I'll mark this one as blocking bug 890156.

We won't be fixing it for the time being, as it's behaving as designed (what were they thinking?!) for now, but once the new Windows API is available we'll be able to move forward here.
Blocks: 890156
Flags: needinfo?(jfkthame)
This enables window title bars to be scaled properly for secondary monitors. (Currently requires Windows Insider build, until the Anniversary Update ships to end users next month.)
Attachment #8771003 - Flags: review?(VYV03354)
Assignee: nobody → jfkthame
Status: NEW → ASSIGNED
Comment on attachment 8771003 [details] [diff] [review]
When Win10 Anniversary Update APIs are available, enable automatic scaling of the non-client area when a window is on a secondary display with different DPI

\o/
Attachment #8771003 - Flags: review?(VYV03354) → review+
Keywords: checkin-needed
Marked checkin-needed, as inbound is currently closed. No try run because this is about fixing behavior on Win10 Anniversary Update, which we don't have running in automation (it's not even generally released yet).
Fx48 is due to be released around the same time as the Anniversary Edition. Should we consider uplifting this?
Flags: needinfo?(jfkthame)
I'm intending to request aurora-49 uplift once this is safely in Nightly; I'm inclined to think that it's not sufficiently critical to justify a beta uplift at this stage in the cycle (compare also bug 1254026).
Depends on: 1254026
Flags: needinfo?(jfkthame)
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/b1d95b24cade
When Win10 Anniversary Update APIs are available, enable automatic scaling of the non-client area when a window is on a secondary display with different DPI. r=emk, a=kwierso
Keywords: checkin-needed
Comment on attachment 8771003 [details] [diff] [review]
When Win10 Anniversary Update APIs are available, enable automatic scaling of the non-client area when a window is on a secondary display with different DPI

The upcoming Windows 10 Anniversary Update will make it possible to fix this "misfeature" (limitation) of the initial Windows mixed-dpi support. With the Windows update due to ship in August, IIUC, it would be good to get this into FF49 rather than waiting for FF50 to improve our user experience.

Approval Request Comment
[Feature/regressing bug #]: Win10 per-monitor-dpi support

[User impact if declined]: window title bars mis-sized on secondary monitor with different DPI

[Describe test coverage new/current, TreeHerder]: tested manually (requires mixed-dpi config)

[Risks and why]: minimal, no effect except on mixed-dpi Windows systems

[String/UUID change made/needed]: n/a
Attachment #8771003 - Flags: approval-mozilla-aurora?
https://hg.mozilla.org/mozilla-central/rev/b1d95b24cade
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla50
Depends on: 1289143
Comment on attachment 8771003 [details] [diff] [review]
When Win10 Anniversary Update APIs are available, enable automatic scaling of the non-client area when a window is on a secondary display with different DPI

Cancelling approval-aurora request for now; I'm not sure we want to push this out until we've resolved bug 1289143.
Attachment #8771003 - Flags: approval-mozilla-aurora?
Duplicate of this bug: 1259700
This problem only appeared at Version 47 which seems at variance to Jonathan's first comment (Jonathan Kew (:jfkthame) 2016-05-06 14:05:05 PDT). However, maybe it appeared because a different API was first used in version 47 to draw the Firefox windows. FYI.
BTW, this problem is still not fixed as at version 47.0.1.
Depends on: 1302168
You need to log in before you can comment on or make changes to this bug.