themix-project / oomox-gtk-theme

Oomox-gtk-theme is a fork of Numix-gtk-theme with slightly different visual design choices and more customization capabilities. It can be used in Themix/Oomox app.
https://github.com/themix-project/oomox
GNU General Public License v3.0
42 stars 8 forks source link

gtk2 pre-scale #5

Open actionless opened 6 years ago

actionless commented 6 years ago

From @kindlychung on April 5, 2017 11:20

According to Arch linux wiki:

Scaling of UI elements is not supported by the toolkit itself, however it's possible to generate a theme with elements pre-scaled for HiDPI display using oomox-gitAUR.

How does one pre-scale elements in oomox?

The HiDPI option doesn't have much of an effect: http://i.imgur.com/Hd2hNDT.png

Copied from original issue: actionless/oomox#82

actionless commented 6 years ago

you can find out widget class of that panel in inkscape and add a rule for it to this file: https://github.com/actionless/oomox/blob/master/src/gtk-2.0/gtkrc.hidpi

this tool should be helpful: https://chipx86.github.io/gtkparasite/

actionless commented 6 years ago

also icon sizes could be overriden by you settings manager, here is an example of how it's done in xsettingsd:

Gtk/IconSizes "panel-menu=40,40:panel=40,40:gtk-menu=24,24:gtk-large-toolbar=40,40:gtk-small-toolbar=40,40:gtk-button=24,24"
actionless commented 6 years ago

if there are any volunteers to implement that pre-scaling here is an example: https://github.com/nana-4/Flat-Plat/pull/142

but in this case it will also take some effort to re-implement border radius option for buttons/inputs

smurphos commented 6 years ago

Have you ever considered doing away with a separate gtkrc.hidpi file and using multiple values based on %SPACING% calculated in change_color.sh to size elements in gtkrc?

actionless commented 6 years ago

yes but without scss that seems like quite a PITA, and so looking on the decreasing number of gtk2 apps on my desktop i've decided to give up on that