How to add buttons like refresh and search in ToolBar in Android?

后端 未结 4 1735
情书的邮戳
情书的邮戳 2020-12-12 18:50

\"enter

I have made a ToolBar, but when I add menu items in menu.xml it always shows a

4条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-12 19:47

    OK, I got the icons because I wrote in menu.xml android:showAsAction="ifRoom" instead of app:showAsAction="ifRoom" since i am using v7 library.

    However the title is coming at center of extended toolbar. How to make it appear at the top?

提交回复
热议问题