How to remove default layout's padding/margin

后端 未结 2 1867
渐次进展
渐次进展 2020-12-11 04:14

I have the following layout files:

activity_main.xml



        
相关标签:
2条回答
  • 2020-12-11 04:42

    Go into this file res/values/dimens.xml and change the values to 0dp just like in the code below.

    <dimen name="activity_horizontal_margin">0dp</dimen>
    <dimen name="activity_vertical_margin">0dp</dimen>
    

    0 讨论(0)
  • 2020-12-11 04:54

    I know this is already answered question but, i just come across such an issue, the answer helped but not completely, as there was a right padding. I found out that, it is because of the padding set in the Theme i used. It might be helpful for those still see the padding. All you need to do is remove it.

    0 讨论(0)
提交回复
热议问题