Hi guys, i'm working whit RUI DataGrid in my handler.
This is the code:
grid DataGrid {
marginLeft=20,
behaviors = [
],
headerBehaviors = [
intesta
],
columns = [
new DataGridColumn { name = "Col1", displayName = "aaaaaaaaaaaaaaaa<br/>aaaaaaaaaaaaaaaa", width = 80, headerAlignment = DataGridLib.ALIGN_CENTER, alignment = DataGridLib.ALIGN_CENTER}
selectionMode = DataGridLib.DISABLE_SELECTION, enableSorting = no,
pageSize = 15,
showScrollbar = yes,
showButtonBar = no,
style = "overflow-x: scroll; overflow-y: scroll;",
data = (consumi as any[])
};
function intesta(grid DataGrid in, cell Widget in, row any in, rowNumber int in, column DataGridColumn in)
cell.height = "50px";
headText TextField{
children = [
new HTML{text = "aaaaaaaaaaaaaaaa<br/>aaaaaaaaaaaaaaaa"}
],
class = "wrap"
};
column.displayName = headText.innerHTML;
end
CSS style
.wrap{
white-space: -o-pre-wrap;
word-wrap: break-word;
white-space: pre-wrap;
white-space: -moz-pre-wrap;
white-space: -pre-wrap;
}
How do I get have the wrap text and does not increase the width of the column?
Thanks
Matteo@MR