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

KCalUtils Library

  • sources
  • kde-4.12
  • kdepimlibs
  • kcalutils
htmlexport.h
1 /*
2  This file is part of the kcalutils library.
3 
4  Copyright (c) 2000-2003 Cornelius Schumacher <schumacher@kde.org>
5  Copyright (C) 2004 Reinhold Kainhofer <reinhold@kainhofer.com>
6 
7  This library is free software; you can redistribute it and/or
8  modify it under the terms of the GNU Library General Public
9  License as published by the Free Software Foundation; either
10  version 2 of the License, or (at your option) any later version.
11 
12  This library is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  Library General Public License for more details.
16 
17  You should have received a copy of the GNU Library General Public License
18  along with this library; see the file COPYING.LIB. If not, write to
19  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20  Boston, MA 02110-1301, USA.
21 */
22 #ifndef KCALUTILS_HTMLEXPORT_H
23 #define KCALUTILS_HTMLEXPORT_H
24 
25 #include "kcalutils_export.h"
26 
27 #include <kcalcore/event.h>
28 #include <kcalcore/incidence.h>
29 #include <kcalcore/todo.h>
30 
31 #include <QtCore/QDateTime>
32 #include <QtCore/QString>
33 
34 namespace KCalCore {
35 class MemoryCalendar;
36 }
37 
38 class QTextStream;
39 
40 namespace KCalUtils {
41 
42 class HTMLExportSettings;
43 
47 class KCALUTILS_EXPORT HtmlExport
48 {
49 public:
53  HtmlExport(KCalCore::MemoryCalendar *calendar, HTMLExportSettings *settings);
54  virtual ~HtmlExport();
55 
59  bool save(const QString &fileName = QString());
60 
64  bool save(QTextStream *ts);
65 
66  void addHoliday(const QDate &date, const QString &name);
67 
68 protected:
69  void createWeekView(QTextStream *ts);
70  void createMonthView(QTextStream *ts);
71  void createEventList(QTextStream *ts);
72  void createTodoList(QTextStream *ts);
73  void createJournalView(QTextStream *ts);
74  void createFreeBusyView(QTextStream *ts);
75 
76  void createTodo(QTextStream *ts, const KCalCore::Todo::Ptr &todo);
77 
78  void createEvent(QTextStream *ts, const KCalCore::Event::Ptr &event,
79  const QDate &date, bool withDescription = true);
80 
81  void createFooter(QTextStream *ts);
82 
83  bool checkSecrecy(const KCalCore::Incidence::Ptr &incidence);
84 
85  void formatLocation(QTextStream *ts, const KCalCore::Incidence::Ptr &incidence);
86 
87  void formatCategories(QTextStream *ts, const KCalCore::Incidence::Ptr &incidence);
88 
89  void formatAttendees(QTextStream *ts, const KCalCore::Incidence::Ptr &incidence);
90 
91  QString breakString(const QString &text);
92 
93  QDate fromDate() const;
94  QDate toDate() const;
95  QString styleSheet() const;
96 
97 private:
98  //@cond PRIVATE
99  Q_DISABLE_COPY(HtmlExport)
100  class Private;
101  Private *const d;
102  //@endcond
103 };
104 
105 }
106 
107 #endif
KCalCore::Event::Ptr
QSharedPointer< Event > Ptr
KCalUtils::HtmlExport
This class provides the functions to export a calendar as a HTML page.
Definition: htmlexport.h:47
KCalCore::MemoryCalendar
todo.h
event.h
incidence.h
KCalCore::Todo::Ptr
QSharedPointer< Todo > Ptr
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:18 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KCalUtils Library

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

kdepimlibs API Reference

Skip menu "kdepimlibs API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kldap
  • kmbox
  • kmime
  • kpimidentities
  • kpimtextedit
  • kresources
  • ktnef
  • kxmlrpcclient
  • microblog

Search



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