Description
Describe the bug
The docs and code suggest that specifying a font's size using the h
parameter (e.g. :se gfn=ProFont:h9
) describes the font's height in pixels. This does not appear to be the case. Depending on the display's DPI, a given font size will yield significantly different results. This happens regardless of the system display resolution as reported by xdpyinfo
.
My guess is the problem lies in the Skia library, since Neovide doesn't appear to determine display DPI, nor make adjustments to the user's requested font sizes.
To Reproduce
Steps to reproduce the behavior:
- Find two Linux machines with significantly different DPI displays.
- Launch Neovide on each.
- Set
gfn
on each machine/display to the same font face and size. - The rendered glyphs will be of different pixel dimensions, depending on actual display DPI.
Expected behavior
The rendered fonts should be of the same pixel dimensions, regardless of display DPI; or at least respect the user-specificed DPI in the system preferences. (If you want font size described in a resolution-independent manner, then you should have a different specifier (p
?) to describe the font's size in points.)
Screenshots
All windows used the font Iosevka Extended.
h9
on a 109 DPI display:
h6
on a 145 DPI display:
h5
on a 210 DPI display:
For reference, here's the Kitty terminal emulator, with font_size 5
on a 210 DPI display. It looks exactly as tiny on the other DPI displays as well:
Desktop (please complete the following information):
- OS: Debian Sid (unstable)
- Neovide 11.0 and 11.1
- Neovim 0.9.1
Please run neovide --log
and paste the contents of the .log
file created in the current directory here:
neovide_rCURRENT.log
Additional context