Xcode9.4.1版本升级到Xcode10.1时,很顺利的下进行,但是项目中需要输入框的部分出现问题,在输入时IOS手机的键盘遮挡输入框问题,经过百度搜索,google搜索终于找到解决方法,方法有几种。
下面时出现的错误:
Can't find keyplane that supports type 5 for keyboard iPhone-PortraitChoco-PhonePad; using 20698_PortraitChoco_iPhone-Complex-Pad_Def
API error: <_UIKBCompatInputView: 0x7f92a9d50be0; frame = (0 0; 0 0); layer = <CALayer: 0x6000030f82e0>> returned 0 width, assuming UIViewNoIntrinsicMetric
2019-03-03 09:36:20.541984-0500 HelloCordova[86860:8842449] API error: <_UIKBCompatInputView: 0x7f92a9d50be0; frame = (0 0; 0 0); layer = <CALayer: 0x6000030f82e0>> returned 0 width, assuming UIViewNoIntrinsicMetric
2019-03-03 09:36:20.567101-0500 HelloCordova[86860:8842449] [LayoutConstraints] 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.
(Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
(
"<NSAutoresizingMaskLayoutConstraint:0x60000132d4f0 h=-&- v=-&- _UIToolbarContentView:0x7f92a9d47080.width == UIToolbar:0x7f92a9d46c30.width (active)>",
"<NSLayoutConstraint:0x600001337570 H:|-(0)-[_UIButtonBarStackView:0x7f92a9d488b0] (active, names: '|':_UIToolbarContentView:0x7f92a9d47080 )>",
"<NSLayoutConstraint:0x6000013375c0 _UIButtonBarStackView:0x7f92a9d488b0.trailing == _UIToolbarContentView:0x7f92a9d47080.trailing (active)>",
"<NSLayoutConstraint:0x600001339b80 H:|-(20)-[_UIModernBarButton:0x7f92a9d60060] (active, names: '|':_UIButtonBarButton:0x7f92a9d5fe10 )>",
"<NSLayoutConstraint:0x60000133b340 H:[_UIModernBarButton:0x7f92a9d60060]-(>=8)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d5fe10 )>",
"<NSLayoutConstraint:0x60000134e080 H:|-(>=5)-[_UIModernBarButton:0x7f92a9d60800] (active, names: '|':_UIButtonBarButton:0x7f92a9d605b0 )>",
"<NSLayoutConstraint:0x60000134df90 H:[_UIModernBarButton:0x7f92a9d60800]-(>=5)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d605b0 )>",
"<NSLayoutConstraint:0x60000132c500 H:|-(8)-[_UIModernBarButton:0x7f92a9d61220'Done'] (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c550 H:[_UIModernBarButton:0x7f92a9d61220'Done']-(20)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c910 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.leading == _UIButtonBarButton:0x7f92a9d5fe10.leading (active)>",
"<NSLayoutConstraint:0x60000132caf0 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.trailing == _UIButtonBarButton:0x7f92a9d60d20.trailing (active)>",
"<NSLayoutConstraint:0x60000132cb40 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d5fe10]-(0)-[UIView:0x7f92a9d07080] (active)>",
"<NSLayoutConstraint:0x60000132cb90 'UISV-spacing' H:[UIView:0x7f92a9d07080]-(0)-[_UIButtonBarButton:0x7f92a9d605b0] (active)>",
"<NSLayoutConstraint:0x60000132cbe0 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d605b0]-(0)-[UIView:0x7f92a9d60b40] (active)>",
"<NSLayoutConstraint:0x60000132cc30 'UISV-spacing' H:[UIView:0x7f92a9d60b40]-(0)-[_UIButtonBarButton:0x7f92a9d60d20] (active)>",
"<NSLayoutConstraint:0x60000132d680 'UIView-Encapsulated-Layout-Width' UIToolbar:0x7f92a9d46c30.width == 0 (active)>",
"<NSLayoutConstraint:0x600001337430 'UIView-leftMargin-guide-constraint' H:|-(0)-[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'](LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>",
"<NSLayoutConstraint:0x6000013374d0 'UIView-rightMargin-guide-constraint' H:[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide']-(0)-|(LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x60000133b340 H:[_UIModernBarButton:0x7f92a9d60060]-(>=8)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d5fe10 )>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
2019-03-03 09:36:20.568777-0500 HelloCordova[86860:8842449] [LayoutConstraints] 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.
(Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
(
"<NSAutoresizingMaskLayoutConstraint:0x60000132d4f0 h=-&- v=-&- _UIToolbarContentView:0x7f92a9d47080.width == UIToolbar:0x7f92a9d46c30.width (active)>",
"<NSLayoutConstraint:0x600001337570 H:|-(0)-[_UIButtonBarStackView:0x7f92a9d488b0] (active, names: '|':_UIToolbarContentView:0x7f92a9d47080 )>",
"<NSLayoutConstraint:0x6000013375c0 _UIButtonBarStackView:0x7f92a9d488b0.trailing == _UIToolbarContentView:0x7f92a9d47080.trailing (active)>",
"<NSLayoutConstraint:0x60000134e080 H:|-(>=5)-[_UIModernBarButton:0x7f92a9d60800] (active, names: '|':_UIButtonBarButton:0x7f92a9d605b0 )>",
"<NSLayoutConstraint:0x60000134df90 H:[_UIModernBarButton:0x7f92a9d60800]-(>=5)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d605b0 )>",
"<NSLayoutConstraint:0x60000132c500 H:|-(8)-[_UIModernBarButton:0x7f92a9d61220'Done'] (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c550 H:[_UIModernBarButton:0x7f92a9d61220'Done']-(20)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c910 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.leading == _UIButtonBarButton:0x7f92a9d5fe10.leading (active)>",
"<NSLayoutConstraint:0x60000132caf0 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.trailing == _UIButtonBarButton:0x7f92a9d60d20.trailing (active)>",
"<NSLayoutConstraint:0x60000132cb40 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d5fe10]-(0)-[UIView:0x7f92a9d07080] (active)>",
"<NSLayoutConstraint:0x60000132cb90 'UISV-spacing' H:[UIView:0x7f92a9d07080]-(0)-[_UIButtonBarButton:0x7f92a9d605b0] (active)>",
"<NSLayoutConstraint:0x60000132cbe0 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d605b0]-(0)-[UIView:0x7f92a9d60b40] (active)>",
"<NSLayoutConstraint:0x60000132cc30 'UISV-spacing' H:[UIView:0x7f92a9d60b40]-(0)-[_UIButtonBarButton:0x7f92a9d60d20] (active)>",
"<NSLayoutConstraint:0x60000132d680 'UIView-Encapsulated-Layout-Width' UIToolbar:0x7f92a9d46c30.width == 0 (active)>",
"<NSLayoutConstraint:0x600001337430 'UIView-leftMargin-guide-constraint' H:|-(0)-[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'](LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>",
"<NSLayoutConstraint:0x6000013374d0 'UIView-rightMargin-guide-constraint' H:[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide']-(0)-|(LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x60000134df90 H:[_UIModernBarButton:0x7f92a9d60800]-(>=5)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d605b0 )>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
2019-03-03 09:36:20.570157-0500 HelloCordova[86860:8842449] [LayoutConstraints] 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.
(Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
(
"<NSAutoresizingMaskLayoutConstraint:0x60000132d4f0 h=-&- v=-&- _UIToolbarContentView:0x7f92a9d47080.width == UIToolbar:0x7f92a9d46c30.width (active)>",
"<NSLayoutConstraint:0x600001337570 H:|-(0)-[_UIButtonBarStackView:0x7f92a9d488b0] (active, names: '|':_UIToolbarContentView:0x7f92a9d47080 )>",
"<NSLayoutConstraint:0x6000013375c0 _UIButtonBarStackView:0x7f92a9d488b0.trailing == _UIToolbarContentView:0x7f92a9d47080.trailing (active)>",
"<NSLayoutConstraint:0x60000132c500 H:|-(8)-[_UIModernBarButton:0x7f92a9d61220'Done'] (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c550 H:[_UIModernBarButton:0x7f92a9d61220'Done']-(20)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>",
"<NSLayoutConstraint:0x60000132c910 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.leading == _UIButtonBarButton:0x7f92a9d5fe10.leading (active)>",
"<NSLayoutConstraint:0x60000132caf0 'UISV-canvas-connection' UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'.trailing == _UIButtonBarButton:0x7f92a9d60d20.trailing (active)>",
"<NSLayoutConstraint:0x60000132cb40 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d5fe10]-(0)-[UIView:0x7f92a9d07080] (active)>",
"<NSLayoutConstraint:0x60000132cb90 'UISV-spacing' H:[UIView:0x7f92a9d07080]-(0)-[_UIButtonBarButton:0x7f92a9d605b0] (active)>",
"<NSLayoutConstraint:0x60000132cbe0 'UISV-spacing' H:[_UIButtonBarButton:0x7f92a9d605b0]-(0)-[UIView:0x7f92a9d60b40] (active)>",
"<NSLayoutConstraint:0x60000132cc30 'UISV-spacing' H:[UIView:0x7f92a9d60b40]-(0)-[_UIButtonBarButton:0x7f92a9d60d20] (active)>",
"<NSLayoutConstraint:0x60000132d680 'UIView-Encapsulated-Layout-Width' UIToolbar:0x7f92a9d46c30.width == 0 (active)>",
"<NSLayoutConstraint:0x600001337430 'UIView-leftMargin-guide-constraint' H:|-(0)-[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide'](LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>",
"<NSLayoutConstraint:0x6000013374d0 'UIView-rightMargin-guide-constraint' H:[UILayoutGuide:0x6000009189a0'UIViewLayoutMarginsGuide']-(0)-|(LTR) (active, names: '|':_UIButtonBarStackView:0x7f92a9d488b0 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x60000132c550 H:[_UIModernBarButton:0x7f92a9d61220'Done']-(20)-| (active, names: '|':_UIButtonBarButton:0x7f92a9d60d20 )>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
解决方法几种:
①Cordova命令安装键盘插件cordova-plugin-keyboard
②Cordova命令安装webview插件 cordova-plugin-ionic-webview
③Cordova命令安装cordova-plugin-inappbrowser
网上几种方法,我的问题使用上面方法②解决。