Xamarin forms controls having the margin, padding, width and height property, how to convert this property values to pixel.
Already got some the reference link for converting db to px, but default xamarin form is px or db is the doubt?
public float convertDpToPx(Context context, float dp)
{
return dp * context.getResources().getDisplayMetrics().density;
}
And is it possible convert the width and height value to pixel in xamarin(uwp, Android and iOS)?
Thanks in advance.