Как добавить отступы между пунктами меню в Android? [Дубликат]
На этот вопрос уже есть ответ здесь:
ActionBarSherlock - Как установить отступ каждой иконки панели действий? 1 ответУ меня пункты меню надуваются из res / menu / menu.xml в ActionBar, как мне добавить отступы между пунктами меню с помощью Android?
<item
android:id="@+id/home"
android:showAsAction="always"
android:title="Home"
android:icon="@drawable/homeb"/>
<item
android:id="@+id/location"
android:showAsAction="always"
android:title="Locations"
android:icon="@drawable/locationb"/>
<item
android:id="@+id/preQualify"
android:showAsAction="always"
android:title="Pre-Qualify"
android:icon="@drawable/prequalityb"/>
<item
android:id="@+id/products"
android:showAsAction="always"
android:title="Products"
android:icon="@drawable/productb"/>
Java-файл:
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(R.menu.activity_store_locator, menu);
return true;
}