Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: How to define correct view to size of screen ?


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 2 - Last Post: Jul 29, 2017 9:53 AM Last Post By: Yilmaz Yoru
aidan levy

Posts: 31
Registered: 7/6/16
How to define correct view to size of screen ?  
Click to report abuse...   Click to reply to this thread Reply
  Posted: May 8, 2017 6:05 AM
I created Android application in RAD studio 10.1 and Master View is good enough to smartphones displays (4-5.5 inch). Now I want to make view for tablets. I used existing "Android 10" Tablet" view and corrected place of controls. I checked it on tablet and its good. But when I run my application on 4" phone I see that in IDE it have old correct places of control but on phone its moved like on tablet view !
It`s mean that FireMonkey selected not correct view to screen size. For 4" screen it must be Master View !
How to define correct view to size of screen ?
Gabriel GRIPARI

Posts: 24
Registered: 3/26/09
Re: How to define correct view to size of screen ?  
Click to report abuse...   Click to reply to this thread Reply
  Posted: May 28, 2017 2:41 AM   in response to: aidan levy in response to: aidan levy
Bonjour,

How to define correct view to size of screen ?

There is no magic solution.
The best way, is to put on your client a TScaleLayout, and populate it, with your visual objects.
TScaleLayout will keep the right proportion of your screen.
Of course, if your mobile is in vertical position, the screen could be nice, and when you turn it, in horizontal position, the screen will be proportionaly deformed, but all object will be on the screen.

If you want to do an application for any screen size, you have to define different bloc of properties.
Each objets must have a specific properties (X, Y, Size, ...). You can make some bloc for small screens, medium screen, and wide screen.
It's a big work.

Best regards

Gabriel
Yilmaz Yoru


Posts: 167
Registered: 1/1/03
Re: How to define correct view to size of screen ?  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 28, 2017 8:47 PM   in response to: aidan levy in response to: aidan levy
aidan levy wrote:
I created Android application in RAD studio 10.1 and Master View is good enough to smartphones displays (4-5.5 inch). Now I want to make view for tablets. I used existing "Android 10" Tablet" view and corrected place of controls. I checked it on tablet and its good. But when I run my application on 4" phone I see that in IDE it have old correct places of control but on phone its moved like on tablet view !
It`s mean that FireMonkey selected not correct view to screen size. For 4" screen it must be Master View !
How to define correct view to size of screen ?

If you don't want to scale your UI you can move all on a layout and align layout center may be u can add a good backgrund image

I recommend you to use more panels, layouts with aligns (top left, mid, bottom and client ). Client panels or layouts mostly have things to be scaled like images, maps etc. or detailed tables. So UI will be same except client side will be bigger in tablet.

If you want to scale as same as your design then you can use Layout1->Scale->X and Y in comparision with Screen->Width and Screen->Height

--
Best Regards
Dr. Yilmaz Yoru
Esenja Company
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02