I am using a custom keyboard in my app. This was working really well, but on upgrading to iOS 7 there is a background displayed behind my custom keyboard in the shape of the default keyboard - none of the keyboard keys of the default keyboard are displayed, just a transparent pale box in the shape of the default keyboard. Has anyone else had the same issue or know of a way to resolve this?
The code i am using to hide the default keyboard is:
id keyboardImpl = [objc_getClass("UIKeyboardImpl") sharedInstance];
[keyboardImpl setAlpha:0.0f];
You shouldn't do that to hide a UIKeyboard because it relies on private classes what can change in any OS release without warning
Take a look at the inputView property on UITextField: https://developer.apple.com/library/ios/documentation/uikit/reference/UITextField_Class/Reference/UITextField.html#//apple_ref/occ/instp/UITextField/inputView
Related
Whenever the software keyboard appears, it resizes the background image.
See screen shot here in this question link.
Software keyboard resizes background image on Android
This question was for android and i want to implement in Titanium.
Please help.
You can just set the windowSoftInputMode property in your window.
Generally speaking, you can assign to this property any combination of two types of constants: visibility states (ALWAYS_HIDDEN, ALWAYS_VISIBLE, HIDDEN, UNSPECIFIED or VISIBLE) and adjustment options (PAN, RESIZE or UNSPECIFIED).
In your case you can combine SOFT_INPUT_STATE_VISIBLE and SOFT_INPUT_ADJUST_PAN.
Just make few changes in your .tss file:
"#yourWindowID": {
...
windowSoftInputMode: Titanium.UI.Android.SOFT_INPUT_STATE_VISIBLE | Titanium.UI.Android.SOFT_INPUT_ADJUST_PAN
...
}
You can find more information here.
I need to add a share button to MoviePlayer, that appear and disappear at the same time when touching the screen like and with native controls.
i found this solution:
Add Custom Controls to MoviePlayer in iPhone 3.0 SDK
But _overlayView property is not recognized with IOS5. Is it possible to achieve it with current SDK?
Thanks.
I am currently working on an iphone app where I want to change default backgroundcolor of keyboard to black.Can anyone provide me sample example/code for implementing the same.
Thanks in advance.
Set the keyboardAppearance property of the text field to UIKeyboardAppearanceAlert. This gives a black background.
As of iOS7 you can use UIKeyboardAppearanceDark as well.
I am trying to write an app that uses a custom keyboard. How can I write code that prevents the iPhone keyboard from popping up. I have seen a custom keyboard that enters text in other iPhone applications, so I know that it is possible.
You're looking for the inputView property that's present on every view (inherited from UIResponder).
I have used a Text view in my app for iPad on xib. I wrote some text on it. Now while the app is running and the user is reading that text, if he accidentally touches the screen a keyboard appear. I want to disable that keyboard popping out. How should I do it?
Try setting the editable mode off:
textView.editable = NO;
You can also achieve this via Interface Builder by unchecking the Behavior Editable box in the Attributes Inspector tab.