• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.10.5 API Reference
  • KDE Home
  • Contact Us
 

KCal Library

  • KCal
  • IncidenceFormatter
Functions
KCal::IncidenceFormatter Namespace Reference

Functions

KCAL_EXPORT_DEPRECATED QString dateTimeToString (const KDateTime &date, bool dateOnly=false, bool shortfmt=true, const KDateTime::Spec &spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString dateToString (const KDateTime &date, bool shortfmt=true, const KDateTime::Spec &spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString durationString (Incidence *incidence)
 
KCAL_EXPORT_DEPRECATED QString extensiveDisplayStr (Calendar *calendar, IncidenceBase *incidence, const QDate &date=QDate(), KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString extensiveDisplayStr (const QString &sourceName, IncidenceBase *incidence, const QDate &date=QDate(), KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString extensiveDisplayStr (IncidenceBase *incidence, KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString extensiveDisplayString (IncidenceBase *incidence)
 
KCAL_EXPORT_DEPRECATED QString formatICalInvitation (QString invitation, Calendar *calendar, InvitationFormatterHelper *helper)
 
KCAL_EXPORT_DEPRECATED QString formatICalInvitationNoHtml (QString invitation, Calendar *calendar, InvitationFormatterHelper *helper)
 
KCAL_EXPORT_DEPRECATED QString formatICalInvitationNoHtml (const QString &invitation, Calendar *calendar, InvitationFormatterHelper *helper, const QString &sender)
 
KCAL_EXPORT_DEPRECATED QString formatTNEFInvitation (const QByteArray &tnef, Calendar *mCalendar, InvitationFormatterHelper *helper)
 
KCAL_EXPORT_DEPRECATED QString mailBodyStr (IncidenceBase *incidence, KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString mailBodyString (IncidenceBase *incidence)
 
KCAL_EXPORT_DEPRECATED QString msTNEFToVPart (const QByteArray &tnef)
 
KCAL_EXPORT_DEPRECATED QString recurrenceString (Incidence *incidence)
 
KCAL_EXPORT_DEPRECATED QStringList reminderStringList (Incidence *incidence, bool shortfmt=true)
 
KCAL_EXPORT_DEPRECATED QString resourceString (Calendar *calendar, Incidence *incidence)
 
KCAL_EXPORT_DEPRECATED QString timeToString (const KDateTime &date, bool shortfmt=true, const KDateTime::Spec &spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString toolTipStr (Calendar *calendar, IncidenceBase *incidence, const QDate &date=QDate(), bool richText=true, KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString toolTipStr (const QString &sourceName, IncidenceBase *incidence, const QDate &date=QDate(), bool richText=true, KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString toolTipStr (IncidenceBase *incidence, bool richText=true, KDateTime::Spec spec=KDateTime::Spec())
 
KCAL_EXPORT_DEPRECATED QString toolTipString (IncidenceBase *incidence, bool richText=true)
 

Detailed Description

Provides methods to format Incidences in various ways for display purposes.

Helpers that provides several static methods to format an Incidence in different ways: like an HTML representation for KMail, a representation for tool tips, or a representation for a viewer widget.

Function Documentation

QString KCal::IncidenceFormatter::dateTimeToString ( const KDateTime &  date,
bool  dateOnly = false,
bool  shortfmt = true,
const KDateTime::Spec &  spec = KDateTime::Spec() 
)

Build a QString date/time representation of a KDateTime object.

Parameters
dateThe date to be formatted.
dateOnlyIf true, don't print the time fields; print the date fields only.
shortfmtIf true, display info in short format.
specTime spec to use.
See Also
dateToString(), timeToString().
Since
4.3

Definition at line 3759 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::dateToString ( const KDateTime &  date,
bool  shortfmt = true,
const KDateTime::Spec &  spec = KDateTime::Spec() 
)

Build a QString date representation of a KDateTime object.

Parameters
dateThe date to be formatted.
shortfmtIf true, display info in short format.
specTime spec to use.
See Also
dateToString(), dateTimeToString().
Since
4.3

Definition at line 3737 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::durationString ( Incidence *  incidence)

Returns a duration string computed for the specified Incidence.

Only makes sense for Events and Todos.

Parameters
incidenceis a pointer to the Incidence.
Since
4.5

Definition at line 3834 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::extensiveDisplayStr ( Calendar *  calendar,
IncidenceBase *  incidence,
const QDate &  date = QDate(),
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a RichText QString representation of an Incidence in a nice format suitable for using in a viewer widget.

Parameters
calendaris a pointer to the Calendar that owns the specified Incidence.
incidenceis a pointer to the Incidence to be formatted.
dateis the QDate for which the string representation should be computed; used mainly for recurring incidences.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.4

Definition at line 991 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::extensiveDisplayStr ( const QString &  sourceName,
IncidenceBase *  incidence,
const QDate &  date = QDate(),
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a RichText QString representation of an Incidence in a nice format suitable for using in a viewer widget.

Parameters
sourceNamewhere the incidence is from (e.g. resource name)
incidenceis a pointer to the Incidence to be formatted.
dateis the QDate for which the string representation should be computed; used mainly for recurring incidences.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.5

Definition at line 1008 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::extensiveDisplayStr ( IncidenceBase *  incidence,
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a RichText QString representation of an Incidence in a nice format suitable for using in a viewer widget.

Parameters
incidenceis a pointer to the Incidence to be formatted.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.2
Deprecated:
use extensiveDisplayStr( Calendar *, IncidenceBase *, KDateTime::Spec )

Definition at line 976 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::extensiveDisplayString ( IncidenceBase *  incidence)

Create a RichText QString representation of an Incidence in a nice format suitable for using in a viewer widget.

Parameters
incidenceis a pointer to the Incidence to be formatted.
Deprecated:
use extensiveDisplayStr( Calendar *, IncidenceBase *, KDateTime::Spec )

Definition at line 971 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::formatICalInvitation ( QString  invitation,
Calendar *  calendar,
InvitationFormatterHelper *  helper 
)

Deliver an HTML formatted string displaying an invitation.

Use the time zone from mCalendar.

Parameters
invitationa QString containing a string representation of a calendar Event which will be intrepreted as an invitation.
calendaris a pointer to the Calendar that owns the invitation.
helperis a pointer to an InvitationFormatterHelper.

Definition at line 2743 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::formatICalInvitationNoHtml ( QString  invitation,
Calendar *  calendar,
InvitationFormatterHelper *  helper 
)

Deliver an HTML formatted string displaying an invitation.

Differs from formatICalInvitation() in that invitation details (summary, location, etc) have HTML formatting cleaned. Use the time zone from calendar.

Parameters
invitationa QString containing a string representation of a calendar Event which will be intrepreted as an invitation.
calendaris a pointer to the Calendar that owns the invitation.
helperis a pointer to an InvitationFormatterHelper.
Deprecated:
use formatICalInvitationNoHtml(const QString &,Calendar *, InvitationFormatterHelper *,const QString &) instead.

Definition at line 2751 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::formatICalInvitationNoHtml ( const QString &  invitation,
Calendar *  calendar,
InvitationFormatterHelper *  helper,
const QString &  sender 
)

Deliver an HTML formatted string displaying an invitation.

Differs from formatICalInvitation() in that invitation details (summary, location, etc) have HTML formatting cleaned. Use the time zone from calendar.

Parameters
invitationa QString containing a string representation of a calendar Event which will be intrepreted as an invitation.
calendaris a pointer to the Calendar that owns the invitation.
helperis a pointer to an InvitationFormatterHelper.
senderis a QString containing the email address of the person sending the invitation.
Since
4.5

Definition at line 2759 of file incidenceformatter.cpp.

KCAL_EXPORT_DEPRECATED QString KCal::IncidenceFormatter::formatTNEFInvitation ( const QByteArray &  tnef,
Calendar *  mCalendar,
InvitationFormatterHelper *  helper 
)

Format a TNEF attachment to an HTML mail.

Since
4.1
QString KCal::IncidenceFormatter::mailBodyStr ( IncidenceBase *  incidence,
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a QString representation of an Incidence in format suitable for including inside a mail message.

Parameters
incidenceis a pointer to the Incidence to be formatted.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.2

Definition at line 3378 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::mailBodyString ( IncidenceBase *  incidence)

Create a QString representation of an Incidence in format suitable for including inside a mail message.

Parameters
incidenceis a pointer to the Incidence to be formatted.
Deprecated:
use mailBodyStr( IncidenceBase *, KDateTime::Spec )

Definition at line 3373 of file incidenceformatter.cpp.

KCAL_EXPORT_DEPRECATED QString KCal::IncidenceFormatter::msTNEFToVPart ( const QByteArray &  tnef)

Transform a TNEF attachment to an iCal or vCard.

Since
4.1
QString KCal::IncidenceFormatter::recurrenceString ( Incidence *  incidence)

Build a pretty QString representation of an Incidence's recurrence info.

Parameters
incidenceis a pointer to the Incidence whose recurrence info is to be formatted.
Since
4.1

Definition at line 3409 of file incidenceformatter.cpp.

QStringList KCal::IncidenceFormatter::reminderStringList ( Incidence *  incidence,
bool  shortfmt = true 
)

Returns a reminder string computed for the specified Incidence.

Each item of the returning QStringList corresponds to a string representation of an reminder belonging to this incidence.

Parameters
incidenceis a pointer to the Incidence.
shortfmtif false, a short version of each reminder is printed; else a longer version of each reminder is printed.
Since
4.5

Definition at line 3865 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::resourceString ( Calendar *  calendar,
Incidence *  incidence 
)

Returns a Calendar Resource label name for the specified Incidence.

Parameters
calendaris a pointer to the Calendar.
incidenceis a pointer to the Incidence.
Since
4.4

Definition at line 3784 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::timeToString ( const KDateTime &  date,
bool  shortfmt = true,
const KDateTime::Spec &  spec = KDateTime::Spec() 
)

Build a QString time representation of a KDateTime object.

Parameters
dateThe date to be formatted.
shortfmtIf true, display info in short format.
specTime spec to use.
See Also
dateToString(), dateTimeToString().
Since
4.3

Definition at line 3720 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::toolTipStr ( Calendar *  calendar,
IncidenceBase *  incidence,
const QDate &  date = QDate(),
bool  richText = true,
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a QString representation of an Incidence in a nice format suitable for using in a tooltip.

Parameters
incidenceis a pointer to the Incidence to be formatted.
dateis the QDate for which the toolTip should be computed; used mainly for recurring incidences.
richTextif yes, the QString will be created as RichText.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.4

Definition at line 3198 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::toolTipStr ( const QString &  sourceName,
IncidenceBase *  incidence,
const QDate &  date = QDate(),
bool  richText = true,
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a QString representation of an Incidence in a nice format suitable for using in a tooltip.

Parameters
sourceNamewhere the incidence is from (e.g. resource name)
incidenceis a pointer to the Incidence to be formatted.
dateis the QDate for which the toolTip should be computed; used mainly for recurring incidences.
richTextif yes, the QString will be created as RichText.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.5

Definition at line 3211 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::toolTipStr ( IncidenceBase *  incidence,
bool  richText = true,
KDateTime::Spec  spec = KDateTime::Spec() 
)

Create a QString representation of an Incidence in a nice format suitable for using in a tooltip.

Parameters
incidenceis a pointer to the Incidence to be formatted.
richTextif yes, the QString will be created as RichText.
specis an optional time specification which, when specified, will shift the Incidence times to different timezones.
Since
4.2
Deprecated:
use toolTipStr( Calendar *, IncidenceBase *, bool, KDateTime::Spec)

Definition at line 3187 of file incidenceformatter.cpp.

QString KCal::IncidenceFormatter::toolTipString ( IncidenceBase *  incidence,
bool  richText = true 
)

Create a QString representation of an Incidence in a nice format suitable for using in a tooltip.

Parameters
incidenceis a pointer to the Incidence to be formatted.
richTextif yes, the QString will be created as RichText.
Deprecated:
use toolTipStr( Calendar *, IncidenceBase *, bool, KDateTime::Spec)

Definition at line 3181 of file incidenceformatter.cpp.

This file is part of the KDE documentation.
Documentation copyright © 1996-2013 The KDE developers.
Generated on Sat Jul 13 2013 01:29:21 by doxygen 1.8.3.1 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KCal Library

Skip menu "KCal Library"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Related Pages

kdepimlibs-4.10.5 API Reference

Skip menu "kdepimlibs-4.10.5 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal