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

okular

  • Okular
  • TextDocumentConverter
Signals | Public Member Functions | Protected Member Functions | List of all members
Okular::TextDocumentConverter Class Reference

#include <textdocumentgenerator.h>

Inheritance diagram for Okular::TextDocumentConverter:
Inheritance graph
[legend]

Signals

void addAction (Action *link, int cursorBegin, int cursorEnd)
 
void addAnnotation (Annotation *annotation, int cursorBegin, int cursorEnd)
 
void addMetaData (const QString &key, const QString &value, const QString &title)
 
void addMetaData (DocumentInfo::Key key, const QString &value)
 
void addTitle (int level, const QString &title, const QTextBlock &position)
 
void error (const QString &message, int duration)
 
void notice (const QString &message, int duration)
 
void warning (const QString &message, int duration)
 

Public Member Functions

 TextDocumentConverter ()
 
 ~TextDocumentConverter ()
 
virtual QTextDocument * convert (const QString &fileName)
 
virtual Document::OpenResult convertWithPassword (const QString &fileName, const QString &password)
 
QTextDocument * document ()
 
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
 
 QObject (QObject *parent, const char *name)
 
virtual  ~QObject ()
 
bool blockSignals (bool block)
 
QObject * child (const char *objName, const char *inheritsClass, bool recursiveSearch) const
 
const QObjectList & children () const
 
const char * className () const
 
bool connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const
 
void deleteLater ()
 
void destroyed (QObject *obj)
 
bool disconnect (const QObject *receiver, const char *method)
 
bool disconnect (const char *signal, const QObject *receiver, const char *method)
 
void dumpObjectInfo ()
 
void dumpObjectTree ()
 
QList< QByteArray > dynamicPropertyNames () const
 
virtual bool event (QEvent *e)
 
virtual bool eventFilter (QObject *watched, QEvent *event)
 
T findChild (const QString &name) const
 
QList< T > findChildren (const QRegExp &regExp) const
 
QList< T > findChildren (const QString &name) const
 
bool inherits (const char *className) const
 
void insertChild (QObject *object)
 
void installEventFilter (QObject *filterObj)
 
bool isA (const char *className) const
 
bool isWidgetType () const
 
void killTimer (int id)
 
virtual const QMetaObject * metaObject () const
 
void moveToThread (QThread *targetThread)
 
const char * name () const
 
const char * name (const char *defaultName) const
 
QString objectName () const
 
QObject * parent () const
 
QVariant property (const char *name) const
 
void removeChild (QObject *object)
 
void removeEventFilter (QObject *obj)
 
void setName (const char *name)
 
void setObjectName (const QString &name)
 
void setParent (QObject *parent)
 
bool setProperty (const char *name, const QVariant &value)
 
bool signalsBlocked () const
 
int startTimer (int interval)
 
QThread * thread () const
 

Protected Member Functions

DocumentViewport calculateViewport (QTextDocument *document, const QTextBlock &block)
 
TextDocumentGenerator * generator () const
 
void setDocument (QTextDocument *document)
 
- Protected Member Functions inherited from QObject
bool checkConnectArgs (const char *signal, const QObject *object, const char *method)
 
virtual void childEvent (QChildEvent *event)
 
virtual void connectNotify (const char *signal)
 
virtual void customEvent (QEvent *event)
 
virtual void disconnectNotify (const char *signal)
 
int receivers (const char *signal) const
 
QObject * sender () const
 
int senderSignalIndex () const
 
virtual void timerEvent (QTimerEvent *event)
 

Additional Inherited Members

- Static Public Member Functions inherited from QObject
bool connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
 
bool connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
 
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
 
QString tr (const char *sourceText, const char *disambiguation, int n)
 
QString trUtf8 (const char *sourceText, const char *disambiguation, int n)
 
- Static Protected Member Functions inherited from QObject
QByteArray normalizeSignalSlot (const char *signalSlot)
 
- Properties inherited from QObject
 objectName
 

Detailed Description

Definition at line 29 of file textdocumentgenerator.h.

Constructor & Destructor Documentation

TextDocumentConverter::TextDocumentConverter ( )

Creates a new generic converter.

Generic Converter Implementation.

Definition at line 38 of file textdocumentgenerator.cpp.

TextDocumentConverter::~TextDocumentConverter ( )

Destroys the generic converter.

Definition at line 43 of file textdocumentgenerator.cpp.

Member Function Documentation

void Okular::TextDocumentConverter::addAction ( Action *  link,
int  cursorBegin,
int  cursorEnd 
)
signal

Adds a new link object which is located between cursorBegin and cursorEnd to the generator.

void Okular::TextDocumentConverter::addAnnotation ( Annotation *  annotation,
int  cursorBegin,
int  cursorEnd 
)
signal

Adds a new annotation object which is located between cursorBegin and cursorEnd to the generator.

void Okular::TextDocumentConverter::addMetaData ( const QString &  key,
const QString &  value,
const QString &  title 
)
signal

Adds a set of meta data to the generator.

void Okular::TextDocumentConverter::addMetaData ( DocumentInfo::Key  key,
const QString &  value 
)
signal

Adds a set of meta data to the generator.

Since
0.7 (KDE 4.1)
void Okular::TextDocumentConverter::addTitle ( int  level,
const QString &  title,
const QTextBlock &  position 
)
signal

Adds a new title at the given level which is located as position to the generator.

DocumentViewport TextDocumentConverter::calculateViewport ( QTextDocument *  document,
const QTextBlock &  block 
)
protected

This method can be used to calculate the viewport for a given text block.

Note
This method should be called at the end of the convertion, because it triggers QTextDocument to do the layout calculation.

Definition at line 70 of file textdocumentgenerator.cpp.

QTextDocument * TextDocumentConverter::convert ( const QString &  fileName)
virtual

Returns the generated QTextDocument object.

Note
there is no need to implement this one if you implement convertWithPassword

Definition at line 48 of file textdocumentgenerator.cpp.

Document::OpenResult TextDocumentConverter::convertWithPassword ( const QString &  fileName,
const QString &  password 
)
virtual

Returns the generated QTextDocument object.

Definition at line 53 of file textdocumentgenerator.cpp.

QTextDocument * TextDocumentConverter::document ( )

Returns the generated QTextDocument object.

Will be null if convert didn't succeed

Definition at line 60 of file textdocumentgenerator.cpp.

void Okular::TextDocumentConverter::error ( const QString &  message,
int  duration 
)
signal

This signal should be emitted whenever an error occurred in the converter.

Parameters
messageThe message which should be shown to the user.
durationThe time that the message should be shown to the user.
TextDocumentGenerator * TextDocumentConverter::generator ( ) const
protected

Returns the generator that owns this converter.

Note
May be null if the converter was not created for a generator.
Since
0.7 (KDE 4.1)

Definition at line 75 of file textdocumentgenerator.cpp.

void Okular::TextDocumentConverter::notice ( const QString &  message,
int  duration 
)
signal

This signal should be emitted whenever the user should be noticed.

Parameters
messageThe message which should be shown to the user.
durationThe time that the message should be shown to the user.
void TextDocumentConverter::setDocument ( QTextDocument *  document)
protected

Sets the converted QTextDocument object.

Definition at line 65 of file textdocumentgenerator.cpp.

void Okular::TextDocumentConverter::warning ( const QString &  message,
int  duration 
)
signal

This signal should be emitted whenever the user should be warned.

Parameters
messageThe message which should be shown to the user.
durationThe time that the message should be shown to the user.

The documentation for this class was generated from the following files:
  • textdocumentgenerator.h
  • textdocumentgenerator.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:19:26 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

okular

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

kdegraphics API Reference

Skip menu "kdegraphics API Reference"
  •     libkdcraw
  •     libkexiv2
  •     libkipi
  •     libksane
  • okular

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