resources: main: Correctly scale and wrap text in slider items#12
resources: main: Correctly scale and wrap text in slider items#12mschwan-phytec merged 3 commits intomainfrom
Conversation
Shrink the default window size to 640x480 pixels allowing smaller displays to correctly display the application. Signed-off-by: Martin Schwan <m.schwan@phytec.de>
Use the full, correct scheme for loading the resource in FontLoader. Signed-off-by: Martin Schwan <m.schwan@phytec.de>
| text: icon | ||
| color: PhyTheme.teal1 | ||
| font.family: icons.font.family | ||
| font.pointSize: Math.max(0.05 * parent.width, 48) |
There was a problem hiding this comment.
This icon feels too small for me. I would leave it as it is.
| color: PhyTheme.white | ||
| font.pointSize: Math.max(0.015 * parent.width, 24) | ||
| Layout.alignment: Qt.AlignHCenter | ||
| Layout.fillWidth: true |
There was a problem hiding this comment.
There was a problem hiding this comment.
I should have mentioned that I plan to use Qt's global scaling mechanisms to adjust the application's font sizes, instead of manually tweaking each label. This has also the benefit of other elements and controls scaling proportionally.
Could you try running qtphy with QT_SCALE_FACTOR=2 and see if that looks better?
There was a problem hiding this comment.
I've also changed the cards' name label styling to use horizontalAlignment: Text.AlignHCenter as you suggested, and applied HTML header styling to it. That should do the trick without worrying about exact font sizes.
There was a problem hiding this comment.
Please refetch the latest changes and test again.
40ba4c1 to
acb1a28
Compare
Correctly scale and wrap the text in the main page's slider items. Also prevent the items' header text from being elided. This text should be always readable. Only the longer description text may be elided. Signed-off-by: Martin Schwan <m.schwan@phytec.de>
acb1a28 to
29d3688
Compare
|
Using this scale factor is fine for scrolling through the tiles, but also every page gets scaled. On some pages this means that they are not really useable. Did you also notice this? |
|
What do you mean by "not usable"? Can you give an example? I observed that the image viewer displays the actual images a little too small and the device information does not allow scrolling. Do you mean something like that? |
|
I see. The correct way to solve this would be to create our own QML style with adjusted paddings and sizes. Unfortunately, for the i.MX8M release we won't be able to fix this in time. Before the i.MX93 release we will also try and fix this. But for now, is it okay, if we merge it as is? |
andrejpicej
left a comment
There was a problem hiding this comment.
I think it is okay for now. And lets finalize the scaling stuff before the next i.MX93 release






Correctly scale and wrap the text in the main page's slider items. Also prevent the items' header text from being elided. This text should be always readable. Only the longer description text may be elided.
Shrink the default window size to 640x480 pixels allowing smaller displays to correctly display the application.