QGIS API Documentation
3.14.0-Pi (9f7028fd23)
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
w
z
Functions
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
w
z
Variables
Typedefs
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
c
e
f
g
h
k
l
m
o
p
r
s
t
u
v
w
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
y
z
Related Functions
a
c
d
e
f
g
i
l
m
n
o
p
q
r
s
t
v
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
Variables
a
b
c
d
e
f
g
h
i
l
n
o
p
q
r
s
t
u
w
Typedefs
a
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
Enumerations
Enumerator
Macros
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
w
y
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
src
core
qgsmaplayerstyle.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsmaplayersty.h
3
--------------------------------------
4
Date : September 2019
5
Copyright : (C) 2018 by Denis Rouzaud
6
Email : denis@opengis.ch
7
***************************************************************************
8
* *
9
* This program is free software; you can redistribute it and/or modify *
10
* it under the terms of the GNU General Public License as published by *
11
* the Free Software Foundation; either version 2 of the License, or *
12
* (at your option) any later version. *
13
* *
14
***************************************************************************/
15
16
#ifndef QGSMAPLAYERSTYLE_H
17
#define QGSMAPLAYERSTYLE_H
18
19
#include "qgis_core.h"
20
#include "
qgis_sip.h
"
21
22
#include <QByteArray>
23
#include <QMap>
24
#include <QStringList>
25
#include <QObject>
26
27
28
class
QDomElement;
29
class
QgsMapLayer
;
30
42
class
CORE_EXPORT
QgsMapLayerStyle
43
{
44
public
:
46
QgsMapLayerStyle
() =
default
;
47
49
explicit
QgsMapLayerStyle
(
const
QString &xmlData );
50
52
bool
isValid()
const
;
53
55
void
clear();
56
58
QString xmlData()
const
;
59
61
void
readFromLayer(
QgsMapLayer
*layer );
63
void
writeToLayer(
QgsMapLayer
*layer )
const
;
64
66
void
readXml(
const
QDomElement &styleElement );
68
void
writeXml( QDomElement &styleElement )
const
;
69
70
private
:
71
QString mXmlData;
72
};
73
74
81
class
CORE_EXPORT
QgsMapLayerStyleOverride
82
{
83
public
:
84
89
QgsMapLayerStyleOverride
(
QgsMapLayer
*layer )
90
: mLayer( layer )
91
{
92
}
93
94
~
QgsMapLayerStyleOverride
();
95
100
void
setOverrideStyle(
const
QString &style );
101
102
private
:
103
104
QgsMapLayer
*mLayer =
nullptr
;
105
bool
mStyleOverridden =
false
;
106
};
107
#endif // QGSMAPLAYERSTYLE_H
QgsMapLayerStyleOverride::QgsMapLayerStyleOverride
QgsMapLayerStyleOverride(QgsMapLayer *layer)
Construct a style override object associated with a map layer.
Definition:
qgsmaplayerstyle.h:89
QgsMapLayerStyleOverride
Definition:
qgsmaplayerstyle.h:81
qgis_sip.h
QgsMapLayer
Definition:
qgsmaplayer.h:81
QgsMapLayerStyle
Definition:
qgsmaplayerstyle.h:42
Generated on Mon Jun 22 2020 05:14:09 for QGIS API Documentation by
1.8.17