A Symbology Enconding visitor that finds a color given a symbolizer element. If you want to use this visitor, use a command like: te::se::SymbolizerColorFinder scf; scf.find(symbolizer); te::color::RGBAColor color = scf.getColor();
More...
#include <SymbolizerColorFinder.h>
Public Member Functions | |
Initializer Methods | |
SymbolizerColorFinder () | |
Constructor. More... | |
~SymbolizerColorFinder () | |
Destructor. More... | |
Find Method | |
Method that can be used to find a color based on Symbology Enconding symbolizer elements. | |
void | find (const te::se::Symbolizer *symbolizer) |
It find the color based on given symbolizer. More... | |
te::color::RGBAColor | getColor () |
Get the color. More... | |
Visitor Methods | |
All concrete visitors must implement these methods. | |
void | visit (const te::se::Style &visited) |
void | visit (const te::se::FeatureTypeStyle &visited) |
void | visit (const te::se::CoverageStyle &visited) |
void | visit (const te::se::Symbolizer &visited) |
void | visit (const te::se::PolygonSymbolizer &visited) |
void | visit (const te::se::LineSymbolizer &visited) |
void | visit (const te::se::PointSymbolizer &visited) |
void | visit (const te::se::TextSymbolizer &visited) |
void | visit (const te::se::RasterSymbolizer &visited) |
Protected Attributes | |
te::color::RGBAColor | m_color |
Color found given a symbolizer. More... | |
Private Member Functions | |
void | find (const te::se::Stroke *stroke) |
Internal method that finds the color based on given Stroke element. More... | |
void | find (const te::se::Fill *fill) |
Internal method that finds the color based on given Fill element. More... | |
void | find (const te::se::Mark *mark) |
Internal method that finds the color based on given Mark element. More... | |
A Symbology Enconding visitor that finds a color given a symbolizer element. If you want to use this visitor, use a command like: te::se::SymbolizerColorFinder scf; scf.find(symbolizer); te::color::RGBAColor color = scf.getColor();
Definition at line 60 of file SymbolizerColorFinder.h.
te::se::SymbolizerColorFinder::SymbolizerColorFinder | ( | ) |
Constructor.
Definition at line 42 of file SymbolizerColorFinder.cpp.
te::se::SymbolizerColorFinder::~SymbolizerColorFinder | ( | ) |
Destructor.
Definition at line 46 of file SymbolizerColorFinder.cpp.
void te::se::SymbolizerColorFinder::find | ( | const te::se::Symbolizer * | symbolizer | ) |
It find the color based on given symbolizer.
symbolizer | The symbolizer that will be used searched. |
Definition at line 50 of file SymbolizerColorFinder.cpp.
References te::common::BaseVisitable< T, R >::accept().
Referenced by te::qt::widgets::GroupingWidget::updateUi().
|
private |
Internal method that finds the color based on given Stroke element.
stroke | The Stroke element that will be used to find the color. |
Definition at line 103 of file SymbolizerColorFinder.cpp.
References te::se::GetColor().
|
private |
Internal method that finds the color based on given Fill element.
fill | The Fill element that will be used to find the color. |
Definition at line 108 of file SymbolizerColorFinder.cpp.
References te::se::GetColor().
|
private |
Internal method that finds the color based on given Mark element.
mark | The mark element that will be used to find the color. |
Definition at line 113 of file SymbolizerColorFinder.cpp.
References te::se::Mark::getFill().
|
inline |
Get the color.
Definition at line 93 of file SymbolizerColorFinder.h.
Referenced by te::qt::widgets::GroupingWidget::updateUi().
|
virtual |
Implements te::se::Visitor.
Definition at line 55 of file SymbolizerColorFinder.cpp.
|
virtual |
Implements te::se::Visitor.
Definition at line 59 of file SymbolizerColorFinder.cpp.
|
virtual |
Implements te::se::Visitor.
Definition at line 63 of file SymbolizerColorFinder.cpp.
|
virtual |
Implements te::se::Visitor.
Definition at line 67 of file SymbolizerColorFinder.cpp.
|
virtual |
Implements te::se::Visitor.
Definition at line 71 of file SymbolizerColorFinder.cpp.
References te::se::PolygonSymbolizer::getFill().
|
virtual |
Implements te::se::Visitor.
Definition at line 79 of file SymbolizerColorFinder.cpp.
References te::se::LineSymbolizer::getStroke().
|
virtual |
Implements te::se::Visitor.
Definition at line 87 of file SymbolizerColorFinder.cpp.
References te::se::PointSymbolizer::getGraphic(), and te::se::Graphic::getMarks().
|
virtual |
Implements te::se::Visitor.
Definition at line 95 of file SymbolizerColorFinder.cpp.
|
virtual |
Implements te::se::Visitor.
Definition at line 99 of file SymbolizerColorFinder.cpp.
|
protected |
Color found given a symbolizer.
Definition at line 139 of file SymbolizerColorFinder.h.