This view is not constrained vertically: at runtime it will jump to the left unless you add a vertic
2017-06-08 16:24
1306 查看
Android studio 使用约束布局(ConstraintLayout)报错:
This view is not constrained vertically: at runtime it will jump to the left unless you add a vertical constraint less… (Ctrl+F1)
The layout editor allows you to place widgets anywhere on the canvas, and it records the current position with designtime attributes (such as layout_editor_absoluteX.) These attributes are not applied at runtime, so if you push your layout on a device, the widgets may appear in a different location than shown in the editor. To fix this, make sure a widget has both horizontal and vertical constraints by dragging from the edge connections.
解决方案:
1.切换xml到design试图下
2.选中ConstraintLayout右键选择Constraint Layout中的Infer Constraints
This view is not constrained vertically: at runtime it will jump to the left unless you add a vertical constraint less… (Ctrl+F1)
The layout editor allows you to place widgets anywhere on the canvas, and it records the current position with designtime attributes (such as layout_editor_absoluteX.) These attributes are not applied at runtime, so if you push your layout on a device, the widgets may appear in a different location than shown in the editor. To fix this, make sure a widget has both horizontal and vertical constraints by dragging from the edge connections.
解决方案:
1.切换xml到design试图下
2.选中ConstraintLayout右键选择Constraint Layout中的Infer Constraints
相关文章推荐
- 在Design界面直接拖放控件的时候,提示AS- This view is not constrained vertically. At runtime it will jump to the left/(0,0) unless you
- AS- This view is not constrained vertically. At runtime it will jump to the left/(0,0) unless you
- This view is not constrained, it only has designtime positions, so it will jump to (0,0) unless you
- This view is not constrained, it only has designtime positions, so it will jump to (0,0) unless you
- Light is falling on a tree from left side you have to find all the nodes on which this light will fa
- The service cannot be activated because it does not support ASP.NET compatibility. ASP.NET compatibility is enabled for this application. Turn off ASP.NET compatibility mode in the web.config or add the AspNetCompatibilityRequirements attribute to the ser
- when the preview menu is diabled in BO, you can add this setting to enabled it
- Attempting to load the view of a view controller while it is deallocating is not allowed and may res
- Unable to start debugging on the web server. You do not have permission to debug the application. The URL for this project is in
- the selected server is enabled,but is not configured properly.Deployment to it will not be permitted
- php首次使用date函数 遇到警告:Warning:date():It is not safe to rely on the system's timezone settings.You...
- UISearchController Attempting to load the view of a view controller while it is deallocating is not allowed and may result in undefined behavior
- 安装Visual Studio 2010时提示"The location specified for the help content store is invalid or you do not have access to it".
- 执行 maven 命令 报错Unable to add module to the current project as it is not of packaging type 'pom'
- the breakpoint will not currently be hit. No executale code is currently loaded at this location
- centos 7 The path "" is not a valid path to the 3.10.0-229.el7.x86_64 kernel headers. Would you like to change it?
- 错误 the type "xxxx" is defined in an assembly that is not refernced.You must add a reference to assem
- runtime modeler error: Wrapper class org.example.mywsdl.Add is not found. Have you run APT to genera
- Attempting to load the view of a view controller while it is deallocating is not allowed and may res
- Ubuntu安装VMware-tools时出现the path "" is not a valid path would you like to change it-完美解决方案