Adjust customers table layout - alternate colors for rows 3
This commit is contained in:
@@ -85,8 +85,8 @@ Item {
|
|||||||
model: testTable.model
|
model: testTable.model
|
||||||
}
|
}
|
||||||
|
|
||||||
//columnWidthProvider: function(column)
|
// columnWidthProvider: function(column)
|
||||||
//{
|
// {
|
||||||
// switch (column)
|
// switch (column)
|
||||||
// {
|
// {
|
||||||
// case 0: return width * 0.2;
|
// case 0: return width * 0.2;
|
||||||
@@ -103,10 +103,12 @@ Item {
|
|||||||
Timer
|
Timer
|
||||||
{
|
{
|
||||||
running: true
|
running: true
|
||||||
interval: 100
|
interval: 3000
|
||||||
|
repeat: true
|
||||||
onTriggered:
|
onTriggered:
|
||||||
{
|
{
|
||||||
//testTable.columnWidths[2] = 150
|
//testTable.columnWidths[2] = 150
|
||||||
|
console.log("Timing..")
|
||||||
testTable.forceLayout();
|
testTable.forceLayout();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -124,14 +126,14 @@ Item {
|
|||||||
color: selected
|
color: selected
|
||||||
? "lightblue" //palette.highlight
|
? "lightblue" //palette.highlight
|
||||||
: (testTable.alternatingRows && row % 2 !== 0
|
: (testTable.alternatingRows && row % 2 !== 0
|
||||||
? palette.base
|
? "lightslategray" // palette.base
|
||||||
: palette.alternateBase)
|
: "lightsteelblue") //palette.alternateBase)
|
||||||
|
|
||||||
Text
|
Text
|
||||||
{
|
{
|
||||||
Layout.fillWidth: true
|
//Layout.fillWidth: true
|
||||||
text: model.display
|
text: model.display
|
||||||
//elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
}
|
}
|
||||||
|
|
||||||
MouseArea
|
MouseArea
|
||||||
|
|||||||
Reference in New Issue
Block a user