forked from Shinonome/dots-hyprland
waffles: make calendar spacing more accurate
This commit is contained in:
@@ -87,7 +87,8 @@ Item {
|
||||
property real verticalPadding: 0
|
||||
property real buttonSize: 40
|
||||
property real buttonSpacing: 2
|
||||
implicitHeight: (6 * buttonSize) + (5 * buttonSpacing) + (2 * verticalPadding)
|
||||
property real buttonVerticalSpacing: buttonSpacing
|
||||
implicitHeight: (6 * buttonSize) + (5 * buttonVerticalSpacing) + (2 * verticalPadding)
|
||||
implicitWidth: weeksColumn.implicitWidth
|
||||
clip: true
|
||||
|
||||
@@ -98,13 +99,13 @@ Item {
|
||||
right: parent.right
|
||||
}
|
||||
y: {
|
||||
const spacePerExtraRow = root.buttonSize + root.buttonSpacing;
|
||||
const spacePerExtraRow = root.buttonSize + root.buttonVerticalSpacing;
|
||||
const origin = -(spacePerExtraRow * root.paddingWeeks);
|
||||
const diff = root.weekDiff * spacePerExtraRow;
|
||||
return origin + (-diff % spacePerExtraRow) + root.verticalPadding;
|
||||
}
|
||||
|
||||
spacing: root.buttonSpacing
|
||||
spacing: root.buttonVerticalSpacing
|
||||
|
||||
Repeater {
|
||||
model: root.totalWeeks
|
||||
|
||||
Reference in New Issue
Block a user