Struggling with TeXmacs on 4k screen under Linux

I’m using TeXmacs under recent Manjaro Linux with a 4k monitor.

I use scaling of UI elements of 1.25 in KDE systemsettings, but this gives blurry fonts like in this example.

As you see UI fonts are ok, like “Author data”, but the rest seems blurry.

If I change UI scaling to 1.0 everything looks crisp, but that is no good setting to work with the monitor. Any ideas?

1 Like

Welcome, Ingolf! What version of TeXmacs are you using?

Have tried everything from 1.9.14 upwards. The picture is compiled from today’s git. The blurriness is the same for all of them.

Interestingly, I just gave it a long shot and tried slowphils Appimage from here https://download.opensuse.org/repositories/home:/slowphil:/texmacs-devel/AppImage/texmacs-latest-x86_64.AppImage and that is working. I guess there seems to be a problem with my system freetype library.

I’ve tried setting scaling to 125% on a 3200x1800 display, but I don’t see any blurring. This is on Fedora 33 with freetype 2.10.4.

What about setting the system scaling to 2.0 ? Does it improves the rendering?

No. Here is a side-by-side picture with the system Texmacs above and the AppImage version below. You have to open the image here to see, that the above image does raster the fonts poorly. On my screen you see it immediately.

Hi, TeXmacs is blurring in my Fedora 33(3840x2160, 150%, kde) and openSUSE(1080p, 125%, kde). Using the latest build from OBS and COPR. I’m try to find the problem.

The menu logo are also blur comparing with Ingolf.

It would be useful to know which versions of the Qt libraries TeXmacs is using. Also one could try the appimage if it is available.

@Ingolf I do not think freetype is the problem. Most probably some weirdness in the version of Qt TeXmacs is linked against, the appimage has its own version of the libraries. Can you check which is the version of Qt linked in the standard package?

1 Like

Both Fedora and openSUSE work with Qt 5.15.2.

The standard package in Arch/Manjaro is dynamically linked. Relevant portion from objdump:

NEEDED libfreetype.so.6
NEEDED libQt5PrintSupport.so.5
NEEDED libQt5Widgets.so.5
NEEDED libQt5Gui.so.5
NEEDED libQt5Core.so.5

And installed Qt version on the system is 5.15.2 (freetype 2.10.4 even if that might not matter).

Manually setting QT_SCREEN_SCALE_FACTORS to 1 from command line works around the problem by not scaling. That seems to be what the AppImage does as well.

2 Likes

export QT_SCREEN_SCALE_FACTORS =1 works for me! Thanks!

2 Likes

It would be useful to record this problem in the savannah bug tracker, I think the handling of HiDPI screens on Qt5 is still not ok. Alternatively one could try a build of TeXmacs with Qt4 if this is still possible.

I entered it into the bugtracker at savannah.

2 Likes

I also note that Wayland does a better job than X11(left is Wayland, both in 1080p 125% kde).

1 Like

This is interesting! (also to report on the bug report filed by @Ingolf). What about other programs, do they have the same problems? I wonder if we are doing something wrong or just there is a bug in the Qt library support for HiDPI (which is not so uncommon in my experience).

Firefox, telegram, kde applications are just fine. But Arduino-IDE is little blur.

The Appimage still uses Qt4.8, and no special Qt parameters are set to run it.
I can provide a Qt5 Appimage but I think it is built with Qt5.6 or 5.8, so as to be able to run on still supported LTS versions.

2 Likes

Sorry, what I meant was that the AppImage seems to use scaling 1.00 as well, i.e. ignore the different scaling factor of the desktop environment.