HTML text has bigger font-size in BrowserComponent in landscape mode

13 views
Skip to first unread message

P5music

unread,
Mar 13, 2021, 12:15:57 PM3/13/21
to CodenameOne Discussions
I would like to ask if anyone has experieced this.

I do not know if it is something that could dipend on my source code or not, although it should be not.

My app shows a HTML list of items inside a Browser component. The HTML is exactly the same when changing orientation.

On my Samsung A10 I experience that the landscape orientation shows bigger text, as you can see in the attached images.

In the simulator I have not such a thing.
Also on the emulator with a tablet skin it is not experienced.
But it happens on the emulator with a smartphone skin like Pixel3.

Does it make any sense?
Thanks
portrait.jpg
landscape.jpg

Shai Almog

unread,
Mar 13, 2021, 10:12:59 PM3/13/21
to CodenameOne Discussions
This seems to be a "Samsung thing" but I wasn't able to find hints of it. They're pretty awful with such "features".

Shai Almog

unread,
Mar 13, 2021, 10:13:54 PM3/13/21
to CodenameOne Discussions

P5music

unread,
Mar 14, 2021, 8:30:47 AM3/14/21
to CodenameOne Discussions
Nope,
as I said it happens only in landscape mode, however it was randomly also happening when changing orientation again.
I think it is fixed now.
It was caused by the BC not being reloaded and repainted after the rotation.
Now I perform a new setPage() and, when loaded, a repaint();
Maybe just the repaint() could work without loading again but I think it is better to reload so to refresh the HTMl content, that can be dynamic in listed items of my app.
Regards
Reply all
Reply to author
Forward
0 new messages