2004-09-08 12:41:14 +00:00
|
|
|
/***************************************************************************
|
2005-02-20 16:04:40 +00:00
|
|
|
* Copyright (C) 2004-2005 by Enrico Ros <eros.kde@email.it> *
|
2005-01-15 01:08:35 +00:00
|
|
|
* Copyright (C) 2004-2005 by Albert Astals Cid <tsdgeos@terra.es> *
|
2004-09-08 12:41:14 +00:00
|
|
|
* *
|
|
|
|
* This program is free software; you can redistribute it and/or modify *
|
|
|
|
* it under the terms of the GNU General Public License as published by *
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or *
|
|
|
|
* (at your option) any later version. *
|
|
|
|
***************************************************************************/
|
|
|
|
|
2006-09-21 08:45:36 +00:00
|
|
|
#ifndef _OKULAR_DOCUMENT_H_
|
|
|
|
#define _OKULAR_DOCUMENT_H_
|
2004-09-08 12:41:14 +00:00
|
|
|
|
2007-01-03 14:30:48 +00:00
|
|
|
#include <okular/core/okular_export.h>
|
|
|
|
#include <okular/core/area.h>
|
|
|
|
#include <okular/core/global.h>
|
2007-01-05 23:12:06 +00:00
|
|
|
#include <okular/core/pagesize.h>
|
2006-05-08 20:12:04 +00:00
|
|
|
|
2006-09-21 08:45:36 +00:00
|
|
|
#include <QtCore/QObject>
|
|
|
|
#include <QtCore/QStringList>
|
|
|
|
#include <QtCore/QVector>
|
|
|
|
#include <QtXml/QDomDocument>
|
|
|
|
|
2005-11-04 11:59:51 +00:00
|
|
|
#include <kmimetype.h>
|
2004-09-08 12:41:14 +00:00
|
|
|
|
2007-03-07 18:15:00 +00:00
|
|
|
class KComponentData;
|
2006-12-27 16:04:49 +00:00
|
|
|
class KBookmark;
|
2007-01-28 15:46:10 +00:00
|
|
|
class KConfigDialog;
|
2005-01-02 14:55:14 +00:00
|
|
|
class KPrinter;
|
2007-01-02 16:11:40 +00:00
|
|
|
class KPrintDialogPage;
|
2006-03-20 22:51:56 +00:00
|
|
|
class KUrl;
|
- Page/Link: tooltips for links backported
- Page: rotation does not switch height and width
- Document/Part/Generator:
1. Add API for attaching stuff to the interface: ActionCollection and the Navigation Panel
also add possibility to merge an XML .rc file with menu layout. Relevant functions are:
QString Generator::getXMLFile(), returns a QString with your .rc file name.
void Generator::setupGUI (KActionCollection* , QToolbox* ), add your components to the user interface
2. Supporting backend settings:
If during startup, backends which provide a configuration ([X-KDE-oKularHasInternalSettings]
set to true) are found, a menu item: configure backends is created, clicking on it results in
loading all the generators that have settings, but not those that dont. the Generator::addPages(KConfigDialog *dlg)
function should be overloaded by a generator and dlg->addPage should be used to add pages.
If a user opens a file that needs an already loaded generator, the already loaded one is used instead of loading another.
3. Error/Warning/Notice sending support, to send a notice/error/warning, add a relevant notice/error/warning(QString& txt ,int duration)
to the generator class, and sending a message to the user is as simple as emitting a signal!
4. Intercepting of events generated by the PageView is done by Generator::handleEvent(QEvent*), subclass it, do a switch on QEvent::type(), handle your
event and return true if pageview is to proceed with its handling or false if not.
5. Support configuring the KPrinter on the generator side, use Generator::canConfigurePrinter(), return true there, and you get a nonconfigured KPrinter in your
Generator::print()
6. PixmapRequest handling update:
a.) Generator::canGeneratePixmap is now Generator::canGeneratePixmap(bool async)
b.) Document::sendGeneratorRequests is a slot now
c.) Old way of sending pixmaps (Document::requestPixmaps(QValueList<PixmapRequest*> checking if we can generate pixmap if not, waiting for receiving)
is replaced with: requestPixmaps only queues the pixmap all checking if w can generate is done in sendGeneratorReqest, the sendGeneratorRequest is
run in three places:
1. in requestPixmaps when we receive a request
2. in requestDone if pixmapStack is not empty
3. sendGeneratorRequest, apart from removing invalid requests, takes the current request and if generator canGeratePixmap(request->async)
it removes the pixmap from stack and sends to generator if not, QTimer::singleshots to itself after 20ms, it ends when stack has no valid pixmap request
7. Added a commented out zoom field to PixmapGenerator, mightcome in handy sometime
- TextPage: add instructions that handle simplyfing the RegularAreaRect, no more double painted borders in selection rectangles, this rocks.
svn path=/trunk/playground/graphics/oKular/kpdf/; revision=445196
2005-08-10 16:14:39 +00:00
|
|
|
class KActionCollection;
|
|
|
|
class QToolBox;
|
2006-09-21 08:45:36 +00:00
|
|
|
|
|
|
|
namespace Okular {
|
|
|
|
|
|
|
|
class Annotation;
|
2006-12-27 16:04:49 +00:00
|
|
|
class BookmarkManager;
|
2006-09-21 08:45:36 +00:00
|
|
|
class DocumentFonts;
|
|
|
|
class DocumentInfo;
|
|
|
|
class DocumentObserver;
|
2007-04-14 19:44:07 +00:00
|
|
|
class DocumentPrivate;
|
2006-09-21 08:45:36 +00:00
|
|
|
class DocumentSynopsis;
|
|
|
|
class DocumentViewport;
|
|
|
|
class EmbeddedFile;
|
2006-10-25 15:35:53 +00:00
|
|
|
class ExportFormat;
|
2006-09-21 08:45:36 +00:00
|
|
|
class Generator;
|
|
|
|
class Link;
|
|
|
|
class Page;
|
|
|
|
class PixmapRequest;
|
2006-11-17 22:15:15 +00:00
|
|
|
class SourceReference;
|
2006-06-23 21:11:52 +00:00
|
|
|
class VisiblePageRect;
|
2004-09-08 12:41:14 +00:00
|
|
|
|
2006-05-28 15:54:48 +00:00
|
|
|
/** IDs for seaches. Globally defined here. **/
|
|
|
|
#define PART_SEARCH_ID 1
|
|
|
|
#define PAGEVIEW_SEARCH_ID 2
|
|
|
|
#define SW_SEARCH_ID 3
|
2007-03-17 22:58:41 +00:00
|
|
|
#define PRESENTATION_SEARCH_ID 4
|
2006-05-28 15:54:48 +00:00
|
|
|
|
|
|
|
|
2004-09-08 12:41:14 +00:00
|
|
|
/**
|
2004-12-11 17:25:03 +00:00
|
|
|
* @short The Document. Heart of everything. Actions take place here.
|
2004-09-08 12:41:14 +00:00
|
|
|
*
|
2006-09-21 08:45:36 +00:00
|
|
|
* The Document is the main object in Okular. All views query the Document to
|
2004-12-11 17:25:03 +00:00
|
|
|
* get data/properties or even for accessing pages (in a 'const' way).
|
|
|
|
*
|
|
|
|
* It is designed to keep it detached from the document type (pdf, ps, you
|
|
|
|
* name it..) so whenever you want to get some data, it asks its internals
|
|
|
|
* generator to do the job and return results in a format-indepedent way.
|
|
|
|
*
|
|
|
|
* Apart from the generator (the currently running one) the document stores
|
2006-09-21 08:45:36 +00:00
|
|
|
* all the Pages ('Page' class) of the current document in a vector and
|
2004-12-11 17:25:03 +00:00
|
|
|
* notifies all the registered DocumentObservers when some content changes.
|
|
|
|
*
|
|
|
|
* For a better understanding of hieracies @see README.internals.png
|
2006-09-21 08:45:36 +00:00
|
|
|
* @see DocumentObserver, Page
|
2004-09-08 12:41:14 +00:00
|
|
|
*/
|
2006-09-21 08:45:36 +00:00
|
|
|
class OKULAR_EXPORT Document : public QObject
|
2004-09-08 12:41:14 +00:00
|
|
|
{
|
2004-12-22 18:21:36 +00:00
|
|
|
Q_OBJECT
|
2007-01-02 22:37:55 +00:00
|
|
|
|
2004-11-09 17:20:19 +00:00
|
|
|
public:
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
2007-03-30 17:46:50 +00:00
|
|
|
* Creates a new document with the given @p widget as widget to relay GUI things (messageboxes, ...).
|
2007-01-02 22:37:55 +00:00
|
|
|
*/
|
2007-03-30 17:46:50 +00:00
|
|
|
Document( QWidget *widget );
|
2004-11-09 17:20:19 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Destroys the document.
|
|
|
|
*/
|
|
|
|
~Document();
|
2005-11-04 11:59:51 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Opens the document.
|
|
|
|
*/
|
2006-03-20 22:51:56 +00:00
|
|
|
bool openDocument( const QString & docFile, const KUrl & url, const KMimeType::Ptr &mime );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Closes the document.
|
|
|
|
*/
|
2004-11-09 17:20:19 +00:00
|
|
|
void closeDocument();
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Registers a new @p observer for the document.
|
|
|
|
*/
|
|
|
|
void addObserver( DocumentObserver *observer );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Unregisters the given @p observer for the document.
|
|
|
|
*/
|
|
|
|
void removeObserver( DocumentObserver *observer );
|
2004-11-09 17:20:19 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Reparses and applies the configuration.
|
|
|
|
*/
|
|
|
|
void reparseConfig();
|
2005-03-05 15:59:15 +00:00
|
|
|
|
2007-03-30 17:46:50 +00:00
|
|
|
/**
|
|
|
|
* Returns the widget to be used for relaying GUI things (messageboxes, ...)
|
|
|
|
*/
|
|
|
|
QWidget *widget() const;
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Returns whether the document is currently opened.
|
|
|
|
*/
|
2005-01-15 01:08:35 +00:00
|
|
|
bool isOpened() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the meta data of the document or 0 if no meta data
|
|
|
|
* are available.
|
|
|
|
*/
|
2004-12-11 17:25:03 +00:00
|
|
|
const DocumentInfo * documentInfo() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the table of content of the document or 0 if no
|
|
|
|
* table of content is available.
|
|
|
|
*/
|
2004-12-11 17:25:03 +00:00
|
|
|
const DocumentSynopsis * documentSynopsis() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the description of used fonts or 0 if no description
|
|
|
|
* is available.
|
|
|
|
*/
|
2005-06-13 15:46:23 +00:00
|
|
|
const DocumentFonts * documentFonts() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the list of embedded files or 0 if no embedded files
|
|
|
|
* are available.
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
const QList<EmbeddedFile*> *embeddedFiles() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the page object for the given page @p number or 0
|
|
|
|
* if the number is out of range.
|
|
|
|
*/
|
|
|
|
const Page * page( int number ) const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the current viewport of the document.
|
|
|
|
*/
|
2005-01-09 23:37:07 +00:00
|
|
|
const DocumentViewport & viewport() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the list of visible page rectangles.
|
|
|
|
* @see VisiblePageRect
|
|
|
|
*/
|
2006-06-23 21:11:52 +00:00
|
|
|
void setVisiblePageRects( const QVector< VisiblePageRect * > & visiblePageRects, int excludeId = -1 );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the list of visible page rectangles.
|
|
|
|
*/
|
|
|
|
const QVector< VisiblePageRect * > & visiblePageRects() const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the number of the current page.
|
|
|
|
*/
|
2004-11-09 17:20:19 +00:00
|
|
|
uint currentPage() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the number of pages of the document.
|
|
|
|
*/
|
2004-11-09 17:20:19 +00:00
|
|
|
uint pages() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the url of the currently opened document.
|
|
|
|
*/
|
2006-03-20 22:51:56 +00:00
|
|
|
KUrl currentDocument() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
2007-03-10 23:59:11 +00:00
|
|
|
* Returns whether the given @p action is allowed in the document.
|
|
|
|
* @see @ref Permission
|
2007-01-02 22:37:55 +00:00
|
|
|
*/
|
2007-03-10 23:59:11 +00:00
|
|
|
bool isAllowed( Permission action ) const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the document supports searching.
|
|
|
|
*/
|
2005-06-24 16:45:25 +00:00
|
|
|
bool supportsSearching() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
2007-01-05 23:12:06 +00:00
|
|
|
* Returns whether the document supports the listing of page sizes.
|
2007-01-02 22:37:55 +00:00
|
|
|
*/
|
2007-01-05 23:12:06 +00:00
|
|
|
bool supportsPageSizes() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
2007-01-05 23:12:06 +00:00
|
|
|
* Returns the list of supported page sizes or an empty list if this
|
2007-01-02 22:37:55 +00:00
|
|
|
* feature is not available.
|
2007-01-05 23:12:06 +00:00
|
|
|
* @see supportsPageSizes()
|
2007-01-02 22:37:55 +00:00
|
|
|
*/
|
2007-01-05 23:12:06 +00:00
|
|
|
PageSize::List pageSizes() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the document supports the export to ASCII text.
|
|
|
|
*/
|
2006-07-01 22:17:53 +00:00
|
|
|
bool canExportToText() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Exports the document as ASCII text and saves it under @p fileName.
|
|
|
|
*/
|
2006-07-01 22:17:53 +00:00
|
|
|
bool exportToText( const QString& fileName ) const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the list of supported export formats.
|
|
|
|
* @see ExportFormat
|
|
|
|
*/
|
2006-10-25 15:35:53 +00:00
|
|
|
QList<ExportFormat> exportFormats() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Exports the document in the given @p format and saves it under @p fileName.
|
|
|
|
*/
|
2006-10-25 15:35:53 +00:00
|
|
|
bool exportTo( const QString& fileName, const ExportFormat& format ) const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the document history is at the begin.
|
|
|
|
*/
|
2005-01-27 17:31:07 +00:00
|
|
|
bool historyAtBegin() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the document history is at the end.
|
|
|
|
*/
|
2005-01-27 17:31:07 +00:00
|
|
|
bool historyAtEnd() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the meta data for the given @p key and @p option or an empty variant
|
|
|
|
* if the key doesn't exists.
|
|
|
|
*/
|
|
|
|
QVariant metaData( const QString & key, const QVariant & option = QVariant() ) const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the current rotation of the document.
|
|
|
|
*/
|
2007-01-05 17:09:47 +00:00
|
|
|
Rotation rotation() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* If all pages have the same size this method returns it, if the page sizes
|
|
|
|
* differ an empty size object is returned.
|
|
|
|
*/
|
2006-10-15 19:37:14 +00:00
|
|
|
QSizeF allPagesSize() const;
|
2004-11-09 17:20:19 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Returns the size string for the given @p page or an empty string
|
|
|
|
* if the page is out of range.
|
|
|
|
*/
|
|
|
|
QString pageSizeString( int page ) const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the gui description file of the document that shall be merged with
|
|
|
|
* Okulars menu/tool bar.
|
|
|
|
*/
|
2007-03-10 17:25:14 +00:00
|
|
|
QString xmlFile() const;
|
2005-07-20 22:28:23 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Calling this method allows the document to add custom actions to the gui
|
|
|
|
* and extend Okulars side pane via @p toolbox.
|
|
|
|
*/
|
|
|
|
void setupGui( KActionCollection *collection, QToolBox *toolbox );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the current document viewport to the given @p page.
|
|
|
|
*
|
|
|
|
* @param excludeId The observer ids which shouldn't be effected by this change.
|
|
|
|
* @param smoothMove Whether the move shall be animated smoothly.
|
|
|
|
*/
|
2005-02-01 18:23:55 +00:00
|
|
|
void setViewportPage( int page, int excludeId = -1, bool smoothMove = false );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the current document viewport to the given @p viewport.
|
|
|
|
*
|
|
|
|
* @param excludeId The observer ids which shouldn't be effected by this change.
|
|
|
|
* @param smoothMove Whether the move shall be animated smoothly.
|
|
|
|
*/
|
|
|
|
void setViewport( const DocumentViewport &viewport, int excludeId = -1, bool smoothMove = false );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the current document viewport to the next viewport in the
|
|
|
|
* viewport history.
|
|
|
|
*/
|
2005-01-27 17:31:07 +00:00
|
|
|
void setPrevViewport();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the current document viewport to the previous viewport in the
|
|
|
|
* viewport history.
|
|
|
|
*/
|
2005-01-27 17:31:07 +00:00
|
|
|
void setNextViewport();
|
2006-09-26 22:22:01 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Sets the next @p viewport in the viewport history.
|
|
|
|
*/
|
|
|
|
void setNextDocumentViewport( const DocumentViewport &viewport );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sends @p requests for pixmap generation.
|
|
|
|
*/
|
|
|
|
void requestPixmaps( const QLinkedList<PixmapRequest*> &requests );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sends a request for text page generation for the given page @p number.
|
|
|
|
*/
|
2007-01-31 21:10:00 +00:00
|
|
|
void requestTextPage( uint number, enum GenerationType type = Synchronous );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Adds a new @p annotation to the given @p page.
|
|
|
|
*/
|
|
|
|
void addPageAnnotation( int page, Annotation *annotation );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Modifies the given @p annotation on the given @p page.
|
|
|
|
*/
|
|
|
|
void modifyPageAnnotation( int page, Annotation *annotation );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Removes the given @p annotation from the given @p page.
|
|
|
|
*/
|
|
|
|
void removePageAnnotation( int page, Annotation *annotation );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Removes the given @p annotations from the given @p page.
|
|
|
|
*/
|
|
|
|
void removePageAnnotations( int page, QList<Annotation*> annotations );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets the text selection for the given @p page.
|
|
|
|
*
|
|
|
|
* @param rect The rectangle of the selection.
|
|
|
|
* @param color The color of the selection.
|
|
|
|
*/
|
2006-09-26 22:22:01 +00:00
|
|
|
void setPageTextSelection( int page, RegularAreaRect * rect, const QColor & color );
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Describes the possible search types.
|
|
|
|
*/
|
|
|
|
enum SearchType
|
|
|
|
{
|
|
|
|
NextMatch, ///< Search next match
|
|
|
|
PreviousMatch, ///< Search previous match
|
|
|
|
AllDocument, ///< Search complete document
|
|
|
|
GoogleAll, ///< Search all words in google style
|
|
|
|
GoogleAny ///< Search any words in google style
|
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Searches the given @p text in the document.
|
|
|
|
*
|
|
|
|
* @param searchID The unique id for this search request.
|
|
|
|
* @param fromStart Whether the search should be started at begin of the document.
|
|
|
|
* @param caseSensitivity Whether the search is case sensitive.
|
2007-01-13 22:55:00 +00:00
|
|
|
* @param type The type of the search. @ref SearchType
|
2007-01-02 22:37:55 +00:00
|
|
|
* @param moveViewport Whether the viewport shall be moved to the position of the matches.
|
|
|
|
* @param color The highlighting color of the matches.
|
|
|
|
* @param noDialogs Whether a search dialog shall be shown.
|
|
|
|
*/
|
2006-11-23 16:54:28 +00:00
|
|
|
bool searchText( int searchID, const QString & text, bool fromStart, Qt::CaseSensitivity caseSensitivity,
|
2005-02-02 18:18:26 +00:00
|
|
|
SearchType type, bool moveViewport, const QColor & color, bool noDialogs = false );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Continues the search for the given @p searchID.
|
|
|
|
*/
|
2005-02-01 18:26:56 +00:00
|
|
|
bool continueSearch( int searchID );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Resets the search for the given @p searchID.
|
|
|
|
*/
|
2005-02-01 18:26:56 +00:00
|
|
|
void resetSearch( int searchID );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Continues with the last search.
|
|
|
|
*/
|
2006-07-11 19:57:17 +00:00
|
|
|
bool continueLastSearch();
|
2005-02-02 18:18:26 +00:00
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Adds a bookmark for the given @p page.
|
|
|
|
*/
|
2006-12-27 16:04:49 +00:00
|
|
|
void addBookmark( int page );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Adds a bookmark for the given @p referUrl at @p viewport.
|
|
|
|
*
|
|
|
|
* @param title The title of the bookmark.
|
|
|
|
*/
|
|
|
|
void addBookmark( const KUrl& referUrl, const Okular::DocumentViewport& viewport, const QString& title = QString() );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the given @p page is bookmarked.
|
|
|
|
*/
|
2006-12-27 16:04:49 +00:00
|
|
|
bool isBookmarked( int page ) const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
2007-01-13 14:45:51 +00:00
|
|
|
/**
|
|
|
|
* Remove a bookmark for the given @p page.
|
|
|
|
*/
|
|
|
|
void removeBookmark( int page );
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Removes the given @p bookmark with the given @p referUrl.
|
|
|
|
*/
|
|
|
|
void removeBookmark( const KUrl& referUrl, const KBookmark& bookmark );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the bookmark manager of the document.
|
|
|
|
*/
|
2006-12-27 16:04:49 +00:00
|
|
|
const BookmarkManager * bookmarkManager() const;
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* Processes/Executes the given @p link.
|
|
|
|
*/
|
|
|
|
void processLink( const Link *link );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Processes/Executes the given source @p reference.
|
|
|
|
*/
|
|
|
|
void processSourceReference( const SourceReference *reference );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the document can configure the printer itself.
|
|
|
|
*/
|
- Page/Link: tooltips for links backported
- Page: rotation does not switch height and width
- Document/Part/Generator:
1. Add API for attaching stuff to the interface: ActionCollection and the Navigation Panel
also add possibility to merge an XML .rc file with menu layout. Relevant functions are:
QString Generator::getXMLFile(), returns a QString with your .rc file name.
void Generator::setupGUI (KActionCollection* , QToolbox* ), add your components to the user interface
2. Supporting backend settings:
If during startup, backends which provide a configuration ([X-KDE-oKularHasInternalSettings]
set to true) are found, a menu item: configure backends is created, clicking on it results in
loading all the generators that have settings, but not those that dont. the Generator::addPages(KConfigDialog *dlg)
function should be overloaded by a generator and dlg->addPage should be used to add pages.
If a user opens a file that needs an already loaded generator, the already loaded one is used instead of loading another.
3. Error/Warning/Notice sending support, to send a notice/error/warning, add a relevant notice/error/warning(QString& txt ,int duration)
to the generator class, and sending a message to the user is as simple as emitting a signal!
4. Intercepting of events generated by the PageView is done by Generator::handleEvent(QEvent*), subclass it, do a switch on QEvent::type(), handle your
event and return true if pageview is to proceed with its handling or false if not.
5. Support configuring the KPrinter on the generator side, use Generator::canConfigurePrinter(), return true there, and you get a nonconfigured KPrinter in your
Generator::print()
6. PixmapRequest handling update:
a.) Generator::canGeneratePixmap is now Generator::canGeneratePixmap(bool async)
b.) Document::sendGeneratorRequests is a slot now
c.) Old way of sending pixmaps (Document::requestPixmaps(QValueList<PixmapRequest*> checking if we can generate pixmap if not, waiting for receiving)
is replaced with: requestPixmaps only queues the pixmap all checking if w can generate is done in sendGeneratorReqest, the sendGeneratorRequest is
run in three places:
1. in requestPixmaps when we receive a request
2. in requestDone if pixmapStack is not empty
3. sendGeneratorRequest, apart from removing invalid requests, takes the current request and if generator canGeratePixmap(request->async)
it removes the pixmap from stack and sends to generator if not, QTimer::singleshots to itself after 20ms, it ends when stack has no valid pixmap request
7. Added a commented out zoom field to PixmapGenerator, mightcome in handy sometime
- TextPage: add instructions that handle simplyfing the RegularAreaRect, no more double painted borders in selection rectangles, this rocks.
svn path=/trunk/playground/graphics/oKular/kpdf/; revision=445196
2005-08-10 16:14:39 +00:00
|
|
|
bool canConfigurePrinter() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Prints the document to the given @p printer.
|
|
|
|
*/
|
2004-11-09 17:20:19 +00:00
|
|
|
bool print( KPrinter &printer );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns a custom printer configuration page or 0 if no
|
|
|
|
* custom printer configuration page is available.
|
|
|
|
*/
|
2007-01-12 23:48:29 +00:00
|
|
|
KPrintDialogPage* printConfigurationWidget() const;
|
2007-01-02 22:37:55 +00:00
|
|
|
|
2007-01-28 15:46:10 +00:00
|
|
|
/**
|
|
|
|
* Fill the KConfigDialog @p dialog with the setting pages of the
|
|
|
|
* generators.
|
|
|
|
*/
|
|
|
|
void fillConfigDialog( KConfigDialog * dialog );
|
|
|
|
|
|
|
|
/**
|
2007-02-05 13:50:36 +00:00
|
|
|
* Returns the list with the supported MIME types.
|
2007-01-28 15:46:10 +00:00
|
|
|
*/
|
|
|
|
QStringList supportedMimeTypes() const;
|
|
|
|
|
2007-03-07 18:15:00 +00:00
|
|
|
/**
|
|
|
|
* Returns the component data associated with the generator. May be null.
|
|
|
|
*/
|
|
|
|
const KComponentData* componentData() const;
|
|
|
|
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* This method is used by the generators to signal the finish of
|
|
|
|
* the pixmap generation @p request.
|
|
|
|
*/
|
2005-01-18 16:43:36 +00:00
|
|
|
void requestDone( PixmapRequest * request );
|
|
|
|
|
2006-11-20 07:53:32 +00:00
|
|
|
public Q_SLOTS:
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* This slot is called whenever the user changes the @p rotation of
|
|
|
|
* the document.
|
|
|
|
*/
|
2006-06-02 20:42:57 +00:00
|
|
|
void slotRotation( int rotation );
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
2007-01-05 23:12:06 +00:00
|
|
|
* This slot is called whenever the user changes the page @p size
|
2007-01-02 22:37:55 +00:00
|
|
|
* of the document.
|
|
|
|
*/
|
2007-01-05 23:12:06 +00:00
|
|
|
void slotPageSizes( int size );
|
2005-07-20 22:28:23 +00:00
|
|
|
|
2006-11-20 07:53:32 +00:00
|
|
|
Q_SIGNALS:
|
2007-01-02 22:37:55 +00:00
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests a
|
|
|
|
* document close operation.
|
|
|
|
*/
|
2005-11-04 11:59:51 +00:00
|
|
|
void close();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests an
|
|
|
|
* application quit operation.
|
|
|
|
*/
|
2005-11-04 11:59:51 +00:00
|
|
|
void quit();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests a
|
|
|
|
* find operation.
|
|
|
|
*/
|
2005-01-01 21:50:34 +00:00
|
|
|
void linkFind();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests a
|
|
|
|
* goto operation.
|
|
|
|
*/
|
2005-01-01 21:50:34 +00:00
|
|
|
void linkGoToPage();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests a
|
|
|
|
* start presentation operation.
|
|
|
|
*/
|
2005-04-07 09:53:15 +00:00
|
|
|
void linkPresentation();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests an
|
|
|
|
* end presentation operation.
|
|
|
|
*/
|
2005-04-07 09:53:15 +00:00
|
|
|
void linkEndPresentation();
|
2007-01-02 22:37:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted whenever a link action requests an
|
|
|
|
* open url operation for the given document @p url.
|
|
|
|
*/
|
|
|
|
void openUrl( const KUrl &url );
|
|
|
|
|
|
|
|
/**
|
2007-01-04 15:22:28 +00:00
|
|
|
* This signal is emitted whenever an error occurred.
|
2007-01-02 22:37:55 +00:00
|
|
|
*
|
|
|
|
* @param text The description of the error.
|
|
|
|
* @param duration The time in seconds the message should be shown to the user.
|
|
|
|
*/
|
|
|
|
void error( const QString &text, int duration );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted to signal a warning.
|
|
|
|
*
|
|
|
|
* @param text The description of the warning.
|
|
|
|
* @param duration The time in seconds the message should be shown to the user.
|
|
|
|
*/
|
|
|
|
void warning( const QString &text, int duration );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* This signal is emitted to signal a notice.
|
|
|
|
*
|
|
|
|
* @param text The description of the notice.
|
|
|
|
* @param duration The time in seconds the message should be shown to the user.
|
|
|
|
*/
|
|
|
|
void notice( const QString &text, int duration );
|
2005-01-01 21:50:34 +00:00
|
|
|
|
2004-11-09 17:20:19 +00:00
|
|
|
private:
|
2007-04-14 19:44:07 +00:00
|
|
|
friend class DocumentPrivate;
|
|
|
|
DocumentPrivate *const d;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
|
|
|
Q_DISABLE_COPY( Document )
|
|
|
|
|
|
|
|
Q_PRIVATE_SLOT( d, void saveDocumentInfo() const )
|
|
|
|
Q_PRIVATE_SLOT( d, void slotTimedMemoryCheck() )
|
|
|
|
Q_PRIVATE_SLOT( d, void sendGeneratorRequest() )
|
|
|
|
Q_PRIVATE_SLOT( d, void rotationFinished( int page ) )
|
2004-09-08 12:41:14 +00:00
|
|
|
};
|
|
|
|
|
2005-01-07 13:07:29 +00:00
|
|
|
|
2005-01-03 15:51:05 +00:00
|
|
|
/**
|
2005-01-09 23:37:07 +00:00
|
|
|
* @short A view on the document.
|
2005-01-03 15:51:05 +00:00
|
|
|
*
|
2005-01-09 23:37:07 +00:00
|
|
|
* The Viewport structure is the 'current view' over the document. Contained
|
2007-01-04 15:22:28 +00:00
|
|
|
* data is broadcasted between observers to synchronize their viewports to get
|
2005-01-09 23:37:07 +00:00
|
|
|
* the 'I scroll one view and others scroll too' views.
|
2005-01-03 15:51:05 +00:00
|
|
|
*/
|
2006-05-08 20:12:04 +00:00
|
|
|
class OKULAR_EXPORT DocumentViewport
|
2005-01-03 15:51:05 +00:00
|
|
|
{
|
2005-01-09 23:37:07 +00:00
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new viewport for the given page @p number.
|
|
|
|
*/
|
|
|
|
DocumentViewport( int number = -1 );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Creates a new viewport from the given xml @p description.
|
|
|
|
*/
|
|
|
|
DocumentViewport( const QString &description );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the viewport as xml description.
|
|
|
|
*/
|
|
|
|
QString toString() const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns whether the viewport is valid.
|
|
|
|
*/
|
|
|
|
bool isValid() const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @internal
|
|
|
|
*/
|
|
|
|
bool operator==( const DocumentViewport &other ) const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The number of the page nearest the center of the viewport.
|
|
|
|
*/
|
2005-01-09 23:37:07 +00:00
|
|
|
int pageNumber;
|
|
|
|
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Describes the relative position of the viewport.
|
|
|
|
*/
|
|
|
|
enum Position
|
|
|
|
{
|
|
|
|
Center = 1, ///< Relative to the center of the page.
|
|
|
|
TopLeft = 2 ///< Relative to the top left corner of the page.
|
|
|
|
};
|
2005-06-13 11:53:47 +00:00
|
|
|
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* If 'rePos.enabled == true' then this structure contains the
|
|
|
|
* viewport center.
|
|
|
|
*/
|
2005-01-09 23:37:07 +00:00
|
|
|
struct {
|
|
|
|
bool enabled;
|
2005-06-13 11:53:47 +00:00
|
|
|
double normalizedX;
|
|
|
|
double normalizedY;
|
|
|
|
Position pos;
|
|
|
|
} rePos;
|
2005-01-09 23:37:07 +00:00
|
|
|
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* If 'autoFit.enabled == true' then the page must be autofitted in the viewport.
|
|
|
|
*/
|
2005-01-09 23:37:07 +00:00
|
|
|
struct {
|
|
|
|
bool enabled;
|
|
|
|
bool width;
|
|
|
|
bool height;
|
|
|
|
} autoFit;
|
2005-01-03 15:51:05 +00:00
|
|
|
};
|
|
|
|
|
2004-12-10 16:04:45 +00:00
|
|
|
/**
|
2006-12-28 16:58:56 +00:00
|
|
|
* @short A DOM tree containing information about the document.
|
2004-12-11 17:25:03 +00:00
|
|
|
*
|
2006-12-28 16:58:56 +00:00
|
|
|
* The DocumentInfo structure can be filled in by generators to display
|
|
|
|
* metadata about the currently opened file.
|
2004-12-10 16:04:45 +00:00
|
|
|
*/
|
2006-05-08 20:12:04 +00:00
|
|
|
class OKULAR_EXPORT DocumentInfo : public QDomDocument
|
2004-12-10 16:04:45 +00:00
|
|
|
{
|
2005-01-02 22:37:52 +00:00
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new document info.
|
|
|
|
*/
|
2005-01-02 22:37:52 +00:00
|
|
|
DocumentInfo();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets a value for a special key. The title should be an i18n'ed
|
|
|
|
* string, since it's used in the document information dialog.
|
|
|
|
*/
|
|
|
|
void set( const QString &key, const QString &value,
|
|
|
|
const QString &title = QString() );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the value for a given key or an empty string when the
|
|
|
|
* key doesn't exist.
|
|
|
|
*/
|
|
|
|
QString get( const QString &key ) const;
|
2004-12-10 16:04:45 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
2005-06-13 15:46:23 +00:00
|
|
|
* @short A DOM tree that describes the Table of Contents.
|
2004-12-11 17:25:03 +00:00
|
|
|
*
|
|
|
|
* The Synopsis (TOC or Table Of Contents for friends) is represented via
|
2005-06-13 15:46:23 +00:00
|
|
|
* a dom tree where each node has an internal name (displayed in the listview)
|
2004-12-11 17:25:03 +00:00
|
|
|
* and one or more attributes.
|
|
|
|
*
|
2005-01-07 13:07:29 +00:00
|
|
|
* In the tree the tag name is the 'screen' name of the entry. A tag can have
|
|
|
|
* attributes. Here follows the list of tag attributes with meaning:
|
2005-08-31 18:13:59 +00:00
|
|
|
* - Icon: An icon to be set in the Lisview for the node
|
2005-01-09 23:37:07 +00:00
|
|
|
* - Viewport: A string description of the referred viewport
|
|
|
|
* - ViewportName: A 'named reference' to the viewport that must be converted
|
2007-01-02 22:37:55 +00:00
|
|
|
* using metaData( "NamedViewport", *viewport_name* )
|
2004-12-10 16:04:45 +00:00
|
|
|
*/
|
2006-05-08 20:12:04 +00:00
|
|
|
class OKULAR_EXPORT DocumentSynopsis : public QDomDocument
|
2004-12-10 16:04:45 +00:00
|
|
|
{
|
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new document synopsis object.
|
|
|
|
*/
|
2005-01-03 15:51:05 +00:00
|
|
|
DocumentSynopsis();
|
2007-01-02 19:05:49 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Creates a new document synopsis object with the given
|
|
|
|
* @p document as parent node.
|
|
|
|
*/
|
2006-09-20 11:44:58 +00:00
|
|
|
DocumentSynopsis( const QDomDocument &document );
|
2004-12-10 16:04:45 +00:00
|
|
|
};
|
|
|
|
|
2005-06-13 15:46:23 +00:00
|
|
|
/**
|
|
|
|
* @short A DOM thee describing fonts used in document.
|
|
|
|
*
|
|
|
|
* Root's childrend (if any) are font nodes with the following attributes:
|
|
|
|
* - Name
|
|
|
|
* - Type
|
|
|
|
* - Embedded (if font is shipped inside the document)
|
|
|
|
* - File (system's file that provides this font
|
|
|
|
*/
|
2006-05-08 20:12:04 +00:00
|
|
|
class OKULAR_EXPORT DocumentFonts : public QDomDocument
|
2005-06-13 15:46:23 +00:00
|
|
|
{
|
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new document fonts object.
|
|
|
|
*/
|
2005-06-13 15:46:23 +00:00
|
|
|
DocumentFonts();
|
|
|
|
};
|
|
|
|
|
2006-05-28 16:54:54 +00:00
|
|
|
/**
|
2006-12-28 16:28:28 +00:00
|
|
|
* @short An embedded file into the document.
|
|
|
|
*
|
|
|
|
* This class represents a sort of interface of an embedded file in a document.
|
|
|
|
*
|
|
|
|
* Generators \b must re-implement its members to give the all the information
|
|
|
|
* about an embedded file, like its name, its description, the date of creation
|
|
|
|
* and modification, and the real data of the file.
|
2006-05-28 16:54:54 +00:00
|
|
|
*/
|
|
|
|
class OKULAR_EXPORT EmbeddedFile
|
|
|
|
{
|
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new embedded file.
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
EmbeddedFile();
|
2007-01-02 19:05:49 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Destroys the embedded file.
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual ~EmbeddedFile();
|
2006-12-28 16:28:28 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the name of the file
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual QString name() const = 0;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
2006-12-28 16:28:28 +00:00
|
|
|
/**
|
|
|
|
* Returns the description of the file, or an empty string if not
|
|
|
|
* available
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual QString description() const = 0;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
2006-12-28 16:28:28 +00:00
|
|
|
/**
|
|
|
|
* Returns the real data representing the file contents
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual QByteArray data() const = 0;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
2006-12-28 16:28:28 +00:00
|
|
|
/**
|
|
|
|
* Returns the modification date of the file, or an invalid date
|
|
|
|
* if not available
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual QDateTime modificationDate() const = 0;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
2006-12-28 16:28:28 +00:00
|
|
|
/**
|
|
|
|
* Returns the creation date of the file, or an invalid date
|
|
|
|
* if not available
|
|
|
|
*/
|
2006-05-28 16:54:54 +00:00
|
|
|
virtual QDateTime creationDate() const = 0;
|
|
|
|
};
|
|
|
|
|
2006-06-23 21:11:52 +00:00
|
|
|
/**
|
|
|
|
* @short An area of a specified page
|
|
|
|
*/
|
2007-01-02 19:05:49 +00:00
|
|
|
class OKULAR_EXPORT VisiblePageRect
|
2006-06-23 21:11:52 +00:00
|
|
|
{
|
|
|
|
public:
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* Creates a new visible page rectangle.
|
|
|
|
*
|
|
|
|
* @param pageNumber The page number where the rectangle is located.
|
|
|
|
* @param rectangle The rectangle in normalized coordinates.
|
|
|
|
*/
|
|
|
|
VisiblePageRect( int pageNumber = -1, const NormalizedRect &rectangle = NormalizedRect() );
|
2006-06-23 21:11:52 +00:00
|
|
|
|
2007-01-02 19:05:49 +00:00
|
|
|
/**
|
|
|
|
* The page number where the rectangle is located.
|
|
|
|
*/
|
2006-06-23 21:11:52 +00:00
|
|
|
int pageNumber;
|
2007-01-02 19:05:49 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* The rectangle in normalized coordinates.
|
|
|
|
*/
|
2006-06-23 21:11:52 +00:00
|
|
|
NormalizedRect rect;
|
|
|
|
};
|
|
|
|
|
2006-09-21 08:45:36 +00:00
|
|
|
}
|
|
|
|
|
2004-09-08 12:41:14 +00:00
|
|
|
#endif
|