减少导航抽屉内菜单组之间的空间 [英] Reduce space between menu groups inside navigation drawer
本文介绍了减少导航抽屉内菜单组之间的空间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想减少导航抽屉中每个菜单组之间的空间(在下图中,两行之间的空间).
I want to reduce the space between each menu group in the Navigation drawer (In the following image, space between the two lines).
我创建了一种自定义样式,并尝试了以下属性
I've created a custom style and tried the following attributes
<item name="android:paddingTop">0dp</item>
<item name="android:paddingBottom">0dp</item>
他们只减少了项目文本周围的空白.
They only reduced the padding around the items text.
即使以下属性不起作用
Even the following attributes didn't worked
<item name="android:layout_marginTop">0dp</item>
<item name="android:layout_marginBottom">0dp</item>
推荐答案
我认为您必须覆盖 项目 dimes.xml
I think you must override
design_navigation_separator_vertical_padding dimens
in your project dimes.xml
<dimen name="design_navigation_separator_vertical_padding" tools:override="true">0dp</dimen>
这篇关于减少导航抽屉内菜单组之间的空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文