Search Results

Search found 78 results on 4 pages for 'uitoolbar'.

Page 2/4 | < Previous Page | 1 2 3 4  | Next Page >

  • UIToolbar above UIWebView inside UIScrollView

    - by Nick VanderPyle
    I'd like to display a toolbar above a UIWebView but hide the toolbar until the person "pulls it down". The same functionality can be seen in Safari on the iPhone. When the page loads, the toolbar containing the address is hidden. You must pull it down. In Safari it's possible to scroll up and eventually see the toolbar or scroll down through the page contents. I've tried placing a UIToolbar and UIWebView inside a UIScrollView but it didn't work. I've tried setting the UIScrollView to the size of the toolbar and webview combined, but that didn't work. - (void)viewDidLoad{ CGSize size = CGSizeMake(webView.frame.size.width, toolBar.frame.size.height + webView.frame.size.height); [scrollView setContentSize:size]; } How should I go about doing this?

    Read the article

  • Pull down UIToolbar above UIWebView inside UIScrollView

    - by Nick VanderPyle
    I'd like to display a toolbar above a UIWebView but hide the toolbar until the person "pulls it down". The same functionality can be seen in Safari on the iPhone. When the page loads, the toolbar containing the address is hidden. You must pull it down. In Safari it's possible to scroll up and eventually see the toolbar or scroll down through the page contents. I've tried placing a UIToolbar and UIWebView inside a UIScrollView but it didn't work. I've tried setting the UIScrollView to the size of the toolbar and webview combined, but that didn't work. - (void)viewDidLoad{ CGSize size = CGSizeMake(webView.frame.size.width, toolBar.frame.size.height + webView.frame.size.height); [scrollView setContentSize:size]; } How should I go about doing this?

    Read the article

  • How to add uitoolbar to uitableviewcontroller?

    - by Jakub
    I have an UITableViewController which I would like to add UIToolbar to with one button. In the - (void)viewDidLoad; method of UITableViewController I have: - (void)viewDidLoad { [super viewDidLoad]; UIBarButtonItem *button = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemAdd target:self action:@selector(pressButton1:)]; self.navigationItem.title = @"Some title"; self.navigationItem.leftBarButtonItem = button; } Unfortunately I don't see the toolbar when I run my app. Any hints? Should I do something more?

    Read the article

  • UIToolbar on top of navigation bar - black opaque doesn't blend

    - by z s
    I am trying to put a UIToolbar on the right side of a UINavigationBar, to add multiple buttons on that side. When I leave the tint of both to Default, they blend fine. But when I set both of them to BlackOpaque, they don't blend very well. I can see the edge of where the toolbar starts very clearly. I've tried this through IB and code. Same result in both cases. Anyone run into this before, or can offer some suggestions?

    Read the article

  • When the current toolbar is touched previous toolbar items are activated.

    - by srikanth rongali
    I have a UIToolBar *toolbar1. I have 3 buttons on the toolbar. And the tool bar is at the bottom of the view. The buttons are like library button, moreApps button, recordVideo button. If I touch the library button a new view(a UITableViewController) appears. I used presentModelViewController for it. If I touch moreApps button a new view (a UIViewController) appears and it loaded from http//. The recordButton touch gives another UIViewController view. When the moreApps button is touched and the view is loaded, it have the content from web and a UIToolBar *toolbar2 at the bottom the view. It has a refresh button and done button. The problem is when I touch the toolbar2 (not on the refresh button and done button) the previous views button are activated and corresponding views of previous buttons(library button, playVideo button) are loaded. I am not able to understand about this problem. Thank you.

    Read the article

  • iPhone toolbar shared by multiple views

    - by codemonkey
    Another iPhone noob question. The app I'm building needs to show a shared custom UIToolbar for multiple views (and their subviews) within a UITabBarController framework. The contents of the custom toolbar are the same across all the views. I'd like to be able to design the custom toolbar as a xib and handle UI events from its own controller class (I'm assuming I can subclass UIToolbar to do so?). That way I could define IBOutlet & IBAction items, etc. Then I could associate this custom toolbar with eachs of the UITabBarController views (and their subviews). But I'm having trouble finding out whether that's possible - and if so, how to do it. In particular, I want to be able to push new views onto UINavigationControllers that are each associated with parent UITabBarController tabs. So, to summarize, I want a: custom toolbar shared by multiple views which are managed by multiple navigation controllers and the navigation controllers are associated with different tabs of a parent tab bar controller The tab bar controller itself is launched modally, though I don't believe that's relevant. Anyway, the tab bar controller is working, as are its child navigation controllers. I'm just having a little trouble figuring out how to persist the shared toolbar to the various subviews. I'd settle for a good clean way of implementing programmatically... though I'd prefer the flexibility of keeping the toolbar's visual design in a xib. Anyone have any suggestions?

    Read the article

  • question related to backbutton of UIToolbar

    - by user217572
    sir I'm getting 2 different values in back button click My question is, *If I want to back to view as per my value coming in int variable. how is it possible? *My second question is that my project is based on UINavigationController So,how should i do that? bcoz i'm using PushviewController to puch the new view from olderview Thanks in advance

    Read the article

  • Animation of UINavigationController's UIToolbar

    - by Michael Waterfall
    When presenting a view controller that has toolbar items, is it possible for the toolbar to slide in with the view controller (i.e. slide in from the right) as opposed to it sliding from the bottom? In the view controller that is being presented, I've got the toolbar being shown within the -viewWillAppear: method, but the toolbar is being slid up from the bottom of the screen as opposed to it looking like it belongs to the view controller. - (void)viewWillAppear:(BOOL)animated { [self.navigationController setToolbarHidden:NO animated:YES]; ... }

    Read the article

  • Adding a UILabel to a UIToolbar

    - by Boolean
    I'm trying to add a label to my toolbar. Button works great, however when I add the label object, it crashes. Any ideas? UIBarButtonItem *setDateRangeButton = [[UIBarButtonItem alloc] initWithTitle:@"Set date range" style:UIBarButtonItemStyleBordered target:self action:@selector(setDateRangeClicked:)]; UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(5, 5, 20, 20)]; label.text = @"test"; [toolbar setItems:[NSArray arrayWithObjects:setDateRangeButton,label, nil]]; // Add the toolbar as a subview to the navigation controller. [self.navigationController.view addSubview:toolbar]; // Reload the table view [self.tableView reloadData];

    Read the article

  • iPad. UIBarButtonItem has an undocumented view of type UIToolbarTextButton. Huh?

    - by dugla
    I have an iPad app where I have a view controller that is the UIGestureRecognizerDelegate for a number of UIGestureRecognizers. I have implemented the following method of UIGestureRecognizerDelegate: - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch { // Double tapping anywhere on the screen hides/shows the toolbar if ([gestureRecognizer isKindOfClass:[UITapGestureRecognizer class]] == YES) { if (touch.tapCount == 2) { self.toolbar.hidden = self.toolbar.isHidden ? NO : YES; } // if (touch.tapCount == 2) } // if ([gestureRecognizer isKindOfClass:[UITapGestureRecognizer class]] == YES) // All gestures are ignored unless they happen on the fullscreen EAGLView if ([touch.view isKindOfClass:[EAGLView class]] == NO) { return NO; } // if ([touch.view isKindOfClass:[EAGLView class]] == NO) return YES; } My setup is a fullscreen EAGLView with a UIToolbar atop the EAGLView. There is a UIBarButtonItem on the toolbar. The idea here is that double-tapping anywhere toggles the appearance of the toolbar. All other gestures must occur on the EAGLView. My problem is that taps directly on the UIBarButtonItem show touch.view to be the UIView subclass UIToolbarTextButton which is undocumented and can't be introspected. Huh? Can someone suggest a work around, preferably that uses introspective goodness of some form? Thanks, Doug Thanks, Doug

    Read the article

  • UIKeyBoard resize on orientation change to landscape

    - by Dave
    This is very rookie question. I have a UIToolBar at the bottom which is supposed to animatedly move up and down with key board when the UIKeyBoard is displayed. I got that working with the help of UIKeyBoard Notifications. The view we are talking about has split view enabled. When device orientation is landscape, both the views as columns are shown [hope that makes sense]. When key board is shown, i do this CGSize keyBoardSize = [[notificationInfo objectForKey:UIKeyboardFrameEndUserInfoKey]CGRectValue].size; CGRect toolbarFrame= [BottomToolBar frame]; toolbarFrame.origin.y -= keyBoardSize.height; [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:0.3]; BottomToolBar .frame = viewFrame; [UIView commitAnimations]; when key board is hiiden i do this toolbarFrame.origin.y += keyBoardSize.height; My Problem is when device orientation changes to landscape, when the key board is visible the bottom tool bar is gone. I see it move up quickly. I am not sure how to fix this. Can anyone help please? Also, is there a way to NOT make the key board span across both the views in the split view?

    Read the article

  • Toolbar hiding on rotated UISplitView DetailView

    - by Gerry
    I've based my app on Apple's SplitView project type. I have a TableView as the Master, and am using different types of views as the Detail view. To select types of detail view, I'm using the fancy concept of buttons on my DetailView toolbar. When the DetailView is derived from UIViewController, everything is good. When the DetailView derives from UIViewController, but contains a UITableView then I have problems. In portrait view the toolbar is visible. In landscape mode the toolbar is hidden, even though the Tableview is moved down to allow space for it. The UIToolbar and UITableView are both defined in my NIB file which is loaded to create the detail view. Why is my toolbar invisible in landscape? BTW, is this the best way to choose Detail view types with UISplitView? Bonus question, what if selecting a row in my DetailView tableview should bring up another View, I can't push it like I would with a NaviagtionController, so how do I go back to the detail tableview? Thanks, Gerry

    Read the article

  • Cannot get UISearchBar Scope Bar to appear in Toolbar on iPad

    - by Jann
    This is really causing me fits. I put a toolbar on the IUView on the iPad. I added the following: Search Bar (not Search Bar and Search Display) to the toolbar. I set the options to be as follows: Show Cancel Button, Show Scope Bar, Scope Button Titles are: "Title1" and "Title2" (with Title2's radio button selected). Opaque, Clear Context and Auto Resize are checked. I hooked up the delegate of Search Bar to the "File's Owner" and linked it to IBOutlet theSearchBar. In my viewWillAppear I have the following: [theSearchBar setScopeButtonTitles:[NSArray arrayWithObjects:@"Near Me",@"Everywhere",nil]]; //Just in case: [theSearchBar setShowsScopeBar:YES]; //doesn't seem to do anything: //[theSearchBar sizeToFit]; searchDisplayController = [[UISearchDisplayController alloc] initWithSearchBar:theSearchBar contentsController:self]; [self setSearchDisplayController:searchDisplayController]; [searchDisplayController setDelegate:self]; [searchDisplayController setSearchResultsDataSource:self]; //again--does not seem to do anything..but people have suggested it: [theSearchBar sizeToFit]; Okay, so far, I thought, so good. So, I made the File's Owner .m file to be a delegate for: UISearchBarDelegate, UISearchDisplayDelegate. My issue: I have yet to implement the delegates necessary to do the search but still... shouldn't I be seeing the scopeBar next to the search field when I click into the search field? Just so you know I DO see the log of the characters I type, so the delegate is working. I have the following dummy functions in the .m file (just in case) // called when keyboard search button pressed - (void)searchBarSearchButtonClicked:(UISearchBar *)searchBar { NSLog(@"Search Button Clicked\n"); [theSearchBar resignFirstResponder]; } // called when cancel button pressed - (void)searchBarCancelButtonClicked:(UISearchBar *)searchBar { NSLog(@"Cancel Button Clicked\n"); [theSearchBar resignFirstResponder]; } - (void)searchBar:(UISearchBar *)searchBar textDidChange:(NSString *)searchText { NSLog(@"Search Text So Far: '%@'\n",searchText); } - (BOOL)searchBarShouldBeginEditing:(UISearchBar *)searchBar { return YES; } - (BOOL)searchBarShouldEndEditing:(UISearchBar *)searchBar { return YES; } Why doesn't the Scope Bar appear? A results UIPopoverController appears with the title "Results" and "No results found" (of course) when i type the first character in my search...but no scope bar. (not that i expect anything other than "No Results Found". I am wondering where the scope bar is supposed to appear...in the titleView of the UIPopover? In the toolbar to the right of the search area? Where?

    Read the article

  • Cannot get UISearchBar Scope Bar to appear in Toolbar (or anywhere) on iPad

    - by Jann
    This is really causing me fits. I see a lot of info on putting a UISearchBar in the top row of a UITableView -- but I am putting the UISearchBar into the Toolbar at the top of my screen (on the iPad). I cannot find ANYTHING regarding how to handle UISearchBar and UISearchDisplayController using a UIPopoverController on the iPad. Any more info about the UISearchDisplayController using a UIPopoverController would be greatly appreciated. Please help with this as I am at my wit's end. Using IB, I put a toolbar on the IUView on the iPad. I added the following: Search Bar (not Search Bar and Search Display) to the toolbar. I set the options to be as follows: Show Cancel Button, Show Scope Bar, Scope Button Titles are: "Title1" and "Title2" (with Title2's radio button selected). Opaque, Clear Context and Auto Resize are checked. I hooked up the delegate of Search Bar to the "File's Owner" and linked it to IBOutlet theSearchBar. In my viewWillAppear I have the following: //Just in case: [theSearchBar setScopeButtonTitles:[NSArray arrayWithObjects:@"Near Me",@"Everywhere",nil]]; //Just in case (again): [theSearchBar setShowsScopeBar:YES]; //doesn't seem to do anything: //[theSearchBar sizeToFit]; searchDisplayController = [[UISearchDisplayController alloc] initWithSearchBar:theSearchBar contentsController:self]; [self setSearchDisplayController:searchDisplayController]; [searchDisplayController setDelegate:self]; [searchDisplayController setSearchResultsDataSource:self]; //again--does not seem to do anything..but people have suggested it: [theSearchBar sizeToFit]; Okay, so far, I thought, so good. So, I made the File's Owner .m file to be a delegate for: UISearchBarDelegate, UISearchDisplayDelegate. My issue: I have yet to implement the delegates necessary to do the search but still... shouldn't I be seeing the scopeBar next to the search field when I click into the search field? Just so you know I DO see the log of the characters I type, so the delegate is working. I have the following dummy functions in the .m file (just in case) // called when keyboard search button pressed - (void)searchBarSearchButtonClicked:(UISearchBar *)searchBar { NSLog(@"Search Button Clicked\n"); [theSearchBar resignFirstResponder]; } // called when cancel button pressed - (void)searchBarCancelButtonClicked:(UISearchBar *)searchBar { NSLog(@"Cancel Button Clicked\n"); [theSearchBar resignFirstResponder]; } - (void)searchBar:(UISearchBar *)searchBar textDidChange:(NSString *)searchText { NSLog(@"Search Text So Far: '%@'\n",searchText); } - (BOOL)searchBarShouldBeginEditing:(UISearchBar *)searchBar { return YES; } - (BOOL)searchBarShouldEndEditing:(UISearchBar *)searchBar { return YES; } Why doesn't the Scope Bar appear? A results UIPopoverController appears with the title "Results" and "No results found" (of course) when i type the first character in my search...but no scope bar. (not that i expect anything other than "No Results Found". I am wondering where the scope bar is supposed to appear...in the titleView of the UIPopover? In the toolbar to the right of the search area? Where?

    Read the article

  • iPad Gestures. How Do I Force a Child View to Discard Gesture Events.

    - by dugla
    On iPad, I have a parent-child view hierarchy. The parent is a fullscreen EAGLView and the child is a UIToobar. The parent has pan/touch/pinch gesture recognizers attached. When gestures occur on the child (toolbar) they are passed on to the parent (fullscreen view). Not what I want. How do I force the toolbar to discard/ignore gestures? Thanks, Doug

    Read the article

  • how to balance position of UIBarButtonItem in toolbar

    - by RAGOpoR
    is it possible to balance the position of button(example toolbar in Safari)? UIBarButtonItem *infoButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemCompose target:self action:@selector(support:)]; UIBarButtonItem *next = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemPlay target:self action:@selector(support:)]; [self.navigationController.toolbar setItems:[NSArray arrayWithObjects:infoButton, next,nil] animated:YES];

    Read the article

  • UITabBarController "More" tab issues

    - by codemonkey
    I've got a UITabBarController with 7 tabs. Each of the 7 tabs has its own UINavigationController and customizes its toolbar. When a view is loaded via the UITabBarController's "More" menu its custom toolbar isn't appearing. If i switch the order of the views around so that the same view is now accessible from the UITabBar without going through the "More" menu then the custom toolbar shows up like it's supposed to. Is there a way to customize a NavigationController's toolbar when that NavigationController is loaded via the "More" menu of a TabBarController? I'm actually also interested in replacing the "More" menu navigation controller with my own custom one on views loaded via the "More" menu... not sure whether that's even possible. Any feedback will be appreciated.

    Read the article

  • Problem adding UIBarButtonItems to a ToolBar

    - by Olivier de Jonge
    I have a UINavigationController with a UITableViewController in it. I want to show a ToolBar on the bottom with UIBarButtonItem's. The ToolBar is showing up, but the buttons won't appear. Anyone knows why? - (void)viewDidLoad { [super viewDidLoad]; [[self navigationItem] setTitle:@"Selections List"]; [[self navigationItem] setRightBarButtonItem:[[[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemAdd target:self action:@selector(addProjectSearch:)] autorelease]]; [[self navigationItem] setLeftBarButtonItem:[self editButtonItem]]; [[super tableView] setDataSource: self]; [[super tableView] setDelegate: self]; //Toolbar UIBarButtonItem * logoutButton = [[[UIBarButtonItem alloc] initWithTitle:@"Log out" style:UIBarButtonItemStylePlain target:self action:@selector(logOut:)]autorelease]; NSMutableArray * arr = [NSMutableArray arrayWithObjects:logoutButton, nil]; [[self navigationController] setToolbarHidden: NO animated:YES]; [[self navigationController] setToolbarItems:arr animated:YES]; }

    Read the article

  • iPhone: How to Display Mail Composer View Without Obscuring Toolbar

    - by Warrior
    I display a mail composer view upon a tool bar button click event. At present, I can display the email composer view but when it display it hides the tool bar. I need the toolbar to remain visible. I have seen other apps display the email composer without hiding a toolbar but I can't figure out how they did so. I am new to iphone development. Please help me out.Thanks.

    Read the article

  • How can I fix this NavigationController and UIToolbar offset issue in Objective-C?

    - by editor
    I'm adding a couple of buttons to an already-existing NavigationController. The two buttons are added to a UIView, which is pushed onto the NavigationItem. The buttons stop and reload a UIWebView. Problem is that there's a slight offset issue that is making it all look pretty ugly. I wish I could set the UIToolbar to transparent or clear background but that doesn't seem to be an option. Can't seem to use negative offsets either. I've got color matching, but if you look closely there's 1px or 2px of highlighting up top that's causing a visual mismatch and then a slight offset at the bottom. Some relevant code below (based on this, inbound Googlers). What are my options to resolve this? // create a toolbar for the buttons UIToolbar* toolbar = [[UIToolbar alloc] initWithFrame:CGRectMake(0, 0, 100, 45)]; [toolbar setBarStyle: UIBarStyleDefault]; UIColor *colorForBar = [[UIColor alloc] initWithRed:.72 green:0 blue:0 alpha:0]; toolbar.tintColor = colorForBar; [colorForBar release]; //[toolbar setTranslucent:YES]; // create an array for the buttons NSMutableArray* buttons = [[NSMutableArray alloc] initWithCapacity:3]; // create a standard reload button UIBarButtonItem *reloadButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemRefresh target:self action:@selector(reload)]; reloadButton.style = UIBarButtonItemStyleBordered; [buttons addObject:reloadButton]; [reloadButton release]; // create a spacer between the buttons UIBarButtonItem *spacer = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil]; [buttons addObject:spacer]; [spacer release]; // create a standard delete button with the trash icon UIBarButtonItem *stopButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemStop target:self action:@selector(stopLoading)]; stopButton.style = UIBarButtonItemStyleBordered; [buttons addObject:stopButton]; [stopButton release]; // put the buttons in the toolbar and release them [toolbar setItems:buttons animated:NO]; [buttons release]; // place the toolbar into the navigation bar self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:toolbar]; [toolbar release];

    Read the article

  • How to position a UIToolbar at the top of the screen?

    - by Mr_Nizzle
    I've figured out how to hide the navigation bar and then show the toolbar it has built-in but the toolbar appears at the bottom os the screen how can i position the toolbar on the top of the scren? here's some of my code UIBarButtonItem *yesterday = [[UIBarButtonItem alloc]initWithTitle:@"Yesterday" style:UIBarButtonItemStyleBordered target:self action:@selector(yesterday:)]; UIBarButtonItem *today = [[UIBarButtonItem alloc]initWithTitle:@"Today" style:UIBarButtonItemStyleDone target:self action:@selector(today:)]; UIBarButtonItem *tomorrow = [[UIBarButtonItem alloc]initWithTitle:@"Tomorrow" style:UIBarButtonItemStyleBordered target:self action:@selector(tomorrow:)]; UIBarButtonItem *month = [[UIBarButtonItem alloc]initWithTitle:@"Month" style:UIBarButtonItemStyleBordered target:self action:@selector(month:)]; NSArray *items = [NSArray arrayWithObjects:yesterday,today,tomorrow,month, nil]; [yesterday release]; [today release]; [tomorrow release]; [month release]; [self setToolbarItems:items]; [[self navigationController] setNavigationBarHidden:YES animated:NO]; [[self navigationController] setToolbarHidden:NO animated:YES]; Thanks.

    Read the article

< Previous Page | 1 2 3 4  | Next Page >