markdown 约束到barrier.md

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown 约束到barrier.md相关的知识,希望对你有一定的参考价值。

## Use Barriers to align elements that dynamically vary in size
Similar to a guideline, a barrier is an invisible line that you can constrain views to. Except a barrier does not define its own position; instead, the barrier position moves based on the position of views contained within it. This is useful when you want to constrain a view to the a set of views rather than to one specific view.

Barriers allow you to specify a constraint based on multiple UI elements. You'll want to use barriers any time that multiple elements could dynamically change their size based on user input or language.

Add **vertical barrier** (or **horizontal**) and in the **Component tree** select the elements to be aligned. Drag both onto your barrier in the Component Tree. Then select barrier in the component tree and open Attributes to set the desired direction. Then drag a constraint to the barrier

以上是关于markdown 约束到barrier.md的主要内容,如果未能解决你的问题,请参考以下文章

markdown CPU约束命令

markdown 验证约束检查

markdown UI基础知识 - 约束布局

markdown 财产约束

markdown 约束指南.md

markdown 使用约束布局的StaggeredLayoutManager中的宽高比