Represents a paint server, which can be a solid color, a reference to another element, or a special value like "none" or "context-fill".
More...
#include "donner/svg/properties/PaintServer.h"
|
| struct | None |
| | Represents the "none" value for a paint server. More...
|
| struct | ContextFill |
| | Represents the "context-fill" value for a paint server. More...
|
| struct | ContextStroke |
| | Represents the "context-stroke" value for a paint server. More...
|
| struct | Solid |
| | Represents a solid color paint server. More...
|
| struct | ElementReference |
| | Represents a reference to another element, which originates from a url() reference. Should point to another paint server. More...
|
|
| | PaintServer (Type value) |
| | Construct a paint server with the given value.
|
|
constexpr | PaintServer (None) |
| | Construct a paint server with no value, None.
|
|
constexpr | PaintServer (Solid solid) |
| | Construct a paint server for a solid color.
|
|
bool | operator== (const PaintServer &other) const |
| | Equality operator.
|
| template<typename T> |
| bool | is () const |
| | Returns true if the paint server is of the requested type.
|
| template<typename T> |
| T & | get () & |
| | Returns the value of the paint server, if it is of the requested type.
|
| template<typename T> |
| const T & | get () const & |
| | Returns the value of the paint server, if it is of the requested type.
|
| template<typename T> |
| T && | get () && |
| | Returns the value of the paint server, if it is of the requested type.
|
|
|
Type | value |
| | Current paint server.
|
|
|
std::ostream & | operator<< (std::ostream &os, const PaintServer &paint) |
| | Ostream output operator.
|
Represents a paint server, which can be a solid color, a reference to another element, or a special value like "none" or "context-fill".
◆ PaintServer()
| donner::svg::PaintServer::PaintServer |
( |
Type | value | ) |
|
|
inline |
Construct a paint server with the given value.
- Parameters
-
| value | The value of the paint server, one of the supported subtypes of PaintServer as listed by the Type variant. |
◆ get() [1/3]
template<typename T>
| T & donner::svg::PaintServer::get |
( |
| ) |
& |
|
inline |
Returns the value of the paint server, if it is of the requested type.
- Template Parameters
-
| T | The type of the paint server to get. |
◆ get() [2/3]
template<typename T>
| T && donner::svg::PaintServer::get |
( |
| ) |
&& |
|
inline |
Returns the value of the paint server, if it is of the requested type.
- Template Parameters
-
| T | The type of the paint server to get. |
◆ get() [3/3]
template<typename T>
| const T & donner::svg::PaintServer::get |
( |
| ) |
const & |
|
inline |
Returns the value of the paint server, if it is of the requested type.
- Template Parameters
-
| T | The type of the paint server to get. |
◆ is()
template<typename T>
| bool donner::svg::PaintServer::is |
( |
| ) |
const |
|
inline |
Returns true if the paint server is of the requested type.
- Template Parameters
-
| T | The type of the paint server to check. |
The documentation for this struct was generated from the following files:
- donner/svg/properties/PaintServer.h
- donner/svg/properties/PaintServer.cc