librelist archives

« back to archive

Using Icons instead of Strings in an ActionbarSherlock Menu

Using Icons instead of Strings in an ActionbarSherlock Menu

From:
Christopher Saunders
Date:
2012-06-03 @ 14:11
Hey,

From what I've gathered in the sample code and demo app for Actionbar
Sherlock, all menu items are in Text.  Is there a way to actually make
these items icons or perhaps views of some kind?

-- 
Christopher Saunders
http://christophersaunders.ca/

Re: [ottawaandroid] Using Icons instead of Strings in an ActionbarSherlock Menu

From:
Rob Woods
Date:
2012-06-03 @ 14:16
I used ABS on my last project and it uses menu items the same way a regular
AB uses them.  Define them in a resource xml file as a <menu>.  There are
attributes for menu items to indicate if they should be overflow menu only
or not.  Also attribute for providing an icon.

Rob W.

[image: Stack Overflow profile for brockoli at Stack Overflow, Q&A for
professional and enthusiast
programmers]<http://stackoverflow.com/users/326430/brockoli>
  Get a signature like this.

<http://r1.wisestamp.com/r/landing?promo=19&dest=http%3A%2F%2Fwww.wisestamp.com%2Femail-install%3Futm_source%3Dextension%26utm_medium%3Demail%26utm_campaign%3Dpromo_19>
CLICK

HERE.<http://r1.wisestamp.com/r/landing?promo=19&dest=http%3A%2F%2Fwww.wisestamp.com%2Femail-install%3Futm_source%3Dextension%26utm_medium%3Demail%26utm_campaign%3Dpromo_19>



On Sun, Jun 3, 2012 at 10:11 AM, Christopher Saunders <
c.saunders322@gmail.com> wrote:

> Hey,
>
> From what I've gathered in the sample code and demo app for Actionbar
> Sherlock, all menu items are in Text.  Is there a way to actually make
> these items icons or perhaps views of some kind?
>
> --
> Christopher Saunders
> http://christophersaunders.ca/
>