Making antiX work better on hi-res 4K video machines to avoid microscopic fonts

Forum Forums General Hardware Making antiX work better on hi-res 4K video machines to avoid microscopic fonts

  • This topic has 65 replies, 9 voices, and was last updated Sep 20-6:54 am by Xecure.
Viewing 15 posts - 31 through 45 (of 66 total)
  • Author
    Posts
  • #45207
    Member
    Xecure
    Helpful
    Up
    0
    ::

    just use a proper distro with scaling if you have a capable machine.

    You mean “Just use a Desktop environment that supports scaling”. This is not distro related. Distros don’t manage this.

    After seeing your problems, BobC, I think I found the source. Anyway. I will be replacing xrandr scaling with the use of text DPI already set in antiX and maybe try adding GTK and QT scaling. Better use the already available tools, and make it easier to revert back to previous scaling.

    Sorry for the inconveniences.

    antiX Live system enthusiast.
    General Live Boot Parameters for antiX.

    #45209
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    I found that with 19.3 booted from flashdrive that it defaulted the fontsize to 2.0. Where I ran into trouble was that the grub, titlebar, taskbar, and menus appear very tiny, but the conky and desktop items are ok.

    I have been running it in 1920×1080 since I switched to antiX when it was pretty new about 3 years ago, but when it’s connected to the 4K big screen, the higher resolution could be nice to have.

    Thanks for helping. I don’t think it did so badly there, myself.

    #45220
    Member
    kksmith
    Helpful
    Up
    0
    ::

    just use a proper distro with scaling if you have a capable machine.

    You mean “Just use a Desktop environment that supports scaling”. This is not distro related. Distros don’t manage this.

    as if to imply sticking a full DE on antix, well there is MX already. carry on.

    #45224
    Member
    Xecure
    Helpful
    Up
    0
    ::

    as if to imply sticking a full DE on antix, well there is MX already. carry on.

    I think there are no distros with icewm that support HiDPI scaling. If one is accustomed to a working environment, they don’t always want to switch to a different one. If we can find a workaround, I think nobody will lose.
    I understand the easiest solution is to jump to a different environment, but that is not always what we want.

    Regards.

    antiX Live system enthusiast.
    General Live Boot Parameters for antiX.

    #45231
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    Running xrandr to change the scale in $HOME/desktop-session/startup fixed it for everything on the screen. My goal was not just to fix it on mine, but also to solve it so normal people don’t have initial problems with it.

    I LIKE antiX with IceWM. It’s very functional and responsive. I have tried many distros, desktops and window managers and the fancy one are very slow to the point where I worry something is broken. No, I don’t go on their message boards complaining, but I have no interest in running a pokey system every day. I have one very fast I7, and the rest of my systems are 12 to 23 years old and I like running the same desktop on all if possible.

    #45295
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    Thinking about it more, if we were to calculate the area of a 14 or 15″ screen, if the resolution is higher than 1080p (ie 1920×1080) on a screen that size, the characters get too hard to see. This could be calculated as dots per inch, and we could come up with a max value. Beyond that is when we should offer something more readable and offer to save it or run arandr for them so they can adjust it to their liking. And when they come out of arandr, offer to save the setting for them as their default. 4K resolution might not be a problem on a 55 inch screen.

    Just thinking aloud…

    #45299
    Member
    skidoo
    Helpful
    Up
    0
    ::

    food for thought: https://github.com/bbidulock/icewm/issues/288
    https://forums.bunsenlabs.org/viewtopic.php?id=3989

    vinzv created a set for bunsenlabs: gtk2+3 HiDPI theme based on greybird, conky scaled large, and a scaled tint2rc
    https://github.com/vinzv/bunsen-beam-hidpi

    opendesktop.org aka Pling (WAS box-look.org and similar websites) now has some HiDPI GTK2+3 themes available for download; one bragged about having “true fractional scaling” and (but, when I had looked) required a GTK3 version higher than what was currently available from debian sid repository.

    #45308
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    Thanks, skidoo, I hadn’t seen these:

    On the IceWM git thread, its interesting to see that the IceWM Devs were referring people to see how IceWM for HiDPI is done on antiX back in October. Maybe that is what instigated the 4K capability needs, LOL.

    On the tint2, note that he says “if xrandr doesn’t report the correct screen size, don’t use this”.

    on that vinzv site I see he wasn’t able to get LightDM to scale. I have that issue on my 4K machine.

    I like the idea of starting with a standard DPI and using a scaling factor to adjust everything. I needed to do a bunch of tweaking to get all the pieces of the different sizes to fit on my new theme. I would change one thing and something else wouldn’t fit.

    #45370
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    and so…. I downloaded and installed Fedora and Xbuntu.

    Well, I did TRY.

    I didn’t get Fedora installed. I got too scared with the disk paritioning stuff to be trying that on my main machine, but the screen was readable. They don’t include gparted, and it was very difficult to figure things out, and I tried anyway, but then it errored out not liking my UEFI setup and refusing to fix it or install, so I gave up because I can’t be risking that system.

    I did get Xbuntu installed, but what fun that was in 3840×2160 and no menu to change anything. I used my phone camera in zoomed in mode to read the options until the battery ran low and then used my trusty 5x magnifying glass. After installing which went well otherwise, its still in 3840×2160.

    #45372
    Member
    skidoo
    Helpful
    Up
    0
    ::

    Sept 2020 http://dev1galaxy.org/viewtopic.php?id=3798

    keep in mind that you are probably trying to scale 3 different GUI toolkits: GTK2, GTK3, and Qt5.

    GTK2 does not have any builtin HiDPI settings. There are a some pretty good HiDPI hacks that work ok for GTK2 though.
    GTK3 applications do NOT scale very well (my opinion). As you have already noted GTK3 will only scale with an integer value. (Correction: GTK3 can scale fonts using a non-integer relative to the currenly set ‘GDK SCALE’ value.)
    QT5 has the best scaling. It will scale to integer or non-integer values.

    Here is how I have manually set up the scaling for Qt5 and GTK3 Apps for my 4K Screen.
    All of the settings are in my ‘$HOME/.xsessionrc’ since I am currenly using an either JWM or Openbox.

    # GTK-3 Scaling
    GDK_SCALE=2 export GDK_SCALE
    GDK_DPI_SCALE=0.5 export GDK_DPI_SCALE

    $ Qt5 Scaling
    export QT_AUTO_SCREEN_SCALE_FACTOR=0
    export QT_SCREEN_SCALE_FACTOR=2.0
    export QT_SCALE_FACTOR=1.9
    #

    Those settings achive pretty good results.

    Here is a good reference: https://wiki.archlinux.org/index.php/HiDPI

    #45373
    Member
    skidoo
    Helpful
    Up
    0
    ::

    Sept 2020
    http://dev1galaxy.org/viewtopic.php?id=3847
    Head_on_a_Stick sez:

    try using an X.Org configuration file to set the display size and DPI: https://wiki.archlinux.org/index.php/Xorg#Display_size_and_DPI

    Run the xdpyinfo command from an unscaled desktop to find the default values.

    [..]
    example:

    # /etc/X11/xorg.conf.d/00-monitor.conf
    Section "Monitor"
       Identifier "eDPI"
       DisplaySize 508 286
    EndSection

    Use xrandr to find the correct Identifier for your monitor (listed as “connected”) and replace 508 286 with the actual horizontal and vertical dimensions of the screen (in millimetres). You will also need to specify the font size in ~/.Xresources:
    Xft.dpi: 140

    #45387
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    I will have put in some time it looks. I finally was able to install fedora by adding an external hard drive and letting it do an automatic install to it, but afterwards it got one dot and a blinking dash on a black screen, no grub. It looks like I will need to replace an internal disk drive to install it. Supposedly it can run IceWM. I’ve spent 4 hours so far trying to get it installed.

    #45401
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    I got it running on Fedora. There were some surprises there. They use Plymouth and Wayland. I didn’t figure out how to scale the screen, and wasn’t able to get it working on my 4K video machine except from flashdrive due to the UEFI errors.

    #47812
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    Well, I had some good success with Xecure’s script on one screen, and tweaked it to handle more when it needed to be rescaled, but then after I got that working, I ran into more problems when I tried testing how it would run automatically at the boot.
    1. conky goes off the screen and turning it on/off doesn’t reposition it
    2. screen background zooms in x 4 I think, but I only see 1/4 of the picture. Changing to another background leaves me with the same problem looking at the top left corner of that background.

    I tried Set Font DPI, and it adjusts all displays, which is a problem when you have displays that are different.

    I think a simpler solution might be good enough. I know how to recognize based on xrandr pixels/mm over 8 when its going to be hard to read, so maybe the solution is if I see that situation, give the user the option to run arandr. I tried it manually, and the other programs look normal that way if I restart the session afterwards.

    I will finish the code to do that tonight and let others try it. Not many people have multiple HiDPI systems, so I think what’s important is that it work without trouble on normal systems, and try to assist a little by noticing there is a problem, and giving the option to run arandr to adjust the resolution if a problem is found, or let them say ok, and it leaves it alone.

    #47902
    Moderator
    BobC
    Helpful
    Up
    0
    ::

    I tried many solutions, and decided that the best solution was to notice if there was a small HiDPI display, and if yes, and DPI had not been overridden already, then pop up a box to give the user a change to run set-dpi or not, and provide a hint of what to do, as well as explain that the font size could also be changed at boot or via set-dpi. Because this is called by ~/.desktop-session/startup and it restarts the desktop at the end if set-dpi is run, it also needs to avoid running again that second time.

    Also included in the startup script is the internet connection detection and helper to start wifi and bring up connnman if not connected already, which runs after the HiDPI screen detection.

    What the program does not do is to handle a HiDPI setup with multiple displays at different scale factors, but I would doubt there are many besides me with that kind of setup. It shouldn’t bother anyone else other than to check the screen resolution vs size in mm and exit.

    Could anyone here please try it? Also, let me know if you do have a small HiDPI screen (ie a laptop with 4K resolution set for default font size) that triggers it to try to help.

    PS: I didn’t localize the text yet in the script. I will do that if I know what file it goes into. I also am not sure that “autoscale-antix” is the right name for it, since we are only checking for small HiDPI screens, not rescaling them automatically. set-dpi is doing that part.

    • This reply was modified 11 months, 1 week ago by BobC.
Viewing 15 posts - 31 through 45 (of 66 total)
  • You must be logged in to reply to this topic.