WPSGraphicStyle.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2
3 /* libwps
4 * Version: MPL 2.0 / LGPLv2.1+
5 *
6 * This Source Code Form is subject to the terms of the Mozilla Public
7 * License, v. 2.0. If a copy of the MPL was not distributed with this
8 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 *
10 * Major Contributor(s):
11 * Copyright (C) 2002, 2005 William Lachance (william.lachance@sympatico.ca)
12 * Copyright (C) 2002, 2004 Marc Maurer (uwog@uwog.net)
13 *
14 * For minor contributions see the git repository.
15 *
16 * Alternatively, the contents of this file may be used under the terms
17 * of the GNU Lesser General Public License Version 2.1 or later
18 * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
19 * applicable instead of those above.
20 *
21 * For further information visit http://libwps.sourceforge.net
22 */
23 #ifndef WPS_GRAPHIC_STYLE
24 # define WPS_GRAPHIC_STYLE
25 # include <ostream>
26 # include <string>
27 # include <vector>
28
29 # include "librevenge/librevenge.h"
30 # include "libwps_internal.h"
31
37 class WPSGraphicStyle
38 {
39 public:
41 enum LineCap { C_Butt, C_Square, C_Round };
43 enum LineJoin { J_Miter, J_Round, J_Bevel };
45 enum GradientType { G_None, G_Axial, G_Linear, G_Radial, G_Rectangular, G_Square, G_Ellipsoid };
46
48 struct GradientStop
49 {
51 GradientStop(float offset=0.0, WPSColor const &col=WPSColor::black(), float opacity=1.0)
52 : m_offset(offset)
53 , m_color(col)
54 , m_opacity(opacity)
55 {
56 }
58 int cmp(GradientStop const &a) const
59 {
60 if (m_offset < a.m_offset) return -1;
61 if (m_offset > a.m_offset) return 1;
62 if (m_color < a.m_color) return -1;
63 if (m_color > a.m_color) return 1;
64 if (m_opacity < a.m_opacity) return -1;
65 if (m_opacity > a.m_opacity) return 1;
66 return 0;
67 }
69 friend std::ostream &operator<<(std::ostream &o, GradientStop const &st)
70 {
71 o << "offset=" << st.m_offset << ",";
72 o << "color=" << st.m_color << ",";
73 if (st.m_opacity<1.0f)
74 o << "opacity=" << st.m_opacity*100.f << "%,";
75 return o;
76 }
78 float m_offset;
80 WPSColor m_color;
82 float m_opacity;
83 };
88 struct Pattern
89 {
91 Pattern()
92 : m_dim(0,0)
93 , m_data()
94 , m_picture()
95 , m_pictureMime("")
96 , m_pictureAverageColor(WPSColor::white())
97 {
98 m_colors[0]=WPSColor::black();
99 m_colors[1]=WPSColor::white();
100 }
102 Pattern(Vec2i dim, librevenge::RVNGBinaryData const &picture, std::string const &mime, WPSColor const &avColor)
103 : m_dim(dim)
104 , m_data()
105 , m_picture(picture)
106 , m_pictureMime(mime)
107 , m_pictureAverageColor(avColor)
108 {
109 m_colors[0]=WPSColor::black();
110 m_colors[1]=WPSColor::white();
111 }
112 Pattern(Pattern const &)=default;
114 virtual ~Pattern();
116 bool empty() const
117 {
118 if (m_dim[0]==0 || m_dim[1]==0) return true;
119 if (m_picture.size()) return false;
120 if (m_dim[0]!=8 && m_dim[0]!=16 && m_dim[0]!=32) return true;
121 return m_data.size()!=size_t((m_dim[0]/8)*m_dim[1]);
122 }
124 bool getAverageColor(WPSColor &col) const;
126 bool getUniqueColor(WPSColor &col) const;
128 bool getBinary(librevenge::RVNGBinaryData &data, std::string &type) const;
129
131 int cmp(Pattern const &a) const
132 {
133 int diff = m_dim.cmp(a.m_dim);
134 if (diff) return diff;
135 if (m_data.size() < a.m_data.size()) return -1;
136 if (m_data.size() > a.m_data.size()) return 1;
137 for (size_t h=0; h < m_data.size(); ++h)
138 {
139 if (m_data[h]<a.m_data[h]) return 1;
140 if (m_data[h]>a.m_data[h]) return -1;
141 }
142 for (int i=0; i<2; ++i)
143 {
144 if (m_colors[i] < a.m_colors[i]) return 1;
145 if (m_colors[i] > a.m_colors[i]) return -1;
146 }
147 if (m_pictureAverageColor < a.m_pictureAverageColor) return 1;
148 if (m_pictureAverageColor > a.m_pictureAverageColor) return -1;
149 if (m_pictureMime < a.m_pictureMime) return 1;
150 if (m_pictureMime > a.m_pictureMime) return -1;
151 if (m_picture.size() < a.m_picture.size()) return 1;
152 if (m_picture.size() > a.m_picture.size()) return -1;
153 const unsigned char *ptr=m_picture.getDataBuffer();
154 const unsigned char *aPtr=a.m_picture.getDataBuffer();
155 if (!ptr || !aPtr) return 0; // must only appear if the two buffers are empty
156 for (unsigned long h=0; h < m_picture.size(); ++h, ++ptr, ++aPtr)
157 {
158 if (*ptr < *aPtr) return 1;
159 if (*ptr > *aPtr) return -1;
160 }
161 return 0;
162 }
164 friend std::ostream &operator<<(std::ostream &o, Pattern const &pat)
165 {
166 o << "dim=" << pat.m_dim << ",";
167 if (pat.m_picture.size())
168 {
169 o << "type=" << pat.m_pictureMime << ",";
170 o << "col[average]=" << pat.m_pictureAverageColor << ",";
171 }
172 else
173 {
174 if (!pat.m_colors[0].isBlack()) o << "col0=" << pat.m_colors[0] << ",";
175 if (!pat.m_colors[1].isWhite()) o << "col1=" << pat.m_colors[1] << ",";
176 o << "[";
177 for (auto const &data : pat.m_data)
178 o << std::hex << int(data) << std::dec << ",";
179 o << "],";
180 }
181 return o;
182 }
184 Pattern &operator=(Pattern const &)=default;
186 Vec2i m_dim;
187
189 WPSColor m_colors[2];
191 std::vector<unsigned char> m_data;
192 protected:
194 librevenge::RVNGBinaryData m_picture;
196 std::string m_pictureMime;
198 WPSColor m_pictureAverageColor;
199 };
201 WPSGraphicStyle()
202 : m_lineWidth(1)
203 , m_lineDashWidth()
204 , m_lineCap(C_Butt)
205 , m_lineJoin(J_Miter)
206 , m_lineOpacity(1)
207 , m_lineColor(WPSColor::black())
208 , m_fillRuleEvenOdd(false)
209 , m_surfaceColor(WPSColor::white())
210 , m_surfaceOpacity(0)
211 , m_shadowColor(WPSColor::black())
212 , m_shadowOpacity(0)
213 , m_shadowOffset(1,1)
214 , m_pattern()
215 , m_gradientType(G_None)
216 , m_gradientStopList()
217 , m_gradientAngle(0)
218 , m_gradientBorder(0)
219 , m_gradientPercentCenter(0.5f,0.5f)
220 , m_gradientRadius(1)
221 , m_backgroundColor(WPSColor::white())
222 , m_backgroundOpacity(-1)
223 , m_bordersList()
224 , m_frameName("")
225 , m_frameNextName("")
226 , m_rotate(0)
227 , m_extra("")
228 {
229 m_arrows[0]=m_arrows[1]=false;
230 m_flip[0]=m_flip[1]=false;
231 m_gradientStopList.push_back(GradientStop(0.0, WPSColor::white()));
232 m_gradientStopList.push_back(GradientStop(1.0, WPSColor::black()));
233 }
234 WPSGraphicStyle(WPSGraphicStyle const &)=default;
235 WPSGraphicStyle &operator=(WPSGraphicStyle const &)=default;
237 static WPSGraphicStyle emptyStyle()
238 {
239 WPSGraphicStyle res;
240 res.m_lineWidth=0;
241 return res;
242 }
244 virtual ~WPSGraphicStyle();
246 bool hasLine() const
247 {
248 return m_lineWidth>0 && m_lineOpacity>0;
249 }
251 void setSurfaceColor(WPSColor const &col, float opacity = 1)
252 {
253 m_surfaceColor = col;
254 m_surfaceOpacity = opacity;
255 }
257 bool hasSurfaceColor() const
258 {
259 return m_surfaceOpacity > 0;
260 }
262 void setPattern(Pattern const &pat)
263 {
264 m_pattern=pat;
265 }
267 bool hasPattern() const
268 {
269 return !m_pattern.empty();
270 }
272 bool hasGradient(bool complex=false) const
273 {
274 return m_gradientType != G_None && int(m_gradientStopList.size()) >= (complex ? 3 : 2);
275 }
277 bool hasSurface() const
278 {
279 return hasSurfaceColor() || hasPattern() || hasGradient();
280 }
282 void setBackgroundColor(WPSColor const &col, float opacity = 1)
283 {
284 m_backgroundColor = col;
285 m_backgroundOpacity = opacity;
286 }
288 bool hasBackgroundColor() const
289 {
290 return m_backgroundOpacity > 0;
291 }
293 void setShadowColor(WPSColor const &col, float opacity = 1)
294 {
295 m_shadowColor = col;
296 m_shadowOpacity = opacity;
297 }
299 bool hasShadow() const
300 {
301 return m_shadowOpacity > 0;
302 }
304 bool hasBorders() const
305 {
306 return !m_bordersList.empty();
307 }
309 bool hasSameBorders() const
310 {
311 if (m_bordersList.empty()) return true;
312 if (m_bordersList.size()!=4) return false;
313 for (size_t i=1; i<m_bordersList.size(); ++i)
314 {
315 if (m_bordersList[i]!=m_bordersList[0])
316 return false;
317 }
318 return true;
319 }
321 std::vector<WPSBorder> const &borders() const
322 {
323 return m_bordersList;
324 }
326 void resetBorders()
327 {
328 m_bordersList.resize(0);
329 }
331 void setBorders(int wh, WPSBorder const &border);
333 friend std::ostream &operator<<(std::ostream &o, WPSGraphicStyle const &st);
335 void addTo(librevenge::RVNGPropertyList &pList, bool only1d=false) const;
337 void addFrameTo(librevenge::RVNGPropertyList &pList) const;
339 int cmp(WPSGraphicStyle const &a) const;
340
342 float m_lineWidth;
344 std::vector<float> m_lineDashWidth;
346 LineCap m_lineCap;
348 LineJoin m_lineJoin;
350 float m_lineOpacity;
352 WPSColor m_lineColor;
354 bool m_fillRuleEvenOdd;
356 WPSColor m_surfaceColor;
358 float m_surfaceOpacity;
359
361 WPSColor m_shadowColor;
363 float m_shadowOpacity;
365 Vec2f m_shadowOffset;
366
368 Pattern m_pattern;
369
371 GradientType m_gradientType;
373 std::vector<GradientStop> m_gradientStopList;
375 float m_gradientAngle;
377 float m_gradientBorder;
379 Vec2f m_gradientPercentCenter;
381 float m_gradientRadius;
382
384 bool m_arrows[2];
385
386 //
387 // related to the frame
388 //
389
391 WPSColor m_backgroundColor;
393 float m_backgroundOpacity;
395 std::vector<WPSBorder> m_bordersList;
397 librevenge::RVNGString m_frameName;
399 librevenge::RVNGString m_frameNextName;
400
401 //
402 // some transformation: must probably be somewhere else
403 //
404
406 float m_rotate;
408 bool m_flip[2];
409
411 std::string m_extra;
412 };
413 #endif
414 /* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
WPSGraphicStyle::Pattern::cmp
int cmp(Pattern const &a) const
compare two patterns
Definition: WPSGraphicStyle.h:131
WPSGraphicStyle::m_flip
bool m_flip[2]
two bool to indicated we need to flip the shape or not
Definition: WPSGraphicStyle.h:408
WPSGraphicStyle::Pattern::getAverageColor
bool getAverageColor(WPSColor &col) const
return the average color
Definition: WPSGraphicStyle.cpp:61
WPSGraphicStyle::GradientStop
a structure used to define the gradient limit
Definition: WPSGraphicStyle.h:48
WPSGraphicStyle::Pattern::m_pictureMime
std::string m_pictureMime
the picture type
Definition: WPSGraphicStyle.h:196
WPSGraphicStyle::m_shadowOffset
Vec2f m_shadowOffset
the shadow offset
Definition: WPSGraphicStyle.h:365
WPSBorder
a border list
Definition: libwps_internal.h:394
WPSGraphicStyle::m_surfaceOpacity
float m_surfaceOpacity
true if the surface has some color
Definition: WPSGraphicStyle.h:358
WPSGraphicStyle::m_frameName
librevenge::RVNGString m_frameName
the frame name
Definition: WPSGraphicStyle.h:397
WPSGraphicStyle::G_Square
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::Pattern::operator=
Pattern & operator=(Pattern const &)=default
operator=
WPSGraphicStyle::hasLine
bool hasLine() const
returns true if the border is defined
Definition: WPSGraphicStyle.h:246
WPSGraphicStyle::Pattern::empty
bool empty() const
return true if we does not have a pattern
Definition: WPSGraphicStyle.h:116
WPSGraphicStyle::m_lineJoin
LineJoin m_lineJoin
the line join
Definition: WPSGraphicStyle.h:348
WPSGraphicStyle::m_shadowOpacity
float m_shadowOpacity
true if the shadow has some color
Definition: WPSGraphicStyle.h:363
WPSGraphicStyle::Pattern::m_data
std::vector< unsigned char > m_data
the pattern data: a sequence of data: p[0..7,0],p[8..15,0]...p[0..7,1],p[8..15,1], ...
Definition: WPSGraphicStyle.h:191
WPSGraphicStyle::m_rotate
float m_rotate
the rotation
Definition: WPSGraphicStyle.h:406
WPSGraphicStyle::m_lineCap
LineCap m_lineCap
the line cap
Definition: WPSGraphicStyle.h:346
WPSGraphicStyle::J_Round
Definition: WPSGraphicStyle.h:43
WPSGraphicStyle::G_Rectangular
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::G_None
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::Pattern::m_pictureAverageColor
WPSColor m_pictureAverageColor
the picture average color
Definition: WPSGraphicStyle.h:198
WPSGraphicStyle::borders
std::vector< WPSBorder > const & borders() const
return the frame border: libwps::Left | ...
Definition: WPSGraphicStyle.h:321
WPSColor::black
static WPSColor black()
return the back color
Definition: libwps_internal.h:306
WPSGraphicStyle::setBorders
void setBorders(int wh, WPSBorder const &border)
sets the cell border: wh=libwps::LeftBit|...
Definition: WPSGraphicStyle.cpp:144
WPSGraphicStyle::m_bordersList
std::vector< WPSBorder > m_bordersList
the borders WPSBorder::Pos (for a frame)
Definition: WPSGraphicStyle.h:395
WPSColor::white
static WPSColor white()
return the white color
Definition: libwps_internal.h:311
WPSGraphicStyle::~WPSGraphicStyle
virtual ~WPSGraphicStyle()
virtual destructor
Definition: WPSGraphicStyle.cpp:140
WPSGraphicStyle::GradientStop::cmp
int cmp(GradientStop const &a) const
compare two gradient
Definition: WPSGraphicStyle.h:58
WPSGraphicStyle::G_Axial
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::m_lineDashWidth
std::vector< float > m_lineDashWidth
the dash array: a sequence of (fullsize, emptysize)
Definition: WPSGraphicStyle.h:344
WPSGraphicStyle::hasShadow
bool hasShadow() const
returns true if the shadow is defined
Definition: WPSGraphicStyle.h:299
WPSColor::isWhite
bool isWhite() const
return true if the color is white
Definition: libwps_internal.h:350
WPSGraphicStyle::GradientStop::m_opacity
float m_opacity
the opacity
Definition: WPSGraphicStyle.h:82
WPSGraphicStyle::J_Miter
Definition: WPSGraphicStyle.h:43
WPSGraphicStyle::cmp
int cmp(WPSGraphicStyle const &a) const
compare two styles
Definition: WPSGraphicStyle.cpp:421
WPSGraphicStyle::setSurfaceColor
void setSurfaceColor(WPSColor const &col, float opacity=1)
set the surface color
Definition: WPSGraphicStyle.h:251
WPSGraphicStyle::m_gradientAngle
float m_gradientAngle
the gradient angle
Definition: WPSGraphicStyle.h:375
WPSGraphicStyle::Pattern::~Pattern
virtual ~Pattern()
virtual destructor
Definition: WPSGraphicStyle.cpp:41
WPSGraphicStyle::Pattern::m_dim
Vec2i m_dim
the dimension width x height
Definition: WPSGraphicStyle.h:186
WPSGraphicStyle::m_gradientRadius
float m_gradientRadius
the gradient radius
Definition: WPSGraphicStyle.h:381
WPSGraphicStyle::Pattern::Pattern
Pattern(Vec2i dim, librevenge::RVNGBinaryData const &picture, std::string const &mime, WPSColor const &avColor)
constructor from a binary data
Definition: WPSGraphicStyle.h:102
WPSGraphicStyle
a structure used to define a picture style
Definition: WPSGraphicStyle.h:37
WPSGraphicStyle::Pattern::getBinary
bool getBinary(librevenge::RVNGBinaryData &data, std::string &type) const
tries to convert the picture in a binary data ( ppm)
Definition: WPSGraphicStyle.cpp:92
WPSGraphicStyle::m_gradientPercentCenter
Vec2f m_gradientPercentCenter
the gradient center
Definition: WPSGraphicStyle.h:379
WPSGraphicStyle::emptyStyle
static WPSGraphicStyle emptyStyle()
returns an empty style.
Definition: WPSGraphicStyle.h:237
libwps_internal.h
WPSColor::isBlack
bool isBlack() const
return true if the color is black
Definition: libwps_internal.h:345
WPSGraphicStyle::hasPattern
bool hasPattern() const
returns true if the pattern is defined
Definition: WPSGraphicStyle.h:267
WPSGraphicStyle::Pattern::m_picture
librevenge::RVNGBinaryData m_picture
a picture
Definition: WPSGraphicStyle.h:194
WPSGraphicStyle::LineJoin
LineJoin
an enum used to define the basic line join
Definition: WPSGraphicStyle.h:43
WPSGraphicStyle::hasBorders
bool hasBorders() const
return true if the frame has some border
Definition: WPSGraphicStyle.h:304
WPSGraphicStyle::setPattern
void setPattern(Pattern const &pat)
set the pattern
Definition: WPSGraphicStyle.h:262
WPSGraphicStyle::m_pattern
Pattern m_pattern
the pattern if it exists
Definition: WPSGraphicStyle.h:368
WPSGraphicStyle::operator=
WPSGraphicStyle & operator=(WPSGraphicStyle const &)=default
WPSGraphicStyle::m_shadowColor
WPSColor m_shadowColor
the shadow color
Definition: WPSGraphicStyle.h:361
WPSGraphicStyle::Pattern::getUniqueColor
bool getUniqueColor(WPSColor &col) const
check if the pattern has only one color; if so returns true...
Definition: WPSGraphicStyle.cpp:45
WPSGraphicStyle::hasSurface
bool hasSurface() const
returns true if the interior surface is defined
Definition: WPSGraphicStyle.h:277
Vec2::cmp
int cmp(Vec2< T > const &p) const
a comparison function: which first compares x then y
Definition: libwps_internal.h:647
WPSGraphicStyle::m_lineOpacity
float m_lineOpacity
the line opacity: 0=transparent
Definition: WPSGraphicStyle.h:350
WPSGraphicStyle::GradientStop::m_offset
float m_offset
the offset
Definition: WPSGraphicStyle.h:78
WPSGraphicStyle::Pattern::m_colors
WPSColor m_colors[2]
the two indexed colors
Definition: WPSGraphicStyle.h:189
WPSGraphicStyle::m_extra
std::string m_extra
extra data
Definition: WPSGraphicStyle.h:411
WPSGraphicStyle::G_Ellipsoid
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::m_gradientStopList
std::vector< GradientStop > m_gradientStopList
the list of gradient limits
Definition: WPSGraphicStyle.h:373
WPSGraphicStyle::m_fillRuleEvenOdd
bool m_fillRuleEvenOdd
true if the fill rule is evenod
Definition: WPSGraphicStyle.h:354
WPSGraphicStyle::m_backgroundColor
WPSColor m_backgroundColor
the background color
Definition: WPSGraphicStyle.h:391
WPSGraphicStyle::GradientStop::m_color
WPSColor m_color
the color
Definition: WPSGraphicStyle.h:80
WPSColor
the class to store a color
Definition: libwps_internal.h:280
WPSGraphicStyle::addTo
void addTo(librevenge::RVNGPropertyList &pList, bool only1d=false) const
add all the parameters to the propList excepted the frame parameter: the background and the borders ...
Definition: WPSGraphicStyle.cpp:165
WPSGraphicStyle::hasSurfaceColor
bool hasSurfaceColor() const
returns true if the surface is defined
Definition: WPSGraphicStyle.h:257
WPSGraphicStyle::m_surfaceColor
WPSColor m_surfaceColor
the surface color
Definition: WPSGraphicStyle.h:356
WPSGraphicStyle::addFrameTo
void addFrameTo(librevenge::RVNGPropertyList &pList) const
add all the frame parameters to propList: the background and the borders
Definition: WPSGraphicStyle.cpp:369
WPSGraphicStyle::Pattern::Pattern
Pattern()
constructor
Definition: WPSGraphicStyle.h:91
WPSGraphicStyle::J_Bevel
Definition: WPSGraphicStyle.h:43
WPSGraphicStyle::C_Butt
Definition: WPSGraphicStyle.h:41
WPSGraphicStyle::hasGradient
bool hasGradient(bool complex=false) const
returns true if the gradient is defined
Definition: WPSGraphicStyle.h:272
WPSGraphicStyle::m_arrows
bool m_arrows[2]
two bool to indicated if extremity has arrow or not
Definition: WPSGraphicStyle.h:384
WPSGraphicStyle::m_lineColor
WPSColor m_lineColor
the line color
Definition: WPSGraphicStyle.h:352
WPSGraphicStyle::m_backgroundOpacity
float m_backgroundOpacity
true if the background has some color
Definition: WPSGraphicStyle.h:393
WPSGraphicStyle::m_gradientBorder
float m_gradientBorder
the gradient border opacity
Definition: WPSGraphicStyle.h:377
WPSGraphicStyle::hasSameBorders
bool hasSameBorders() const
return true if the frame has some border
Definition: WPSGraphicStyle.h:309
WPSGraphicStyle::Pattern::operator<<
friend std::ostream & operator<<(std::ostream &o, Pattern const &pat)
a print operator
Definition: WPSGraphicStyle.h:164
WPSGraphicStyle::hasBackgroundColor
bool hasBackgroundColor() const
returns true if the background is defined
Definition: WPSGraphicStyle.h:288
WPSGraphicStyle::C_Round
Definition: WPSGraphicStyle.h:41
WPSGraphicStyle::GradientStop::GradientStop
GradientStop(float offset=0.0, WPSColor const &col=WPSColor::black(), float opacity=1.0)
constructor
Definition: WPSGraphicStyle.h:51
WPSGraphicStyle::LineCap
LineCap
an enum used to define the basic line cap
Definition: WPSGraphicStyle.h:41
WPSGraphicStyle::WPSGraphicStyle
WPSGraphicStyle()
constructor
Definition: WPSGraphicStyle.h:201
Vec2< int >
WPSGraphicStyle::setBackgroundColor
void setBackgroundColor(WPSColor const &col, float opacity=1)
set the background color
Definition: WPSGraphicStyle.h:282
WPSGraphicStyle::m_lineWidth
float m_lineWidth
the linewidth
Definition: WPSGraphicStyle.h:342
WPSGraphicStyle::C_Square
Definition: WPSGraphicStyle.h:41
WPSGraphicStyle::operator<<
friend std::ostream & operator<<(std::ostream &o, WPSGraphicStyle const &st)
a print operator
Definition: WPSGraphicStyle.cpp:509
WPSGraphicStyle::setShadowColor
void setShadowColor(WPSColor const &col, float opacity=1)
set the shadow color
Definition: WPSGraphicStyle.h:293
WPSGraphicStyle::Pattern
a basic pattern used in a WPSGraphicStyle:
Definition: WPSGraphicStyle.h:88
WPSGraphicStyle::resetBorders
void resetBorders()
reset the border
Definition: WPSGraphicStyle.h:326
WPSGraphicStyle::G_Radial
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::m_gradientType
GradientType m_gradientType
the gradient type
Definition: WPSGraphicStyle.h:371
WPSGraphicStyle::GradientType
GradientType
an enum used to define the gradient type
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::G_Linear
Definition: WPSGraphicStyle.h:45
WPSGraphicStyle::GradientStop::operator<<
friend std::ostream & operator<<(std::ostream &o, GradientStop const &st)
a print operator
Definition: WPSGraphicStyle.h:69
WPSGraphicStyle::m_frameNextName
librevenge::RVNGString m_frameNextName
the frame next name (if there is a link)
Definition: WPSGraphicStyle.h:399