I have the following menu:
<menu xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:title="@string/search_title"
android:id="@+id/action_search_music"
android:icon="@drawable/ic_add_final"
app:actionViewClass="android.support.v7.widget.SearchView"
app:showAsAction="ifRoom|collapseActionView" />
<item
android:id="@+id/more_options"
android:title="Rename playlist"
android:orderInCategory="101"
app:showAsAction="always"
android:icon="@drawable/ic_more_vert_black_24dp">
<menu >
<item android:id="@+id/rename_playlist"
android:title="Rename playlist"
>
</item>
<item android:id = "@+id/action_delete_playlist"
android:title="Delete playlist"/>
</menu>
</item>
</menu>
Now, there is a pretty big space between the two menu items that I am unable to reduce. Are there any ideas how to reduce that space?
EDIT: The answer here: https://stackoverflow.com/a/10085862/6427401 doesn't work for me
simple and immediate solution: add " " before and after the menu item.
It can be enabled with the "Divi > Theme Customizer > Header & Navigation > Header Format > Enable Vertical Navigation" option. The default spacing is 19px, so anything bigger will increase it, while anything smaller will decrease it.
Add this to your app theme.
<item name="android:actionButtonStyle">@style/ActionButtonStyle</item>
where ActionButtonStyle
is
<style name="ActionButtonStyle" parent="Widget.AppCompat.ActionButton">
<item name="android:minWidth">0dip</item>
<item name="android:paddingStart">8dip</item>
<item name="android:paddingEnd">8dip</item>
</style>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With