开发者

Whats the diff between setting top=0,bottom=0,left=0,right=0 OR width=100% , height=100%

the child component can take all its 开发者_Go百科parent width and height by setting its properties

top=0,right=0,bottom=0,left=0

But same can be done by setting the child component properties

width=100%,height=100%

so whats the difference between these two approaches ?? plz give advantages/disadvantages if possible .thx in advance.


They both have the same effect in a BasicLayout. The only different might be in performance. In other layouts like VerticalLayout and HorizontalLayout I don't think the constraints (top, right, etc) have any effect, but the percentage values do.


Measuring GraphicElements with strokes is slightly different between using width/height and constraints. This blog post explains in more detail: http://flexponential.com/2010/03/14/measuring-a-graphicelement-with-a-stroke-in-a-group/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜