CalendarSupport
freeperiodmodel.cpp
3 SPDX-FileCopyrightText: 2009-2010 Klaralvdalens Datakonsult AB, a KDAB Group company <info@kdab.net>
89KCalendarCore::Period::List FreePeriodModel::splitPeriodsByDay(const KCalendarCore::Period::List &freePeriods)
101 const QDateTime midnight(tmpPeriod.start().date(), QTime(23, 59, 59, 999), tmpPeriod.start().timeZone());
134 const QString startTime = QLocale::system().toString(period.start().time(), QLocale::ShortFormat);
156 const QString longMonthName = QLocale::system().monthName(startDate.month(), QLocale::LongFormat);
157 const QString dayofWeek = QLocale::system().dayName(startDate.dayOfWeek(), QLocale::LongFormat);
176 toolTip += QLatin1StringView("<b>") + i18nc("@info:tooltip", "Free Period") + QLatin1StringView("</b>");
178 toolTip += QLatin1StringView("<i>") + i18nc("@info:tooltip period start time", "Start:") + QLatin1StringView("</i> ");
181 toolTip += QLatin1StringView("<i>") + i18nc("@info:tooltip period end time", "End:") + QLatin1StringView("</i> ");
184 toolTip += QLatin1StringView("<i>") + i18nc("@info:tooltip period duration", "Duration:") + QLatin1StringView("</i> ");
int asSeconds() const
QDateTime end() const
Duration duration() const
QDateTime start() const
QString formatSpelloutDuration(quint64 msecs) const
QString toString() const
KLocalizedString subs(const KLocalizedString &a, int fieldWidth=0, QChar fillChar=QLatin1Char(' ')) const
QString i18nc(const char *context, const char *text, const TYPE &arg...)
KLocalizedString KI18N_EXPORT ki18nc(const char *context, const char *text)
void beginResetModel()
void endResetModel()
bool hasIndex(int row, int column, const QModelIndex &parent) const const
virtual QVariant headerData(int section, Qt::Orientation orientation, int role) const const
virtual QModelIndex index(int row, int column, const QModelIndex &parent) const const override
int day() const const
int dayOfWeek() const const
int month() const const
QDate date() const const
QTime time() const const
QTimeZone timeZone() const const
QDateTime toLocalTime() const const
const_reference at(qsizetype i) const const
iterator begin()
void clear()
iterator end()
iterator erase(const_iterator begin, const_iterator end)
qsizetype size() const const
LongFormat
QString dayName(int day, FormatType type) const const
QString monthName(int month, FormatType type) const const
QLocale system()
QString toString(QDate date, FormatType format) const const
int column() const const
bool isValid() const const
int row() const const
QObject * parent() const const
AlignRight
DisplayRole
Orientation
QVariant fromValue(T &&value)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:13:02 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:13:02 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.