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

okular

bookmarkmanager.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *   Copyright (C) 2006 by Pino Toscano <pino@kde.org>                     *
00003  *                                                                         *
00004  *   This program is free software; you can redistribute it and/or modify  *
00005  *   it under the terms of the GNU General Public License as published by  *
00006  *   the Free Software Foundation; either version 2 of the License, or     *
00007  *   (at your option) any later version.                                   *
00008  ***************************************************************************/
00009 
00010 #ifndef _OKULAR_BOOKMARK_MANAGER_H_
00011 #define _OKULAR_BOOKMARK_MANAGER_H_
00012 
00013 #include <kbookmark.h>
00014 
00015 #include "okular_export.h"
00016 
00017 class QAction;
00018 class KUrl;
00019 
00020 namespace Okular {
00021 
00022 class Document;
00023 class DocumentPrivate;
00024 class DocumentViewport;
00025 
00032 class OKULAR_EXPORT BookmarkManager : public QObject
00033 {
00034     Q_OBJECT
00035 
00036     public:
00037         virtual ~BookmarkManager();
00038 
00042         KUrl::List files() const;
00046         KBookmark::List bookmarks( const KUrl& url ) const;
00047 
00051         void save() const;
00052 
00056         void addBookmark( int page );
00057 
00064         bool addBookmark( const KUrl& referurl, const Okular::DocumentViewport& vp, const QString& title = QString() );
00065 
00069         void removeBookmark( int page );
00070 
00074         int removeBookmark( const KUrl& referurl, const KBookmark& bm );
00075 
00079         bool isBookmarked( int page ) const;
00080 
00087         QList< QAction* > actionsForUrl( const KUrl& url ) const;
00088 
00089     Q_SIGNALS:
00093         void openUrl( const KUrl& url );
00094 
00098         void saved();
00099 
00100     private:
00101         class Private;
00102         Private * const d;
00103         friend class Private;
00104 
00105         // private interface used by the Document
00106         friend class Document;
00107         friend class DocumentPrivate;
00108 
00109         BookmarkManager( DocumentPrivate * document );
00110 
00111         void setUrl( const KUrl& url );
00112         bool setPageBookmark( int page );
00113         bool removePageBookmark( int page );
00114 
00115         Q_DISABLE_COPY( BookmarkManager )
00116 };
00117 
00118 }
00119 
00120 #endif

okular

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

kdegraphics

Skip menu "kdegraphics"
  • okular
Generated for kdegraphics by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal