Reputation: 489
I have a scrollView
in a viewController
's main view
, which contains two textFields
, an email and a password
If I set isSecureEntry = true
on the password field (only), the email can not use 3rd party keyboards (doesn't matter what keyboardType
I set it to, either). Is this normal behaviour? If it detects a secure textField
on a view, it disables 3rd party keyboards for all textFields
? Because if I set isSecureEntry = false
on the password field, both text fields can use the 3rd party keyboard.
UITextViews
throughout the app can properly use it, also other UITextFields
in other views.
If it matters, this bunch of system constraints break when bringing the language changer popup up:
Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(
"<NSLayoutConstraint:0x1d02966c0 'UISV-canvas-connection' UIStackView:0x102c6d820.leading == UIInputSwitcherTableCellSegmentView:0x102c6df20.leading (active)>",
"<NSLayoutConstraint:0x1d0296760 'UISV-canvas-connection' H:[UIInputSwitcherTableCellSegmentView:0x102c6fc00]-(0)-| (active, names: '|':UIStackView:0x102c6d820 )>",
"<NSLayoutConstraint:0x1d0296800 'UISV-fill-equally' UIInputSwitcherTableCellSegmentView:0x102c6efd0.width == UIInputSwitcherTableCellSegmentView:0x102c6df20.width (active)>",
"<NSLayoutConstraint:0x1d02968f0 'UISV-fill-equally' UIInputSwitcherTableCellSegmentView:0x102c6fc00.width == UIInputSwitcherTableCellSegmentView:0x102c6df20.width (active)>",
"<NSLayoutConstraint:0x1d02967b0 'UISV-spacing' H:[UIInputSwitcherTableCellSegmentView:0x102c6df20]-(9)-[UIInputSwitcherTableCellSegmentView:0x102c6efd0] (active)>",
"<NSLayoutConstraint:0x1d02968a0 'UISV-spacing' H:[UIInputSwitcherTableCellSegmentView:0x102c6efd0]-(9)-[UIInputSwitcherTableCellSegmentView:0x102c6fc00] (active)>",
"<NSLayoutConstraint:0x1d0295860 'UIView-Encapsulated-Layout-Width' UIStackView:0x102c6d820.width == 0 (active)>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x1d02968a0 'UISV-spacing' H:[UIInputSwitcherTableCellSegmentView:0x102c6efd0]-(9)-[UIInputSwitcherTableCellSegmentView:0x102c6fc00] (active)>
Thank you!
Upvotes: 3
Views: 1256
Reputation: 46
Once you enable the secure text entry for the textfield,system will limit the third party keyboard,it also affect the textfield before,that is the email textfield in your situation.But it only affect one textfield before the textfield which has secure text entry porperty.That mean,if your have three textfield in a view,the view hierarchy like this:
--scrollView
-textfield1(can use third party keyboard)
-textfield2(can not use third party keyboard)
-textfield3(secure text entry)(can not use third party keyboard)
You see,the top textfield will not be affect by the secure text entry porperty. So,i have found a solution in your situation,you can insert a textfield with very small height(but not hidden,such as 0.5) between the email textfield and password textfield.Now,you can use third party keyboard in your email textfield.
Upvotes: 2