-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathqgsdecorationcopyright.h
66 lines (54 loc) · 2.14 KB
/
qgsdecorationcopyright.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/***************************************************************************
plugin.h
Functions:
-------------------
begin : Jan 21, 2004
copyright : (C) 2004 by Tim Sutton
email : [email protected]
***************************************************************************/
/***************************************************************************
* *
* 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. *
* *
***************************************************************************/
#ifndef QGSCOPYRIGHTLABELPLUGIN
#define QGSCOPYRIGHTLABELPLUGIN
#include "qgsdecorationitem.h"
#include <QColor>
#include <QFont>
#include <QObject>
#include "qgis_app.h"
class QAction;
class QPainter;
class QgsDecorationCopyrightDialog;
class APP_EXPORT QgsDecorationCopyright : public QgsDecorationItem
{
Q_OBJECT
public:
//! Constructor
QgsDecorationCopyright( QObject *parent = nullptr );
public slots:
//! set values on the gui when a project is read or the gui first loaded
void projectRead() override;
//! save values to the project
void saveToProject() override;
//! Show the dialog box
void run() override;
//! render the copyright label
void render( QPainter * ) override;
private:
//! This is the font that will be used for the copyright label
QFont mQFont;
//! This is the string that will be used for the copyright label
QString mLabelQString;
//! This is the color for the copyright label
QColor mLabelQColor;
//! enable or disable use of position percentage for placement
int mMarginHorizontal;
int mMarginVertical;
friend class QgsDecorationCopyrightDialog;
};
#endif