[转]Tips on using&nbsp…
来源:互联网 发布:nginx lua waf 编辑:程序博客网 时间:2024/06/09 19:59
Tips on using the TileLayout in Flex 4.6
Tips on using TileLayout in Flex4.6. I had some difficulty in getting a tile layout to dynamicallyexpand or contract the layout items. This post shows how I solvedit.
To get the items in a TileLayoutto expand to fill all the available space in a List or DataGroupcontainer use the following settings:
<
s:TileLayoutid
=
"tileLayout"
horizontalGap
=
"20"
verticalGap
=
"20"
orientation
=
"columns"
requestedColumnCount
=
"{columnCount}"
rowAlign
=
"justifyUsingHeight"
columnAlign
=
"justifyUsingWidth"
rowHeight
=
"{list.height/ list.dataProvider.length}"
/>
The key is to set the rowHeightto minimum values based on the total number of items. In this casewe are checking the list data provider and making sure the cell isat least that size.* In some cases it works fine without therowHeight line???
When the columnAlign is set toColumnAlign.JUSTIFY_USING_WIDTH the columnWidth actual valueincreases so that the last fully visible column right edge alignswith the container’s right edge. Note that explicitly setting thecolumnWidth property does not turn off justification. It onlydetermines the initial column width value. Justification mayincrease it.
The columnCount is an integerwith the value of 2. You can modify this value to fit yourneeds.
Note: To get all the contents ofa layout item to use all available space set the verticalAlign andhorizontalAligh to justify.
<
s:TileLayoutid
=
"tileLayout"
horizontalAlign
=
"justify"
verticalAlign
=
"justify"
/>
Whenever you set the column countthe layout will be updated and the layout items resized.
<
s:Listid
=
"list"
left
=
"20"
right
=
"20"
top
=
"20"
bottom
=
"20"
width
=
"100%"
height
=
"100%"
labelField
=
"@label"
selectedIndex
=
"-1"
contentBackgroundAlpha
=
"0"
>
- [转]Tips on using&nbsp…
- 转:为何 Emacs 和&nbsp…
- 【转】更新 Mac OS&nbsp…
- [转] Qt属性setProperty & propert…
- [转] Qt属性setProperty & propert…
- weibo 登录&nbsp…
- Android edittext&nbsp…
- !!! FAILED BINDER&nbsp…
- OGNL & ValueStack&…
- LA 5713 Qin&nbsp…
- Convex Hull Algorithms & general…
- [转]Building MPICH2 on…
- [转]Building MPICH2 on…
- INSERT ... ON DUP…
- Configuring FTP on Exadata <转…
- Javascript_DOMContentLoaded&nbsp…
- ApplicationEventMulticaster&nbsp…
- [转] 彼尔…
- jsessionid的作用
- How to get Time Separator in Jav…
- 定制chart的DataTips个性化数据显…
- [转]一名优秀的Flex开发者需要知道…
- flex chart 上添加其他…
- [转]Tips on using&nbsp…
- [转]Flex组件 SuperPanel
- [转]Linux下Sed命令的用法
- [转]FLEX学习之别人的好文章
- [转]Flex 自定义组件外观
- [转]关于Perl文件操作——批量修改文…
- [转]maven核心,pom.xml详解
- [转]mave的依赖范围
- [转]maven常用命令集