Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Macros | Functions
SkSVGNode.cpp File Reference
#include "include/core/SkCanvas.h"
#include "include/core/SkMatrix.h"
#include "include/pathops/SkPathOps.h"
#include "include/private/base/SkTPin.h"
#include "modules/svg/include/SkSVGNode.h"
#include "modules/svg/include/SkSVGRenderContext.h"
#include "modules/svg/include/SkSVGValue.h"
#include "src/base/SkTLazy.h"

Go to the source code of this file.

Macros

#define PARSE_AND_SET(svgName, attrName)
 

Functions

template<typename T >
void SetInheritedByDefault (SkTLazy< T > &presentation_attribute, const T &value)
 

Macro Definition Documentation

◆ PARSE_AND_SET

#define PARSE_AND_SET (   svgName,
  attrName 
)
Value:
this->set##attrName( \
SkSVGAttributeParser::parseProperty<decltype(fPresentationAttributes.f##attrName)>( \
svgName, n, v))
static ParseResult< PropertyT > parseProperty(const char *expectedName, const char *name, const char *value)

Function Documentation

◆ SetInheritedByDefault()

template<typename T >
void SetInheritedByDefault ( SkTLazy< T > &  presentation_attribute,
const T value 
)

Definition at line 80 of file SkSVGNode.cpp.

80 {
81 if (value.type() != T::Type::kInherit) {
82 presentation_attribute.set(value);
83 } else {
84 // kInherited values are semantically equivalent to
85 // the absence of a local presentation attribute.
86 presentation_attribute.reset();
87 }
88}
void reset()
Definition SkTLazy.h:69
T * set(const T &src)
Definition SkTLazy.h:56
uint8_t value