Cope with changed font size #114

Closed
opened 2022-01-16 22:40:40 +00:00 by rz · 20 comments

Hi, I use systemwide settings to increase the font size - Settings/Display & brightness/Font & display size -> large

This completely messes up the layout of the app. I would not mind if the app would just ignore the system wide setting.

Hi, I use systemwide settings to increase the font size - Settings/Display & brightness/Font & display size -> large This completely messes up the layout of the app. I would not mind if the app would just ignore the system wide setting.

Hi @rz 👋

I'm a happy daily user of the app and looking forward to help you with this feature request.

As noted above I started looking into this. Please feel free to contribute to my PR.


Could you please provide a few more details to ease the further investigation of this issue?

app version

android device

  • In the past many issue have been caused by restrictions of certain android versions or device manufacturers. Informations about the device your using might help @Starfish to further investigate this issue

Regards,

Jean-Luc

Hi @rz :wave: I'm a happy daily user of the app and looking forward to help you with this feature request. As noted above I started looking into this. Please feel free to contribute to my PR. ------- Could you please provide a few more **details** to ease the further investigation of this issue? **app version** - [x] I guess your using release [0.57.3](https://codeberg.org/Starfish/TinyWeatherForecastGermany/releases/tag/0.57.3) from [codeberg.org](https://codeberg.org/Starfish/TinyWeatherForecastGermany/releases) or the [F-Droid](https://kaffeemitkoffein.de/fdroid) repository by @Starfish. Or did you get it from the official [F-Droid](https://f-droid.org/en/packages/de.kaffeemitkoffein.tinyweatherforecastgermany/) repository? **android device** - [x] In the past many issue have been caused by restrictions of certain **android versions** or **device manufacturers**. Informations about the device your using might help @Starfish to further investigate this issue Regards, Jean-Luc

thanks for your efforts. I use the latest version from f-droid.org, 0.57.3

The device is a Realme 8 with Android 11 and I would be happy to test your patch

thanks for your efforts. I use the latest version from f-droid.org, 0.57.3 The device is a Realme 8 with Android 11 and I would be happy to test your patch
Starfish added the
bug
enhancement
labels 2022-01-23 16:54:22 +00:00
Starfish self-assigned this 2022-01-23 16:54:30 +00:00

I did look into this and it is not that bad. I admit that I never tested the app for other font sizes than the default system setting.

I went trough the views and my findings are:

  • the main app view (the AdapterView) is messed up because a) items overlap b) item hight is broken, meaning that some items might dissapear at the bottom.
  • the text forecasts look ok
  • the weather warnings look mostly ok, there are some minor layout issues in the AdapterView
  • the widgets are ok, provided you resize them manually to reflect the font size change.

I should be able to fix this without ignoring the global font size setting. Will adapt the layouts a little bit. I think ignorig it is bad practise regading the UI.

I did look into this and it is not *that bad*. I admit that I never tested the app for other font sizes than the default system setting. I went trough the views and my findings are: * the main app view (the AdapterView) is messed up because a) items overlap b) item hight is broken, meaning that some items might dissapear at the bottom. * the text forecasts look ok * the weather warnings look mostly ok, there are some minor layout issues in the AdapterView * the widgets are ok, provided you resize them manually to reflect the font size change. I should be able to fix this without ignoring the global font size setting. Will adapt the layouts a little bit. I think ignorig it is bad practise regading the UI.

The Clock & Weather widget looks messy on my device and resizing does not help.

The Clock & Weather widget looks messy on my device and resizing does not help.

@rz can you post a sceenshot how it looks like?

@rz can you post a sceenshot how it looks like?
There is no content yet.

@rz thanks for the picture 👍

I experienced similar issues on some of my devices in the past. But removing and re-adding the widgets did fix it for me so far.

Hope this might work for you.

@Starfish might be able to share further insights based on the underlying code of the widgets.

@rz thanks for the picture 👍 I experienced similar issues on some of my devices in the past. But removing and re-adding the widgets did fix it for me so far. Hope this might work for you. @Starfish might be able to share further insights based on the underlying code of the widgets.

I will fix this in one of the future releases. However, likely not in the next one.

I will fix this in one of the future releases. However, likely not in the next one.

Fixed for all the widgets: 25f21b02d5 6ed1d6bb9f 8f94b9bdaf 82f8482458

Fixed for all the widgets: https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/25f21b02d5624087f7f30ca2c552eaf73da3b321 https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/6ed1d6bb9f3fe61ea8116066fac290fb7f6d53f2 https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/8f94b9bdaf36e6c6768d501aa0c41a38b88efc71 https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/82f848245848bdc20a35cf69df3e9a41fa0667f5

Fixed for the main app view: 859fa34443

Fixed for the main app view: https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/859fa344434457695ebf347f95461f4db5557ba5

Now also adapted the TextForecastViewActivity layout: 7493663381

The weather warnings look ok.

Everything is done, so I will close this issue. Please report if any broken layouts remain.

@eUgEntOptIc44 : #115 will remain closed because I accomplished the task by correcting some layouts and making some adaptions to dimen.xml.

Doing it programatically is probably a bad idea, because I doubt it would work with the widgets.

Now also adapted the TextForecastViewActivity layout: https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/74936633811cce3bfac0646b9c724906a83b8a70 The weather warnings look ok. Everything is done, so I will close this issue. Please report if any broken layouts remain. @eUgEntOptIc44 : #115 will remain closed because I accomplished the task by correcting some layouts and making some adaptions to dimen.xml. Doing it programatically is probably a bad idea, because I doubt it would work with the widgets.

...and, in a lot of cases, you can keep "sp".

...and, in a lot of cases, you can keep "sp".

@Starfish thank you very much for your insights on this. 👍 I'm always keen to learn about new stuff.

I'm looking forward to testing the upcoming release. Is there already an ETA for this to share with us?

@Starfish thank you very much for your insights on this. 👍 I'm always keen to learn about new stuff. I'm looking forward to testing the upcoming release. Is there already an ETA for this to share with us?

I'll make a userdebug today, still need to do some work regarding warnings in widgets and notifications about weather warnings.

There is one trick regarding the sp value: you can also set onther views that highly depend upon font size to sp instead of dp. 😄 Like icons, but also some parent views. You'll notice that now almost all icons also scale with system-wide font size changes. 😄😄😄

At the end, I had to force dp over sp in very few places only.

From a user perspective, it is simply better to use sp rather than dp whenever possible, so that the user feels comfortable with the font size.

I'll make a userdebug today, still need to do some work regarding warnings in widgets and notifications about weather warnings. There is one trick regarding the sp value: you can also set onther views that highly depend upon font size to sp instead of dp. 😄 Like icons, but also some parent views. You'll notice that now almost all icons also scale with system-wide font size changes. 😄😄😄 At the end, I had to force dp over sp in very few places only. From a user perspective, it is simply better to use sp rather than dp whenever possible, so that the user feels comfortable with the font size.

I've compiled an userdebug.

Any feedback is very much appreciated. Please note that I still need to test all the views regarding display densities.

Everything is not yet guaranteed to look perfect on all devices. 😄

I've compiled an [userdebug](https://kaffeemitkoffein.de/nextcloud/index.php/s/4SXHaLxLSmFd8Ri). Any feedback is very much appreciated. Please note that I still need to test all the views regarding *display densities*. Everything is not yet guaranteed to look perfect on all devices. 😄

Happy 🥳 to share first tests on AndroidX86 (Android 9 running on x86 architecture) using latest user debug build:

test weather warning in notification center

small widget on home screen featuring orange weather warning

Font size is looking perfect. Increased readability by a lot for me. Just the log text view seems not to be following suit. But this is rather low-prio because it's still readable.

Widgets all look great 👍

Happy :partying_face: to share first tests on AndroidX86 (Android 9 running on x86 architecture) using latest user debug build: ![test weather warning in notification center](https://codeberg.org/attachments/912b5834-1923-496c-9afc-1b365c3624dd) ![small widget on home screen featuring orange weather warning](https://codeberg.org/attachments/4a512b5e-5731-4845-8e29-4dfaa93b2739) Font size is looking perfect. Increased readability by a lot for me. Just the log text view seems not to be following suit. But this is rather low-prio because it's still readable. Widgets all look great 👍

Yes that is true, did not take care of the logs...

Yes that is true, did not take care of the logs...

Yes that is true, did not take care of the logs...

no worries. As this is (presumably) of rather low priority to the majority of the users I think that hardly anyone else notices that.


I also translated the new strings (required for the weather warnings) to French, German and Italian. Should be pushed by weblate soon.

> Yes that is true, did not take care of the logs... no worries. As this is (presumably) of rather low priority to the majority of the users I think that hardly anyone else notices that. ------ I also translated the new strings (required for the weather warnings) to French, German and Italian. Should be pushed by weblate soon.

Just noticed about the strings, was wondering why German was at 100% 👍 , then I have seen you already translated them :-) Thanks!

Fixed logs: 3d9a5ca66b

Just noticed about the strings, was wondering why German was at 100% 👍 , then I have seen you already translated them :-) Thanks! Fixed logs: https://codeberg.org/Starfish/TinyWeatherForecastGermany/commit/3d9a5ca66b860a3e8ad944030e80f1d4f698c1e5

I've compiled an userdebug.

Great thanks. Might be a good idea to use a distinct package name for that so that users of F-Droid can install it without uninstalling the app from F-Droid first. Also, it is frequently a good idea to test a fresh installation and stable and testing version in parallel.

Looks much better, some issues are left:

  • the introduction on fresh installation is slightly mangled, "SKIP" and "NEXT" are in unusual places.
  • something is wrong with "Enter place here:" no matter where I touch can't enter anything. I got around it by using find by location in settings
  • "large" widget as well as "Clock&Weather" are created very small, need to be expanded by hand
  • all widgets are 100% translucent totally ignoring opacity setting
> I've compiled an [userdebug](https://kaffeemitkoffein.de/nextcloud/index.php/s/4SXHaLxLSmFd8Ri). Great thanks. Might be a good idea to use a distinct package name for that so that users of F-Droid can install it without uninstalling the app from F-Droid first. Also, it is frequently a good idea to test a fresh installation and stable and testing version in parallel. Looks much better, some issues are left: * the introduction on fresh installation is slightly mangled, "SKIP" and "NEXT" are in unusual places. * something is wrong with "Enter place here:" no matter where I touch can't enter anything. I got around it by using find by location in settings * "large" widget as well as "Clock&Weather" are created very small, need to be expanded by hand * all widgets are 100% translucent totally ignoring opacity setting
Sign in to join this conversation.
No Milestone
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Starfish/TinyWeatherForecastGermany#114
There is no content yet.