large GUI fonts in some QT applications.

Everything about X, Gnome, KDE, ... and everything running on it

large GUI fonts in some QT applications.

Postby diniwed » 2018-02-19 20:57

I intermittently use such applications as frescobaldi, TeXstudio etc. and I noticed that the "GUI fonts" (the ones in menus, sidebars, and other "decorations"...) have grown very large - c. 4 times the height/width they are in other applications.

This has happened fairly recently and after doing some research I am under the impression that this may be related to current versions of these applications (as shipped by debian stable - STRETCH) are using the new Qt5 toolkit that among other things would appear to address issues relative to the introduction of the new "very" high resolution displays.

With previous Qt versions a "Qt config" tool was provided that let you set a session-wide font size. From what I read here, there and everywhere, there is no such tool for Qt5... nor will there ever be one.

A possible workaround that I found unofficially advertised in various forums & wikis would appear to consist in setting an environment variable that globally scales all applications by a given factor, such as:

$ QT_AUTO_SCREEN_SCALE_FACTOR=0 frescobaldi 0

This variable appears to have changed name(s) at least twice... the sample above being to the best of my knowledge the latest brew.

Apart from the fact that I do not want to "scale" my display... just change the size of my "GUI" fonts... I must say that in my case... setting this variable to a value such as .5 (e.g.) does not work. In other words I am only able to make the fonts larger... not smaller.

I use neither of the popular DE's such as gnome/kde/xfce and this may have some be related.

I have lived with this annoyance for ~6 months so I guess is I could live with it for a bit longer. So this is not such a big deal at this point... although I prefer working on a "clean" desktop rather than the mess I now see. My main concern is that other Qt5 applications such as the okular pdf viewer that I use on a regular basis will eventually be affected.

I was wondering if anyone else is having this issue with something comparable with my laptops display resolution of 1920x1200, ~130 dpi and if they have found a workaround.

Thank you for your continued support of Joe User in these troubled times.

CJ
diniwed
 
Posts: 6
Joined: 2017-09-16 18:51

Re: large GUI fonts in some QT applications.

Postby debiman » 2018-02-20 09:04

are these applications all qt4, or all qt5, or something else?
maybe this can be helpful: https://wiki.archlinux.org/index.php/Qt
User avatar
debiman
 
Posts: 3008
Joined: 2013-03-12 07:18

Re: large GUI fonts in some QT applications.

Postby Innovate » 2018-02-21 22:25

diniwed wrote:I intermittently use such applications as frescobaldi, TeXstudio etc. and I noticed that the "GUI fonts" (the ones in menus, sidebars, and other "decorations"...) have grown very large - c. 4 times the height/width they are in other applications.

This has happened fairly recently and after doing some research I am under the impression that this may be related to current versions of these applications (as shipped by debian stable - STRETCH) are using the new Qt5 toolkit that among other things would appear to address issues relative to the introduction of the new "very" high resolution displays.

With previous Qt versions a "Qt config" tool was provided that let you set a session-wide font size. From what I read here, there and everywhere, there is no such tool for Qt5... nor will there ever be one.


I've gotten one. Is this what you're looking for?

Image Image Image
Innovate
 
Posts: 174
Joined: 2015-12-27 01:28
Location: /dev/urandom

Re: large GUI fonts in some QT applications.

Postby diniwed » 2018-02-23 20:12

Thanks for pointing me in the right direction...

The application on the screenshots is qt5ct.

It is only available as a package in debian testing (buster) and sid... not debian stable (stretch). As of today the package is not in stretch/backports either.

I had given it a try some time ago but I ran into problems compiling from source. Since your screenshots looked rather promising I decided to give it another shot. This time I was successful.

One needs to do the following in debian/stretch (stable):

1. download the qt5ct zip file from github (click on the green "clone or download" button -> choose download zip file)

2. compile and install:

$ unzip qt5ct.zip
$ cd qt5ct-master
$ qmake PREFIX=/usr/local
$ make
# make install

• Check the README file in the qt5ct-master directory for a list of dependencies.
• I had to install the qtbase5-private-dev package... otherwise the make step fails
• Depending on your permissions (in my example you need write access to /usr/local) you may have to su to root or use sudo to run the make install command successfully...

3. set up the environment:

Before you run qt5ct and affected Qt5 applications you must set the following environment variable:

$ export QT_QPA_PLATFORMTHEME=qt5ct

The simple way to do this is to add the command to ~/.bash_profile and log out of your session and log back in.

4. run qt5ct and change the font and font size to your liking.

5. test

I checked the following Qt applications: okular, sigil, frescobaldi, kfontview, calibre, texstudio, lyx and everything looked OK.

Thanks again... can't tell you what a relief it is to have my desktop back to its normal state.

Priceless!

CJ
diniwed
 
Posts: 6
Joined: 2017-09-16 18:51

Re: large GUI fonts in some QT applications.

Postby stevepusser » 2018-02-23 22:18

It's actually a piece of cake to backport this package from upstream: https://wiki.debian.org/SimpleBackportCreation
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Quod Libet 4.2.0, Pale Moon 28.1.0, wine-staging 3.19, GIMP 2.10.8, Liquorix kernel 4.18-21, CopyQ 3.7.0
User avatar
stevepusser
 
Posts: 10119
Joined: 2009-10-06 05:53

Re: large GUI fonts in some QT applications.

Postby diniwed » 2018-02-23 23:32

Line one of the document:

"Please keep in mind that this is meant as a quick howto for how to build private backports and is not the way we expect from official backports for backports.debian.org. "

What is needed for those who like me are frankly allergic to so-called DE's aka gnome, kde, et al. is an official backport.

Something you can apt-get install in a jiffy and forget about…

This document is really about creating your own personal debian package and integrating it to your distro as opposed to the "rogue" compile-from-source procedure.

I've done that in the past for stuff where I needed to patch the source for my own needs and thanks to debian's rock-solid packaging system it did turn out to be a "piece of cake".

Having the backports maintainers actually create the backport making sure that it agrees with just about everyone's setup and add the package to their repository is a different matter.

But I'm not holding my breath.… this is only a small but (rather indispensable in my case) utility that I don't see catching the fancy of a "backporter" any time soon…!

The fact that buster, the current testing flavor of debian ships qt5ct is probably quite sufficient where I am concerned considering this is my home machine.

I just need to make a note that I have this non-official compiled version of qt5ct in /usr/local and get rid of it before I do my next dist-upgrade.

Come to think of it… I could probably remove it from my system right now… now that I have made my changes I am not likely to touch it again in the foreseeable future.

CJ
diniwed
 
Posts: 6
Joined: 2017-09-16 18:51

Re: large GUI fonts in some QT applications.

Postby stevepusser » 2018-02-24 00:07

My intent was to show how one can often solve compilation problems like the one you said you encountered, simply by using the packaging system to backport a program not yet in your release. The unofficial package you get is very likely to be the same as an offical backport...there's no magic fairy dust that gets added to the official one.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Quod Libet 4.2.0, Pale Moon 28.1.0, wine-staging 3.19, GIMP 2.10.8, Liquorix kernel 4.18-21, CopyQ 3.7.0
User avatar
stevepusser
 
Posts: 10119
Joined: 2009-10-06 05:53


Return to Desktop & Multimedia

Who is online

Users browsing this forum: No registered users and 8 guests

fashionable