It’s been some time since I worked with Qt’s HIDPI support, but I don’t think there’s a way to work purely in the screen pixel dimensions like I think you can in the win32 api. What you can do is render into a pixmap at the higher resolution and then paint that pixmap to the screen.
Qt implements HIDPI support through the device pixel ratio, which is the ratio of device independent coordinates to device pixels. On macOS this is typically 2.0, meaning a 200x200 device independent square renders as a 400x400 pixel square on the screen. Taking a 200x200 device independent square as an example — to draw at the higher 400x400 resolution, create a 400x400 QPixmap, set the devicePixelRatio to 1.0 and draw. Then to render to the screen, set the devicePixelRatio to 2.0 and paint the pixmap to the screen. This is what we’ve done to render high dpi icons.
I’m willing to do some experiments to try to render lines and other elements at HIDPI, but it’s been some time since I’ve worked with the core drawing code so would appreciate some pointers. Also is there a test case that shows the problem, preferably on macOS?
Thanks,
John
> --
> You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
scintilla-inter...@googlegroups.com.
> To view this discussion visit
https://groups.google.com/d/msgid/scintilla-interest/bd785523-13d2-4356-8e36-7b21322c073dn%40googlegroups.com.