简体   繁体   English

推送,增长和填充MigLayout有什么区别?

[英]What is the difference between push, grow, and fill in MigLayout?

I see that grow and push accept an optional weighting parameter, but apart from that: what is the real difference between grow, fill, and push? 我看到growpush接受一个可选的权重参数,但除此之外:grow,fill和push之间的真正区别是什么? The documentation isn't very clear about that. 该文档对此不太清楚。

push affects only gaps, not elements, as far as I know. 据我所知, push只会影响差距,而不会影响元素。 If a component is set to fill , this means to set all subcomponents to grow , while grow affects the component directly. 如果将组件设置为fill ,则意味着将所有子组件设置为grow ,而grow直接影响该组件。

The push constraint does affect elements. push约束确实会影响元素。 It is only one of its contexts where it makes gaps greedy. 它只是使空隙变得贪婪的背景之一。

The answer is a bit more complex. 答案要复杂一些。 I have provided it in a more recent question . 我在最近的一个问题中提供了它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM