Adjust scaling factor in preferences

• Nov 10, 2016 - 17:13

From time to time there are support requests in the forum, where users (not me, Idon't have one;-) have trouble with the resolution on high resolution monitors, first of all with windows 10 and OSX Sierra ("icons are too small" and so on).

I know you can MuseScore start with -x option for scaling (which only affect the icons, not the font of the menu entries).

While we know too little about details of the monitors for a solution, I wonder if it would be useful (respectively possible) to have - in sense of usability - an option for adjusting the scaling factor (or dpi settings) in the "Preferences"

("Blender" seems to have something like that to adjust the dpi, when I understand this correct: https://wiki.blender.org/index.php/Doc:DE/2.6/Manual/Preferences/System.

Note ( wasn't aware of that): you can adjust in preferences the icon size (but an item for scaling factor could maybe useful), but maybe there could be something similar to Blender that is affect also the size of menu entries (in sense of changing the dpi solution). But I'm not a programmer ;-)


Comments

There are actually several different things going on here, let's not confuse them:

1) "-x" is the option I introduced for MuseScore 2.0 to scale "some" things in the interface - the things that were not scaling correctly on my fairly high DPI Linux system automatically :-). Some things were scaling correctly already becasue they were based on OS settings (eg, the font to use for text), others weren't; the "-x" fixes the latter while leaving the former alone. This is needed for any system with a high DPI (or, for that matter, with an especially *low* DPI).

2) Starting with MuseScore 2.0.3, we now *do* scale everything correctly according to what the system reports to us as the DPI of the monitor. So if the system reports your monitor DPI correctly, you no longer need "-x". Unfortunately, in some cases the resolution is *not* reported correctly,. so we scale to the wrong resolution. In these cases, you can use "-x" as a partial workaround, but it won't actually get it completely correct, because it was really designed to solve #1, and the set of things that don't scale correctly in this case is potentially different, depending on your OS etc.

3) A future version of MuseScore will support a new "-r" option that allows you to specify the actual monitor resolution and will thus get the scaling right.

4) Some OS's allow you to specify sizes for multiple application elements - potentially different sizes for menus versus dialog boxes versus palette names, etc. We should honor these.

5) There has also been a request to provide additional user level control of the sizes of various application elements, above and beyond merely correctly honoring the OS settings. We currently do this for "icon" sizes, which actually affect a non-obvious set of UI elements.

As far as I am concerned, if we implement #4, then #5 becomes much less important, and realistically, any such controls we did implement could just as easily be put in a configuration file , some new an "advanced configuration settings" dialog we periodically discuss adding, or even be done via the command line - it's not something average user would ever need to mess with.

However, given that the problem discussed in #2 is not likely to go away - some OS / hardware combinations are probably always going to not report DPI correctly - we should indeed provide a simple preference or other easy way of providing the same function as the "-r" option as per #3.

I can use the -x command line to increase the size of the icons. But, no help there with the text in the UI. It's way too small. I have a 25" HP monitor, Cinnamon 3.0.7 running on Ubuntu 16.10. However, if I run the Mate or XFCE4 desktops the UI text is fine.

In reply to by bvdp

The general text size for the UI should be taken directly from the application font size you have set in your window manager (eg, xfce or whatever you use). We don't scale the text because we assume the user is setting something in his overall window manager preferences that works across the board. But I believe there are some text elements that do require scaling due to how we do things internally. Try out a nightly build of 2.1 (see Downloads in menu at right of this page) and the "-D" option which allows you to specify an actual resolution in DPI (eg, 200, or whatever). For most people this should give better results than "-x". Not sure how this will play out for your case, though.

In reply to by Marc Sabatella

Using 2.0.3 and the -d option (note, not -D which isn't an option) I think the info you are requesting is:

DPI 72.000000
Information for screen: "HDMI-1"
Available geometry: 0 37 1920 x 1043
Available size: 1920 x 1043
Available virtual geometry: 0 37 1920 x 1043
Available virtual size: 1920 x 1043
Depth: 24 bits
Geometry: 0 0 1920 x 1080
Logical DPI: 96.1263
Logical DPI X: 96
Logical DPI Y: 96.2526
Physical DPI: 88.1969
Physical DPI X: 88.1881
Physical DPI Y: 88.2058
Physical size: 553 x 311 mm
Refresh rate: 60 Hz
Size: 1920 x 1080
Virtual geometry: 0 0 1920 x 1080
Virtual size: 1920 x 1080

Okay, I got 2.1.0 and tried again. Now, the new -D option works. But, to me, it's the same result as the old -x option: It increases the size of icons, but not the UI text which remains too small.

Thanks for the quick reply. I'm sure I'm not the only one with aging eyes :)

In reply to by bvdp

Right, "-D" is only an option for 2.1, which is why I recommended you try it. but as I said, it wouldn't normally affect most text.

Again, MuseScore should be honoring the application text size you have set in your window manager preferences. Meaning, text size in MsueScore should be the same as all other applications on your system? Are you saying this isn't the case? What window manager are you using? What text size do you have set? Can you post a screen shot showing how text looks in some other application compared to how it looks in MuseScore?

In reply to by Marc Sabatella

I've attached a screen shot showing a bit of Firefox, Clementine, the font settings dialog and Mscore. I think you should see that the menu line in mscore is about 1/2 the size of the other applications.

Again, this is on:

Ubuntu 16.10
Cinnamon 3.0.7

Same system running XFCE4 works fine.

I've not used the -D or -x options in the screen shots.

Hope this helps. Screenshot_2017-04-14_13-42-28.png

In reply to by Marc Sabatella

Yes, I think it's the scaling that doesn't work. Which is funny, since I thought that was applied on a system level, not per application.

The problem with simply changing the font size without scaling is that non-font elements are now to small ... in all applications.

Is mscore trying too hard to interpret the system font settings?

In reply to by bvdp

We only know what the Qt libraries we use depend on. We ask Qt for the application font size, and it tells us. Apparently it is not taking the scaling into consideration. I would think Qt would know to look at this additional factor without our having to do anything special, but maybe there is some way we are supposed to query it ourselves. Needs further investigation.

In reply to by kuwitt

Yes, this is the sort of thing we need to investigate further. We are already doing some of this, which is why we are able to correctly scale everything else in the UI according to the monitor resolution in the vast majority of cases (we have problems with multiple monitor setups, also TV sets connected by VGA, a few other corner cases here and there). Unfortunately, some of what we would need to do a better job isn't available in Qt 5.4, which is what we are using for MusEscore 2.x. Newer Qt features could be used in MuseScore 3.0, however.

In reply to by Marc Sabatella

Apparently, not news ... but I did try the appimage version of 3.0 and there is no difference in the presentation. I tried both -D and -x settings and they both increase the icon (gfx) sizes, but the text remains too small. I don't have time right now, but I suspect that using XFCE4 or probably anything other that Cinnamon will solve my problem. And all this is quite odd since Cinnamon, AFAIK, is based on QT just like mscore.

In reply to by bvdp

By using cinnamon could you try to run MuseScore from terminal with "QT_SCALE_FACTOR" before (for example "QT_SCALE_FACTOR=1 mscore" or "QT_SCALE_FACTOR=1.5 mscore" - not sure which values are possible/useful)?

Note: I think you've to install QT 5.6 before (or higher), when it isn't already installed.

In reply to by kuwitt

YES! That works perfectly. Just tried it with mscore 2.0.3 and my eyes thank you!

I'll have to play a bit with the setting value, but I just tried 1.5 and it works very nicely. At last I can read all those nice menus. Hopefully this doesn't break anything.

In reply to by Marc Sabatella

All I did was to add this to my ~/.profile (The .profile file in my home directory):

## This lets mscore (and other qt applications?) scale up properly
export QT_SCALE_FACTOR=1.5

Don't do this in .bashrc ... it will not apply the setting to menu started programs. Please don't ask how I figured that out :)

BTW, it also seems to fix some small font issues on other programs.

And, yes, no -x or -D required.

In reply to by Marc Sabatella

I suppose without the -x or -D option, but of course it's better if @bvdp answers this question himself/herself.

I tried the command without having a HiDPI monitor. Not sure if it works by using other OS too.

Maybe another useful link could be: http://stackoverflow.com/questions/32313658/qt-high-dpi-support-on-wind…

And it would be also interesting to know if there's the same behavior of other QT applications by using a HiDPI monitor.

Do you still have an unanswered question? Please log in first to post your question.