GlyphLinePatternElement
-
class HPS::GlyphLinePatternElement : public HPS::LinePatternElement
The GlyphLinePatternElement class is a user space object. It is used for specifying glyphs elements within a line pattern.
Public Functions
-
GlyphLinePatternElement()
The default constructor creates an empty GlyphLinePatternElement object.
-
GlyphLinePatternElement(GlyphLinePatternElement &&in_that)
The move constructor creates a GlyphLinePatternElement by transferring the underlying impl of the rvalue reference to this GlyphLinePatternElement thereby avoiding a copy and allocation.
- Parameters
in_that – An rvalue reference to a GlyphLinePatternElement to take the impl from.
-
GlyphLinePatternElement(GlyphLinePatternElement const &in_that)
The copy constructor creates a new GlyphLinePatternElement object that contains the same settings as the source GlyphLinePatternElement.
- Parameters
in_that – The source GlyphLinePatternElement to copy.
-
GlyphLinePatternElement(LinePatternElement const &in_that)
This constructor creates a GlyphLinePatternElement object that contains the same settings as the source LinePatternElement. The copy will only be successful if the source line pattern element is really an upcast of a glyph line pattern element. Otherwise the copy will fail and the resulting GlyphLinePatternElement will be invalid.
- Parameters
in_that – The source LinePatternElement to copy.
-
inline virtual HPS::Type ObjectType() const
This function returns the type the object, as declared (if the object is derived, this does not give the true type of the derived object).
- Returns
The declared type of the object in question, which may differ from the true, underlying type.
-
GlyphLinePatternElement &operator=(GlyphLinePatternElement &&in_that)
The move assignment operator transfers the underlying impl of the rvalue reference to this GlyphLinePatternElement thereby avoiding a copy.
- Parameters
in_that – An rvalue reference to a GlyphLinePatternElement to take the impl from.
- Returns
A reference to this GlyphLinePatternElement.
-
GlyphLinePatternElement &operator=(GlyphLinePatternElement const &in_that)
Copies the source GlyphLinePatternElement into this GlyphLinePatternElement.
- Parameters
in_that – The source GlyphLinePatternElement to copy.
- Returns
A reference to this GlyphLinePatternElement.
-
void SetFixed(bool in_state)
Sets whether the angle of the GlyphLinePatternElement should be fixed relative to the line vector.
- Parameters
in_state – Whether the angle of the GlyphLinePatternElement should be fixed relative to the line vector.
-
void SetInsetBehavior(LinePattern::InsetBehavior in_behavior)
Sets the inset behavior for this GlyphLinePatternElement.
- Parameters
in_behavior – The inset behavior for this GlyphLinePatternElement.
-
void SetMirror(bool in_state)
Sets whether to flip this GlyphLinePatternElement about the x-axis prior to applying any rotation.
- Parameters
in_state – Whether to flip this GlyphLinePatternElement about the x-axis prior to applying any rotation.
-
void SetRotation(float in_degrees)
Sets the angle in degrees the GlyphLinePatternElement is rotated relative to the line vector.
- Parameters
in_degrees – The angle in degrees the GlyphLinePatternElement is rotated relative to the line vector.
-
void SetSource(char const *in_source)
Sets the name of the source for this GlyphLinePatternElement.
- Parameters
in_source – UTF8-encoded name of the source for this GlyphLinePatternElement.
-
void SetWeight(float in_weight, LinePattern::SizeUnits in_units)
Sets the weight for this GlyphLinePatternElement.
- Parameters
in_weight – The weight for this GlyphLinePatternElement.
in_units – The units of the weight for this GlyphLinePatternElement.
-
bool ShowFixed(bool &out_state) const
Shows whether the angle of the GlyphLinePatternElement should be fixed relative to the line vector.
- Parameters
out_state – Whether the angle of the GlyphLinePatternElement should be fixed relative to the line vector.
- Returns
true if a fixed flag was set, false otherwise.
-
bool ShowInsetBehavior(LinePattern::InsetBehavior &out_behavior) const
Shows the inset behavior for this GlyphLinePatternElement.
- Parameters
out_behavior – The inset behavior for this GlyphLinePatternElement.
- Returns
true if an inset behavior was set, false otherwise.
-
bool ShowMirror(bool &out_state) const
Shows whether to flip this GlyphLinePatternElement about the x-axis prior to applying any rotation.
- Parameters
out_state – Whether to flip this GlyphLinePatternElement about the x-axis prior to applying any rotation.
- Returns
true if a mirror flag was set, false otherwise.
-
bool ShowRotation(float &out_degrees) const
Shows the angle in degrees the GlyphLinePatternElement is rotated relative to the line vector.
- Parameters
out_degrees – The angle in degrees the GlyphLinePatternElement is rotated relative to the line vector.
- Returns
true if an angle was set, false otherwise.
-
bool ShowSource(UTF8 &out_source) const
Shows the name of the source for this GlyphLinePatternElement.
- Parameters
out_source – UTF8-encoded name of the source for this GlyphLinePatternElement.
- Returns
true if a source was set, false otherwise.
-
bool ShowWeight(float &out_weight, LinePattern::SizeUnits &out_units) const
Shows the weight for this GlyphLinePatternElement.
- Parameters
out_weight – The weight for this GlyphLinePatternElement.
out_units – The units for the weight for this GlyphLinePatternElement.
- Returns
true if a weight was set, false otherwise.
-
~GlyphLinePatternElement()
Public Static Attributes
-
static const HPS::Type staticType = HPS::Type::GlyphLinePatternElement
-
GlyphLinePatternElement()