I have come to an issue with iOS 7 that I dont know how to solve. I have multiple UItextviews that present a keyboard on touch. For iOS 6 the view scrolls up and the keyboard is shown underneath, but when i run it on iOS 7 the view gets pushed underneath the keyboard. I cant figure out why the view is getting pushed down in iOS 7. i dont have any code that handles iOS 7 different.
UITextView
iOS 6
i OS 7
See my answers here and here.
You should set contentInset bottom to the keyboard's height and then add some code to handle the view that is below the keyboard to be scrolled to visible.
Related
Is there a function to check what device the user is using?
In one of my View Controllers I have a view inside a scrollview. In that view I have some text inputs. Then I change the height position on that view in order to prevent the keyboard from being on top of the view/inputs.
I don't need to move the view as much on an iPhone 6 compared to an iPhone 5.
print(UIDevice.currentDevice().name)
Will get you want you want.
I am just finally updating my app into IOS7. Seems like all of the XIBs now load to the very top of the screen and over write the Carrier, Time and Battery. Do I need to set something to move everything down?
This is normal if you are using iOS7. See this Fix for status bar issue in IOS 7 or this iOS 7 - Status bar overlaps the view (...problem already solved).
Under iOS <=6:
When I click round switch, the delete "Usun" button goes from right.
In iOS 7: the cell goes to the left, delete "Usun" button is hidden, but work!!! after click.
This is the same code & the same xib like in 6.
How can I resolve this problem under iOS 7?
I have the following problem:
I have a universal app. I use a tab bar, a navigation controller and a table view. There is nothing wrong, everything runs as it should.This is in Xcode 4.
But now I open the app in Xcode 5, something goes wrong. The view that comes after the table view, all have a text view. However, all text views are different in length.
In Xcode 4 I have properly set the autosizing for iphone / ipad. In Xcode 5 I have all the same settings. But the problem is that the text view is displayed differently. For short texts view begins at the top of the text. But for long texts, the view starts somewhere in the middle of the text. So I have to go up first to the beginning of the text to read. Also on the ipad, the view is not using the full width of the ipad to display the text anymore.
I have tried all of the autosizing, but I can not figure it out.
Check your constraints, you probably need to pin the height of the text views
I have an app with a table view in a nav controller; I wanted to disable bouncing so that when my table is in Edit mode, user can scroll down and find rows to delete; otherwise, it would bounce back and not give them the opportunity to press the delete icon next to the row.
So I did this:
self.tableView.bounces=NO;
When I run my app on iOS 4, this works like a charm. User can scroll and the table does not bounce back.
But on iOS 5, the scrolling is also not working at all for the table. No scroll. So to be safe, I did this:
self.tableView.bounces=NO;
self.tableView.scrollEnabled=YES;
But this made no difference.
I create my table view and its nav controller programmatically; everything else is working fine with them. Any idea why disabling bounces would also prevent scrolling on iOS 5?
I found the solution here:
UITableView won't scroll after editing view frame and origin
If you manually set the origin of the tableview, on iOS 5 it disables scrolling. on iOS 4 it is not. a shame, really.