Changeset View
Changeset View
Standalone View
Standalone View
ui/annotationactionhandler.h
- This file was added.
1 | /************************************************************************** | ||||
---|---|---|---|---|---|
2 | * Copyright (C) 2019 by Simone Gaiarin <simgunz@gmail.com> * | ||||
3 | * * | ||||
4 | * This program is free software; you can redistribute it and/or modify * | ||||
5 | * it under the terms of the GNU General Public License as published by * | ||||
6 | * the Free Software Foundation; either version 2 of the License, or * | ||||
7 | * (at your option) any later version. * | ||||
8 | **************************************************************************/ | ||||
9 | | ||||
10 | #ifndef _ANNOTATIONACTIONHANDLER_H_ | ||||
11 | #define _ANNOTATIONACTIONHANDLER_H_ | ||||
12 | | ||||
13 | #include <QObject> | ||||
14 | | ||||
15 | class QAction; | ||||
16 | class QColor; | ||||
17 | class QFont; | ||||
18 | class KActionCollection; | ||||
19 | class PageViewAnnotator; | ||||
20 | class AnnotationActionHandlerPrivate; | ||||
21 | | ||||
22 | /** | ||||
23 | * @short Handles all the actions of the annotation tools toolbar | ||||
24 | * | ||||
25 | */ | ||||
26 | class AnnotationActionHandler : public QObject | ||||
27 | { | ||||
28 | Q_OBJECT | ||||
29 | | ||||
30 | public: | ||||
31 | AnnotationActionHandler( PageViewAnnotator * parent, KActionCollection * ac ); | ||||
32 | ~AnnotationActionHandler(); | ||||
33 | | ||||
34 | void deselectAllAnnotationActions(); | ||||
35 | | ||||
36 | void reparseTools(); | ||||
37 | void setToolsEnabled( bool on ); | ||||
38 | void setTextToolsEnabled( bool on ); | ||||
39 | | ||||
40 | Q_SIGNALS: | ||||
41 | void advancedSettingsTriggered(); | ||||
42 | | ||||
43 | private: | ||||
44 | void addFavoriteAnnotations(); | ||||
45 | | ||||
46 | friend class AnnotationActionHandlerPrivate; | ||||
47 | class AnnotationActionHandlerPrivate * d; | ||||
48 | | ||||
49 | private Q_SLOTS: | ||||
50 | void slotToolSelected( int toolID ); | ||||
51 | void slotFavoriteToolSelected( int favToolID ); | ||||
52 | void slotSelectBorderColor(); | ||||
53 | void slotSelectInnerColor(); | ||||
54 | void slotSelectAnnotationFont(); | ||||
55 | void slotSelectAnnotationWidth( int width ); | ||||
56 | void slotSelectAnnotationOpacity( int opacity ); | ||||
57 | }; | ||||
58 | | ||||
59 | #endif // _ANNOTATIONACTIONHANDLER_H_ |