2019-09-10 02:37:01 +10:00
|
|
|
import QtQuick.Controls 2.12
|
|
|
|
import QtQuick 2.12
|
|
|
|
|
|
|
|
|
|
|
|
Repeater {
|
|
|
|
id: repeater
|
|
|
|
|
|
|
|
readonly property int childrenImplicitWidth: {
|
|
|
|
let total = 0
|
|
|
|
|
|
|
|
for (let i = 0; i < repeater.count; i++) {
|
2019-09-20 05:49:29 +10:00
|
|
|
let item = repeater.itemAt(i)
|
2019-11-10 01:48:05 +11:00
|
|
|
if (item && item.implicitWidth) total += item.implicitWidth
|
2019-09-20 05:49:29 +10:00
|
|
|
}
|
|
|
|
|
|
|
|
return total
|
|
|
|
}
|
|
|
|
|
|
|
|
readonly property int childrenWidth: {
|
|
|
|
let total = 0
|
|
|
|
|
|
|
|
for (let i = 0; i < repeater.count; i++) {
|
|
|
|
let item = repeater.itemAt(i)
|
|
|
|
if (item && item.width) total += item.width
|
2019-09-10 02:37:01 +10:00
|
|
|
}
|
|
|
|
|
|
|
|
return total
|
|
|
|
}
|
|
|
|
}
|