I'm developing an iOS app with Xcode.
How can I create a button that holds a fixed position on the screen...even on a TableView?
One example is the blue round button that is at the bottom of the screen in some scenes on Foursquare app.
Add the button to the view that holds the tableView, not to the table view itself. Either bring it (the button) to front, or add it after the tableView so that it is in top of it.
Related
I have a scrollview with a bunch of icons in a collection view bring brought in from another screen. If I share one of the icons to anywhere (messenger for example) then I cancel and go back to the app, but then the entire view has moved up and no longer scrolls to the top.
Any ideas?
Normal view:
Sharing the image:
Come back to app, the collection view has moved up and I cannot scroll to the top.
Please note that there are constraints in the storyboard and it is working fine in the simulator.
I have an iOS8 app which has a UITabBarViewController as part of its master view. Embedded within that is a UITableViewController which has some UITextFields embedded in some of the cells.
When a text view is tapped, the keyboard automatically appears. If necessary, the 'view' is adjusted to allow the textView to remain showing so data can be entered.
The problem is that the tabBarController and associated tabs are also moved up. This is usually OK unless my phone is in landscape which leaves very little room to show the tableview and allow effective gestures (e.g. swiping the tableview up/down).
So, is there a way to get the keyboard to only push-up the tableview within the tabBarController, rather than the whole outer frame also being moved up? Picture below shows the problem. The device is in landscape
I want to implement a search bar in my app which mimics the one on iOS 7's home screen. When I pull down, I want it to bounce down while having enough room on top for the status bar, and I want my current view to move down to make room for the search bar as well. How should I go about with this?
My current thought is to make a new UIView class, add a UISearchBar to it and add that view to my current view (So that I can scroll down to display the search bar). But is there a better way to do this?
This is how it looks like on the iPhone home screen
http://static.trustedreviews.com/94/000028d08/1a0e/Spotlight-Search.jpg
As you said you could create a UIView with a search bar in it. Add it to your main view and set your searchView origin.y to be less than 0 so it will hide below the top of the screen.
Next you could use a UIPanGestureRecognizer to track the dragging of your finger and update the origin.y of your searchView while you drag..
I'm using JASidePanels to have a slideout-menu in my app. One of the views I have has a always-visible keyboard. My problem is that, when in this keyboard-fixed view, and I show the menu, the keyboard stays at the center of my window instead of following the view i hid to show the menu. I understand why this is, but I would like to tweak it so it follows the view im swiping to the right, instead of staying in the middle.
TL;DR how can I stick a keyboard fixed to a UIView, instead of staying in front of whole app window
I am new to IOS development, i would like to ask how i could make a scrollview with some buttons in it aligned horizontally, in which when you tab on one of the buttons the scrollview expand and displays infor data, and when you tab it again it contract or goes to the normal size again). Something like when you open grouped apps on the iphone
In the action of your UIButton try to change the UIScrollView's frame.