I ran into this issue earlier in the week and again just now. I'm in the process of setting my keyboard offset for when the keyboard appears on the screen when the user is in landscape mode of an iPad. iPads have a dimension of 1024 x 768.
- (void) keyboardWasShown:(NSNotification *)nsNotification {
NSDictionary *userInfo = [nsNotification userInfo];
CGSize kbSize = [[userInfo objectForKey:UIKeyboardFrameBeginUserInfoKey] CGRectValue].size;
NSLog(@"Height: %f Width: %f", kbSize.height, kbSize.width);
// Portrait: Height: 264.000000 Width: 768.000000
// Landscape: Height: 1024.000000 Width: 352.000000
}
How is it that the height of the keyboard can be 1024? This would mean that the keyboard is now covering the entire screen. I would assume that the height should be 352, and the width should be 1024. Is this a bug?
How to make your iPad keyboard full size. Place two fingers on the floating keyboard. Spread your fingers apart to enlarge the keyboard back to full size.
What Is the Floating Keyboard on an iPad? The floating keyboard is an iPad feature which makes the default virtual keyboard smaller. It floats over the active app, which is why it's called a floating keyboard. You can drag and position it, and it's designed to make it easier to type with one hand.
Go to Settings > Accessibility > Keyboards, tap Full Keyboard Access, then turn on Full Keyboard Access. Control your iPad using keyboard shortcuts. To customize the keyboard shortcuts, tap Commands.
From http://developer.apple.com/library/ios/documentation/uikit/reference/UIWindow_Class/UIWindowClassReference/UIWindowClassReference.html#//apple_ref/doc/uid/TP40006817-CH3-SW27
UIKeyboardFrameBeginUserInfoKey
The key for an NSValue object containing a CGRect that identifies the start frame of the keyboard in screen coordinates. These coordinates do not take into account any rotation factors applied to the window’s contents as a result of interface orientation changes. Thus, you may need to convert the rectangle to window coordinates (using the convertRect:fromWindow: method) or to view coordinates (using the convertRect:fromView: method) before using it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With