wordWrap="true" does not work in Flex Datagrid
in Flex Datagrid, I need to support line wrap function in one column. In theory I need to set wordWrap="true" and variableRowHeight="true". It works well.
But the pr开发者_如何学Gooblem is that if in the cloumn I set itemRenderer="lc.monitoring.logviewer.components.CustomColumnRenderer" properties, then the line wrap funciton does not take effect. It seems that the line wrap function can not work with itemRenderer in the datagrid column.
Any one can help me about this.
Don't use Label
- it is for displaying a single line of text.
The
Label
control displays a single line of noneditable text. Use theText
control to create blocks of multiline noneditable text.
mx.controls.Text
supports multiline text and wordwrap
If the control is not as wide as the text, the text will wordwrap. The text is always aligned top-left in the control.
You should try to override measure and updateDisplaylist inside your itemrenderer. Your item renderer does not know how to resize the height in order to allow showing info inside the dg
精彩评论