Aven on hiDPI screens

Olly Betts olly at survex.com
Mon Sep 6 00:26:59 BST 2021


On Sun, Sep 05, 2021 at 10:44:50PM +0100, Wookey wrote:
> I now have a HiDPI screen: 3840x2160 and 344mm x 194mm or about 283DPI
> (or 11 dots per mm).
> 
> This has caused many applications to become extremely hard to use due
> to unreadable text and tiny icons. Aven is one of them. I have got
> java, and GTK apps as well as the desktop and terminal stuff to work
> adequately, but I can't work out what is needed for wxGTK apps like aven.

Since 1.2.42, aven deliberately disables HiDPI scaling:

| + (Unix version): Disable scaling for HiDPI displays with GTK3.  The OpenGL
|   code needs work before this will work usefully, so just disable for now
|   (which simulates how things are when using GTK2).

> Has anyone found out how to make the aven text a readable size on such
> displays? (menu items, icons, the survey tree and labels are all very
> tiny).

IIRC before this, the survey pane was drawn at half the height and half
the width (or presumably whatever fraction corresponds to the HiDPI-ness
factor of your display), so while you probably had more readable text in
menus, etc, around the edge of the window, the very important bit in the
middle was rather broken.

> Ideally just setting the X DPI would make everything DTRT, but it
> doesn't. Clearly far too many things are actually specified in pixels,
> not sizes.

It's probably to do with the sizing and scaling of the OpenGL pane, but
ideally it needs someone with an HiDPI display to sort it out.

See src/aven.cc for the current bodge:

    setenv("GDK_SCALE", "1", 1);

If you comment that out and rebuild, you'll hopefully see the problem.

(It may be that there are wxWidgets issues too.  I think their
development release series has seen more hidpi patches than 3.0.x, but
3.1.x is not ABI stable so not suitable for Debian, etc.  I've been
nudging them to actually start a new stable release series, but don't
seem to want to, preferring to promote the idea of a development release
people should use in production.)

Cheers,
    Olly



More information about the Survex mailing list