kate Library API Documentation

katebookmarks.h

00001 /* This file is part of the KDE libraries
00002    Copyright (C) 2002, 2003 Anders Lund <anders.lund@lund.tdcadsl.dk>
00003    Copyright (C) 2002 John Firebaugh <jfirebaugh@kde.org>
00004 
00005    This library is free software; you can redistribute it and/or
00006    modify it under the terms of the GNU Library General Public
00007    License version 2 as published by the Free Software Foundation.
00008 
00009    This library is distributed in the hope that it will be useful,
00010    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012    Library General Public License for more details.
00013 
00014    You should have received a copy of the GNU Library General Public License
00015    along with this library; see the file COPYING.LIB.  If not, write to
00016    the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00017    Boston, MA 02111-1307, USA.
00018 */
00019 
00020 #ifndef __KATE_BOOKMARKS_H__
00021 #define __KATE_BOOKMARKS_H__
00022 
00023 #include <qobject.h>
00024 #include <qptrlist.h>
00025 
00026 class KateView;
00027 
00028 namespace KTextEditor { class Mark; }
00029 
00030 class KAction;
00031 class KActionMenu;
00032 class KActionCollection;
00033 
00034 class KateBookmarks : public QObject
00035 {
00036   Q_OBJECT
00037 
00038   public:
00039     enum Sorting { Position, Creation };
00040     KateBookmarks( KateView* parent, Sorting sort=Position );
00041     virtual ~KateBookmarks();
00042 
00043     void createActions( KActionCollection* );
00044 
00045     KateBookmarks::Sorting sorting() { return m_sorting; };
00046     void setSorting( Sorting s ) { m_sorting = s; };
00047 
00048   private slots:
00049     void toggleBookmark();
00050     void clearBookmarks();
00051     void bookmarkMenuAboutToShow();
00052     void bookmarkMenuAboutToHide();
00053     void goNext();
00054     void goPrevious();
00055 
00056     void marksChanged ();
00057 
00058   private:
00059     KateView*                    m_view;
00060     KAction*                     m_bookmarkToggle;
00061     KAction*                     m_bookmarkClear;
00062     KAction*                     m_goNext;
00063     KAction*                     m_goPrevious;
00064     KActionMenu*                 m_bookmarkMenu;
00065     Sorting                      m_sorting;
00066 };
00067 
00068 #endif // _KateBookmarks_H_
00069 
00070 // vim: noet ts=2
KDE Logo
This file is part of the documentation for kate Library Version 3.2.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Thu Mar 4 22:45:57 2004 by doxygen 1.3.6-20040222 written by Dimitri van Heesch, © 1997-2003