Menu icons not showing, ics 4.0.3

I tried to add an icon to my menu item in xml by adding this line

android:icon="@android:drawable/ic_menu_preferences"

in <item>and it didn't work.

I also tried to put my image in a folder with the ability to transfer, try to display it:

android:icon="@drawable/my_image"

Does not work either, icons do not appear on the menu.

What am I doing wrong?

+3
source share
1 answer

If in the “menu” you mean the overflow area of ​​the action of the action bar, it does not display icons, and therefore you are not doing anything wrong. Icons are used only for toolbar buttons in the action bar.

+1
source

All Articles