Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scaling factor #55

Open
adamdama opened this issue Feb 23, 2024 · 1 comment
Open

Scaling factor #55

adamdama opened this issue Feb 23, 2024 · 1 comment

Comments

@adamdama
Copy link

We are experimenting with delivering Flutter apps to Tizen based TVs. During our exploration we found that the app is being scaled up by a factor of 1.6 which seems to be coming from this code:

double scale_factor = dpi / 90.0 * kProfileFactor;

This is making our app elements look too big even though the window size is correct at 1920 x 1080.

Is there a recommended approach to adjusting this scale in the Flutter app globally? Or do we need to adjust the widget and height of every widget when deployed to Tizen?

@swift-kim
Copy link
Member

As far as I remember, the DPI came from the TV UI design guideline, so the scale factor (pixel ratio) has a constant value regardless of the screen size. You may find the widgets too big if you have a large screen TV. All other built-in apps should follow the same design guidelines and therefore have the same look and feel. Maybe I need to check out the latest guidelines again.

This issue and the workaround suggested by ardera may help, but it doesn't seem to work as desired in all cases. The easiest way would be to build the embedder by yourself by adjusting the hardcoded value. You will need a Linux machine or WSL, or you can even use the GitHub Actions CI if you don't want to set up the build environment locally. Otherwise we can consider adding a dedicated API to the C# embedding but the implementation may take some time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants