jkanev / treetime

TreeTime is a data organisation, management and analysis tool. A tree is a hierarchical structure that arranges information in units and sub-units. TreeTime uses linked trees (one data item can be part of different distinct trees) to store and organise any general purpose data.
https://github.com/jkanev/treetime/blob/master/README.md
GNU General Public License v3.0
44 stars 5 forks source link

No UI scaling #6

Closed coldsobolev closed 4 months ago

coldsobolev commented 5 months ago

it frequently occurs that someone is unable to read the content of the main window when someone is sharing their screen or something. there has to be a button that rescales the whole UI.

jkanev commented 4 months ago

Thanks for noting (indeed!), and thanks for your fix. I'll leave the issue open until the next release with the fix in it.

jkanev commented 4 months ago

For the moment the increase/decrease buttons only work for the Fusion theme. The other themes only scale the GUI, but not the font, probably due to CSS overrides of the font in the theme (ignoring the font-size settings by the Qt setFont function).

coldsobolev commented 4 months ago

it doesn't seem as straightforward as you described. on a setup of mine with kvantum as the default theme, scaling works out of the box, even for other themes like windows and fusion, once i switch to organic, scaling no longer works for any of the themes even after switching back to them

coldsobolev commented 4 months ago

https://github.com/jkanev/treetime/assets/168366420/7285b019-8ff7-4367-90bd-3240be802c67

jkanev commented 4 months ago

That's because the Organic them overlays everything with CSS definitions. Which in turn is because Qt doesn't provide a way to change drawn icons (like the tree unfold arrows) using pure method calls. The last commit (9e993c08) changed the zoom control to a slider now (for optics), and slightly changed the calls: the buttons are now scaled when creating the objects, and the tree view tabs are scaled indiviually. Changing the zoom also forces a re-draw of the data area. This fixes it (at least on my setup :) ). Also changed: To be consistent with other text and spread sheet processors, only the data view scales, while the main UI buttons stay the same.

coldsobolev commented 4 months ago

thx for the fix, works on my machine as well. smooth slider btw. closing issue.