Shift TimelineView’s items half a day

They are supposed to show how many _nigths_ guests are staying in
lodgins, thus they arrive at afternoon and leave at morning; the shift
puts the starting position at midday.
This commit is contained in:
jordi fita mas 2025-01-20 11:09:07 +01:00
parent b9c68f4b76
commit 8677051303
1 changed files with 1 additions and 1 deletions

View File

@ -9,7 +9,7 @@ struct TimelineView::Item
, day(day) , day(day)
{ {
item->setParentItem(&view); item->setParentItem(&view);
item->setPosition(QPointF(day * view.dayWidth(), 0.0)); item->setPosition(QPointF(day * view.dayWidth() + view.dayWidth() / 2, 0.0));
item->setSize(QSizeF(len * view.dayWidth(), view.height())); item->setSize(QSizeF(len * view.dayWidth(), view.height()));
item->setVisible(true); item->setVisible(true);
} }