views:

83

answers:

2

Hi guys,

I know that it's trivial to add a red number badge to an app's icon on the home screen. What's the best way to get a badge that looks like this within my app? There are some classes I've found online that can do this, such as MKNumberBadgeView, but none that I've found look completely right. Facebook, for example, implements red badges within the app perfectly as far as I can see. Did they just build their own badges by trial and error? Any suggestions would be appreciated.

Thanks,

Luke

+2  A: 

Where do you want the badge? The standard badge can trivially be added to a UITabBarItem through the badgeValue property. It is documented here.

Sedate Alien
*UITabBarItem you mean.
DysonApps
Indeed, thank you for that!
Sedate Alien
I'm hoping to stick the badge on a UIImageView, but ideally the badge would just be a view itself. This is a great suggestion and I might be able to use it if I can get the tab bar itself to be invisible, which I'm working on.
Luke