[vim/vim] GVim on Windows doesn't respond to scaling changes (#3102)

244 views
Skip to first unread message

Bohr Shaw

unread,
Jun 25, 2018, 10:33:43 PM6/25/18
to vim/vim, Subscribed

I switch between two HiDPI displays and their scaling is different.
Unless I restart GVim, its scaling remains fixed after I switch displays.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub

K.Takata

unread,
Jun 25, 2018, 10:55:09 PM6/25/18
to vim/vim, Subscribed

On Windows?
Right, Vim doesn't support per-monitor DPI now.
I haven't checked how to support it.

K.Takata

unread,
Jun 25, 2018, 11:02:01 PM6/25/18
to vim/vim, Subscribed

On Windows?

Ah, you wrote that in the title.

Tetralux

unread,
Aug 27, 2019, 7:51:45 PM8/27/19
to vim/vim, Subscribed

Suffer from this too, on Windows x64.

My primary 1440p monitor is good, my 4k secondary monitor blurs.

This can be fixed by calling SetDPIAwareness(2) at init time and then responding to the appropriate window message by scaling fonts, window size etc.

I've never done it, but my 10 minute glance at it leads me to that.

Christian Brabandt

unread,
Aug 28, 2019, 2:16:16 AM8/28/19
to vim/vim, Subscribed

how about a PR then?

Dan Thompson

unread,
Mar 2, 2020, 3:27:19 PM3/2/20
to vim/vim, Subscribed

Documentation: https://docs.microsoft.com/en-us/windows/win32/hidpi/high-dpi-desktop-application-development-on-windows


You are receiving this because you are subscribed to this thread.

Reply to this email directly, view it on GitHub, or unsubscribe.

Esme

unread,
Dec 9, 2021, 8:27:51 PM12/9/21
to vim/vim, Subscribed

Manually enabling GDI scaling works well, per https://vi.stackexchange.com/questions/16622/how-to-adjust-gvim-to-my-hidpi-display-scaling-on-windows-10, perhaps you could simply enable this in an application manifest?


You are receiving this because you are subscribed to this thread.

Reply to this email directly, view it on GitHub.
Triage notifications on the go with GitHub Mobile for iOS or Android.

Christian Brabandt

unread,
Dec 10, 2021, 2:36:16 AM12/10/21
to vim/vim, Subscribed

so, how about a patch then?


You are receiving this because you are subscribed to this thread.

K.Takata

unread,
Dec 13, 2021, 4:08:24 AM12/13/21
to vim/vim, Subscribed

Enabling gdiScaling is just a workaround, I think.
The proper solution sould be to implement PerMonitorV2 support, but it might not be so easy.


You are receiving this because you are subscribed to this thread.

Bram Moolenaar

unread,
Jan 16, 2022, 9:16:34 AM1/16/22
to vim/vim, Subscribed

Closed #3102 via c81e9bf.


Reply to this email directly, view it on GitHub.
Triage notifications on the go with GitHub Mobile for iOS or Android.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issue/3102/issue_event/5900358390@github.com>

Reply all
Reply to author
Forward
0 new messages