Padding and Margin in Android studio

In this video, we can learn what is padding and margin? Both Padding and Margin are most important commonly used properties for spacing out elements in android. Padding is the space inside the border, between the border and the actual view’s content and Margins, are the spaces outside the border, between the border and the other elements next to this view.
– difference between padding and margin in android? Padding is for inside/within components and Margin is to be applied for the on-outside of the components.
– What is measurement difference between px, in, mm, dp, and sp? px- Pixels corresponds to actual pixels on the screen. in(Inches), mm(Milimeter), pt(Points)-based on the physical size of the screen. dp(Density Pixels)-based on the physical density of the screen, sp(Scale Pixels)

 


Leave a Reply

Your email address will not be published. Required fields are marked *