Libkleo
expiration.cpp
47 range.maximum = std::min(std::max(today.addDays(maximumExpiry), range.minimum), maximumAllowedDate());
53QDate Kleo::Expiration::defaultExpirationDate(Kleo::Expiration::ExpirationOnUnlimitedValidity onUnlimitedValidity)
61 } else if (defaultExpirationInDays < 0 || onUnlimitedValidity == ExpirationOnUnlimitedValidity::InternalDefaultExpiration) {
102 return i18nc("@label Valid until (<a date>):", "Valid until (%1):", dateToString(dateRange.minimum));
107 dateToString(dateRange.maximum.isValid() ? dateRange.maximum : Expiration::maximumAllowedDate()));
136void Kleo::Expiration::setUpExpirationDateComboBox(KDateComboBox *dateCB, const Kleo::Expiration::DateRange &range)
140 dateCB->setOptions(KDateComboBox::EditDate | KDateComboBox::SelectDate | KDateComboBox::DatePicker | KDateComboBox::DateKeywords
143 dateCB->setDateRange(dateRange.minimum, dateRange.maximum.isValid() ? dateRange.maximum : maximumAllowedDate(), hintAndErrorMessage, hintAndErrorMessage);
void setOptions(Options options)
SelectDate
DateKeywords
WarnOnInvalid
EditDate
DatePicker
void setDateMap(QMap< QDate, QString > dateMap)
void setDateRange(const QDate &minDate, const QDate &maxDate, const QString &minWarnMsg=QString(), const QString &maxWarnMsg=QString())
QString i18nc(const char *context, const char *text, const TYPE &arg...)
KCALUTILS_EXPORT QString dateToString(QDate date, bool shortfmt=true)
const QList< QKeySequence > & replace()
QDate addDays(qint64 ndays) const const
QDate addYears(int nyears) const const
QDate currentDate()
bool isValid(int year, int month, int day)
ShortFormat
QString toString(QDate date, FormatType format) const const
void setToolTip(const QString &)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:56:14 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:56:14 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.