Skip To Content ArcGIS for Developers Sign In Dashboard

SimpleRenderer Class

(Esri::ArcGISRuntime::SimpleRenderer)

A simple renderer based on a single symbol. More...

Header: #include <SimpleRenderer>
Since: Esri::ArcGISRuntime 100.0
Inherits: Renderer

Public Functions

SimpleRenderer(QObject *parent = nullptr)
SimpleRenderer(Symbol *symbol, QObject *parent = nullptr)
~SimpleRenderer()
QString description() const
QString label() const
void setDescription(const QString &description)
void setLabel(const QString &label)
void setSymbol(Symbol *symbol)
Symbol *symbol() const

Additional Inherited Members

Detailed Description

A simple renderer based on a single symbol.

Simple renderers symbolize all graphics in a graphics overlay or features in a feature layer according to a given scheme. Simple renderers use a simple scheme, meaning the same symbol is used for all graphics and features, regardless of their attribute values.

Example:

Apply a SimpleRenderer to a GraphicsOverlay:

SimpleMarkerSymbol* simpleMarker = new SimpleMarkerSymbol(SimpleMarkerSymbolStyle::Circle, QColor(Qt::blue), 16.0, this);
SimpleRenderer* simpleRenderer = new SimpleRenderer(simpleMarker, this);
GraphicsOverlay* graphicsOverlay = new GraphicsOverlay(this);
graphicsOverlay->setRenderer(simpleRenderer);

Member Function Documentation

SimpleRenderer::SimpleRenderer(QObject *parent = nullptr)

Default constructor with an optional parent.

SimpleRenderer::SimpleRenderer(Symbol *symbol, QObject *parent = nullptr)

Constructor that takes a symbol with an optional parent.

SimpleRenderer::~SimpleRenderer()

Destructor.

QString SimpleRenderer::description() const

Returns the description for the renderer.

See also setDescription().

QString SimpleRenderer::label() const

Returns the label for the renderer.

See also setLabel().

void SimpleRenderer::setDescription(const QString &description)

Sets the description for the renderer.

See also description().

void SimpleRenderer::setLabel(const QString &label)

Sets the label for the renderer.

See also label().

void SimpleRenderer::setSymbol(Symbol *symbol)

Sets the symbol for the renderer.

This symbol will be applied to all graphics or features that are in the layer that this renderer is applied to.

See also symbol().

Symbol *SimpleRenderer::symbol() const

Returns the symbol for the renderer.

See also setSymbol.


Feedback on this topic?