KAlarm Library
alarmtext.cpp
144 void AlarmText::setEmail(const QString& to, const QString& from, const QString& cc, const QString& time,
290 return d->mFrom.isEmpty() && d->mTo.isEmpty() && d->mCc.isEmpty() && d->mTime.isEmpty() && d->mSubject.isEmpty();
440 dispText = Private::mFromPrefix + lines[MAIL_FROM_LINE].mid(Private::mFromPrefixEn.length()) + QLatin1Char('\n');
441 dispText += Private::mToPrefix + lines[MAIL_TO_LINE].mid(Private::mToPrefixEn.length()) + QLatin1Char('\n');
443 dispText += Private::mCcPrefix + lines[MAIL_CC_LINE].mid(Private::mCcPrefixEn.length()) + QLatin1Char('\n');
444 dispText += Private::mDatePrefix + lines[n].mid(Private::mDatePrefixEn.length()) + QLatin1Char('\n');
480 calText = Private::mFromPrefixEn + lines[MAIL_FROM_LINE].mid(Private::mFromPrefix.length()) + QLatin1Char('\n');
481 calText += Private::mToPrefixEn + lines[MAIL_TO_LINE].mid(Private::mToPrefix.length()) + QLatin1Char('\n');
483 calText += Private::mCcPrefixEn + lines[MAIL_CC_LINE].mid(Private::mCcPrefix.length()) + QLatin1Char('\n');
484 calText += Private::mDatePrefixEn + lines[n].mid(Private::mDatePrefix.length()) + QLatin1Char('\n');
int indexOf(QChar ch, int from, Qt::CaseSensitivity cs) const
QStringList split(const QString &sep, SplitBehavior behavior, Qt::CaseSensitivity cs) const
bool contains(const QString &str, Qt::CaseSensitivity cs) const
QString cc() const
Return the 'Cc' header parameter for an email alarm.
Definition: alarmtext.cpp:241
QString displayText() const
Return the text for a text message alarm, in display format.
Definition: alarmtext.cpp:183
static QString fromCalendarText(const QString &text, bool &email)
Translate an alarm calendar text to a display text.
Definition: alarmtext.cpp:422
QString subject() const
Return the 'Subject' header parameter for an email alarm.
Definition: alarmtext.cpp:251
QString time() const
Return the 'Date' header parameter for an email alarm.
Definition: alarmtext.cpp:246
bool isNull() const
void clear()
int matchedLength() const
int indexIn(const QString &str, int offset, CaretMode caretMode) const
static QString emailHeaders(const QString &text, bool subjectOnly)
Check whether a text is an email (with at least To and From headers), and if so return its headers or...
Definition: alarmtext.cpp:399
bool isTodo() const
Return whether the instance contains the text of a todo.
Definition: alarmtext.cpp:303
int count(const T &value) const
static QString toCalendarText(const QString &text)
Return the text for an alarm message text, in alarm calendar format.
Definition: alarmtext.cpp:462
bool isEmpty() const
unsigned long kmailSerialNumber() const
Return the kmail serial number of an email.
Definition: alarmtext.cpp:308
bool startsWith(const QString &s, Qt::CaseSensitivity cs) const
bool isScript() const
Return whether the instance contains the text of a script.
Definition: alarmtext.cpp:298
void setEmail(const QString &to, const QString &from, const QString &cc, const QString &time, const QString &subject, const QString &body, unsigned long kmailSerialNumber=0)
Set the instance contents to be an email.
Definition: alarmtext.cpp:144
QString from() const
Return the 'From' header parameter for an email alarm.
Definition: alarmtext.cpp:236
void setScript(const QString &text)
Set the instance contents to be a script.
Definition: alarmtext.cpp:138
QString mid(int position, int n) const
int count() const
void setTodo(const KCalCore::Todo::Ptr &todo)
Set the instance contents to be a todo.
Definition: alarmtext.cpp:159
SubAction actionSubType() const
Return the action sub-type of the event's main alarm.
Definition: kaevent.cpp:1987
QList< T > mid(int pos, int length) const
int length() const
static bool checkIfEmail(const QString &text)
Return whether a text is an email, with at least To and From headers.
Definition: alarmtext.cpp:388
QString left(int n) const
bool isEmail() const
Return whether the instance contains the text of an email.
Definition: alarmtext.cpp:293
AlarmText(const QString &text=QString())
Constructor which sets the alarm text.
Definition: alarmtext.cpp:106
QString to() const
Return the 'To' header parameter for an email alarm.
Definition: alarmtext.cpp:231
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:38:49 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:38:49 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.