MauiKit Calendar
6#include "hourlyincidencemodel.h"
7#include "multidayincidencemodel.h"
8#include <Akonadi/ETMCalendar>
17 Q_PROPERTY(
int datesToAdd READ datesToAdd WRITE setDatesToAdd NOTIFY datesToAddChanged)
18 Q_PROPERTY(
int scale READ scale WRITE setScale NOTIFY scaleChanged)
19 Q_PROPERTY(QStringList hourlyViewLocalisedHourLabels MEMBER m_hourlyViewLocalisedHourLabels CONSTANT)
23 enum Scale { DayScale, ThreeDayScale, WeekScale, MonthScale, YearScale, DecadeScale };
34 explicit InfiniteCalendarViewModel(
QObject *
parent =
nullptr);
35 ~InfiniteCalendarViewModel()
override =
default;
38 QVariant data(
const QModelIndex &idx,
int role)
const override;
39 QHash<int, QByteArray> roleNames()
const override;
40 int rowCount(
const QModelIndex &
parent = {})
const override;
42 Q_INVOKABLE void addDates(
bool atEnd,
const QDate startFrom = QDate());
43 void addDayDates(
bool atEnd,
const QDate &startFrom,
int amount = 1);
44 void addWeekDates(
bool atEnd,
const QDate &startFrom);
45 void addMonthDates(
bool atEnd,
const QDate &startFrom);
46 void addYearDates(
bool atEnd,
const QDate &startFrom);
47 void addDecadeDates(
bool atEnd,
const QDate &startFrom);
49 int datesToAdd()
const;
50 void setDatesToAdd(
int datesToAdd);
53 void setScale(
int scale);
56 void datesToAddChanged();
60 QVector<QDate> m_startDates;
61 QVector<QDate> m_firstDayOfMonthDates;
62 QStringList m_hourlyViewLocalisedHourLabels;
64 int m_datesToAdd = 10;
65 int m_scale = MonthScale;
virtual QModelIndex parent(const QModelIndex &index) const const=0
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 24 2025 11:47:16 by
doxygen 1.13.2 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.