iOS: add spell checking support
We don't have a separate enum just for spell checking in Qt, but Qt::ImhNoPredicitiveText should cover it. So use it to enable/disable both spell checking and auto completion. Change-Id: I7ad661cb7d720988f13bc1ed940573006c0ce229 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
This commit is contained in:
parent
7eb8b67c8b
commit
60fe9fb018
@ -62,6 +62,7 @@
|
||||
@property(nonatomic, assign) id<UITextInputDelegate> inputDelegate;
|
||||
@property(nonatomic) UITextAutocapitalizationType autocapitalizationType;
|
||||
@property(nonatomic) UITextAutocorrectionType autocorrectionType;
|
||||
@property(nonatomic) UITextSpellCheckingType spellCheckingType;
|
||||
@property(nonatomic) BOOL enablesReturnKeyAutomatically;
|
||||
@property(nonatomic) UIKeyboardAppearance keyboardAppearance;
|
||||
@property(nonatomic) UIKeyboardType keyboardType;
|
||||
|
@ -496,6 +496,8 @@ Q_GLOBAL_STATIC(StaticVariables, staticVariables);
|
||||
self.secureTextEntry = BOOL(hints & Qt::ImhHiddenText);
|
||||
self.autocorrectionType = (hints & Qt::ImhNoPredictiveText) ?
|
||||
UITextAutocorrectionTypeNo : UITextAutocorrectionTypeDefault;
|
||||
self.spellCheckingType = (hints & Qt::ImhNoPredictiveText) ?
|
||||
UITextSpellCheckingTypeNo : UITextSpellCheckingTypeDefault;
|
||||
|
||||
if (hints & Qt::ImhUppercaseOnly)
|
||||
self.autocapitalizationType = UITextAutocapitalizationTypeAllCharacters;
|
||||
|
Loading…
Reference in New Issue
Block a user