Discussion Forums  >  Uncategorized

Replies: 1    Views: 211

Stobe
buzztouch Evangelist
Profile
Posts: 1528
Reg: Mar 04, 2011
Fredericksburg,...
24,680
02/03/12 01:05 PM (14 years ago)

text in bottom toolbar possible?

I was wondering how hard it would be (if even possible) to put a text label in the bottom toolbar (the one that gets shown when adding the email link, for example.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
02/04/12 01:37 AM (14 years ago)
Sure, very possible. I dont' have the code in front of me but it'll be something like this... All the screens that use the lower toolbar you're referring to grab it from the BT_viewUtilities.m file. This file has a few methods that create the bottom toolbar for certain types of screens. Look for one named something like getToolbarForWebView or something? In this method, you'll see where an array of buttons is created then added to the UIToolBar as subview. The idea here is that you'll create a UILabel then add that label to the UIToolBar as a subview. Lots of the other screens create UILabels so you can copy/paste code to make the label. You'll also want to do a google search on how to center the UILabel in the toolbar when you add it. Tip: Rather than horsing around trying to center it (it can get tricky), make the UILabel the same width as the screen then just center the text ;-)
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.