In any screen sizes to build app in xamarin?

Warning: count(): Parameter must be an array or an object that implements Countable in /home/styllloz/public_html/qa-theme/donut-theme/qa-donut-layer.php on line 274
0 like 0 dislike
First encounter with Xamarin and mobile development.

Shoveled documentation and articles, this is what I get:

dp == width_in_px * 160 / dpi
Is the concept of Screen Density. For example, xhdpi, where 1dp == 2px
I installed Xamarin Live Player. Take your Ipad Air2.

In google I find out that dpi == 264px / inch. The resolution of 2048x1536px. Inserted into the formula and say:

width_in_dp == 2048 * 160 / 264. This equals to 1241.

Asked in AbsoluteLayout Label with the point 0 0 and width 1241px. Get a broader element.

Find device metrics from google, for ipad specified Screen Density xhdpi. Given the new information share and get 1024dp. And it fits.

And here's my question:

Why the first formula is incorrect, and on what basis are developed by Xamarin in terms of size? To display correctly on devices of different sizes?
by | 32 views

1 Answer

0 like 0 dislike
The dimensions that you use in Xamarin.Forms - values determined for the platforms of equal type size measurement. UWP is the Effective pixels, for iOS and Android Points to this Density-independent pixels.

A couple of links on this subject:

Work with dimensions
Image sizes
How to know the size in pixels on the platform to con...

Related questions

0 like 0 dislike
1 answer
asked May 21, 2019 by 1trofimov
0 like 0 dislike
1 answer
0 like 0 dislike
3 answers
110,608 questions
257,187 answers
40,796 users