The HPS::LineAttributeKit class is a user space object, useful for carrying a group of attribute settings related to lines. More...
#include <hps.h>
Public Member Functions | |
LineAttributeKit () | |
Initializes an empty kit. More... | |
LineAttributeKit (LineAttributeKit const &in_kit) | |
The copy constructor creates a new LineAttributeKit object that contains the same settings as the source object. More... | |
LineAttributeKit (LineAttributeKit &&in_that) | |
The move constructor creates a LineAttributeKit by transferring the underlying impl of the rvalue reference to this LineAttributeKit thereby avoiding a copy and allocation. More... | |
LineAttributeKit & | operator= (LineAttributeKit &&in_that) |
The move assignment operator transfers the underlying impl of the rvalue reference to this LineAttributeKit thereby avoiding a copy. More... | |
virtual | ~LineAttributeKit () |
Destroy this kit. More... | |
HPS::Type | ObjectType () const |
void | Set (LineAttributeKit const &in_kit) |
Copies all settings from the source LineAttributeKit into this object. More... | |
void | Show (LineAttributeKit &out_kit) const |
Copies all settings from this LineAttributeKit into the given LineAttributeKit. More... | |
LineAttributeKit & | operator= (LineAttributeKit const &in_kit) |
Copies the source LineAttributeKit into this object. More... | |
bool | Empty () const |
Indicates whether this object has any values set on it. More... | |
bool | Equals (LineAttributeKit const &in_kit) const |
Check if the source LineAttributeKit is equivalent to this object. More... | |
bool | operator== (LineAttributeKit const &in_kit) const |
Check if the source LineAttributeKit is equivalent to this object. More... | |
bool | operator!= (LineAttributeKit const &in_kit) const |
Check if the source LineAttributeKit is not equivalent to this object. More... | |
LineAttributeKit & | SetPattern (char const *in_name) |
Specifies the pattern of lines. More... | |
LineAttributeKit & | SetPattern (char const *in_name, LinePatternOptionsKit const &in_options) |
Specifies the pattern of lines. More... | |
LineAttributeKit & | SetWeight (float in_weight, Line::SizeUnits in_units=Line::SizeUnits::ScaleFactor) |
Sets the weight of lines. More... | |
LineAttributeKit & | UnsetPattern () |
Removes the line pattern setting for lines. More... | |
LineAttributeKit & | UnsetWeight () |
Removes the weight setting for lines. More... | |
LineAttributeKit & | UnsetEverything () |
Removes all settings from this object. More... | |
bool | ShowPattern (UTF8 &out_pattern, LinePatternOptionsKit &out_options) const |
Shows the pattern used to draw lines. More... | |
bool | ShowWeight (float &out_weight, Line::SizeUnits &out_units) const |
Shows the weight of lines. More... | |
virtual HPS::Type | Type () const |
This function returns the true type of the underlying object. More... | |
virtual void | Reset () |
Resets this object to its initial, uninitialized state. More... | |
bool | HasType (HPS::Type in_mask) const |
This function indicates whether this Object has the given Type mask. More... | |
intptr_t | GetClassID () const |
Returns a unique identifier that is shared by all objects of the same class. More... | |
intptr_t | GetInstanceID () const |
Returns an identifier that can be used to identify which instance of a class an object is. More... | |
Static Public Member Functions | |
static LineAttributeKit | GetDefault () |
Creates a LineAttributeKit which contains the default settings. More... | |
template<typename T > | |
static intptr_t | ClassID () |
Unique identifier for this class. More... | |
Static Public Attributes | |
static const HPS::Type | staticType = HPS::Type::LineAttributeKit |
The HPS::LineAttributeKit class is a user space object, useful for carrying a group of attribute settings related to lines.
Calling HPS::LineAttributeKit::GetDefault() will return a kit with values found in this table.
HPS::LineAttributeKit::LineAttributeKit | ( | ) |
Initializes an empty kit.
HPS::LineAttributeKit::LineAttributeKit | ( | LineAttributeKit const & | in_kit | ) |
The copy constructor creates a new LineAttributeKit object that contains the same settings as the source object.
in_kit | The source object to copy. |
HPS::LineAttributeKit::LineAttributeKit | ( | LineAttributeKit && | in_that | ) |
The move constructor creates a LineAttributeKit by transferring the underlying impl of the rvalue reference to this LineAttributeKit thereby avoiding a copy and allocation.
in_that | An rvalue reference to a LineAttributeKit to take the impl from. |
|
virtual |
Destroy this kit.
|
inlinestaticinherited |
Unique identifier for this class.
Note: this method uses construction of static objects. If used in a constructor, it should be used in the body not the initializer list.
|
virtual |
Indicates whether this object has any values set on it.
Reimplemented from HPS::Object.
bool HPS::LineAttributeKit::Equals | ( | LineAttributeKit const & | in_kit | ) | const |
Check if the source LineAttributeKit is equivalent to this object.
in_kit | The source LineAttributeKit to compare to this object. |
|
inherited |
Returns a unique identifier that is shared by all objects of the same class.
|
static |
Creates a LineAttributeKit which contains the default settings.
The returned object will not necessarily have values set for every option, but it will have settings for those options where it is reasonable to have a default.
|
inherited |
Returns an identifier that can be used to identify which instance of a class an object is.
Different keys and controls will return the same value if they are backed by the same database resource.
|
inherited |
|
inlinevirtual |
bool HPS::LineAttributeKit::operator!= | ( | LineAttributeKit const & | in_kit | ) | const |
Check if the source LineAttributeKit is not equivalent to this object.
in_kit | The source LineAttributeKit to compare to this object. |
LineAttributeKit& HPS::LineAttributeKit::operator= | ( | LineAttributeKit && | in_that | ) |
The move assignment operator transfers the underlying impl of the rvalue reference to this LineAttributeKit thereby avoiding a copy.
in_that | An rvalue reference to an LineAttributeKit to take the impl from. |
LineAttributeKit& HPS::LineAttributeKit::operator= | ( | LineAttributeKit const & | in_kit | ) |
Copies the source LineAttributeKit into this object.
in_kit | The source LineAttributeKit to copy. |
bool HPS::LineAttributeKit::operator== | ( | LineAttributeKit const & | in_kit | ) | const |
Check if the source LineAttributeKit is equivalent to this object.
in_kit | The source LineAttributeKit to compare to this object. |
|
virtualinherited |
Resets this object to its initial, uninitialized state.
Reimplemented in HPS::EventHandler, HPS::EventDispatcher, HPS::World, HPS::HighlightSearchResults, HPS::HighlightSearchResultsIterator, HPS::SelectionResults, HPS::SelectionResultsIterator, HPS::FontSearchResults, HPS::FontSearchResultsIterator, HPS::SearchResults, and HPS::SearchResultsIterator.
void HPS::LineAttributeKit::Set | ( | LineAttributeKit const & | in_kit | ) |
Copies all settings from the source LineAttributeKit into this object.
in_kit | The source LineAttributeKit to copy. |
LineAttributeKit& HPS::LineAttributeKit::SetPattern | ( | char const * | in_name | ) |
Specifies the pattern of lines.
in_name | The name of a line pattern, defined in a portfolio that is accessible. |
LineAttributeKit& HPS::LineAttributeKit::SetPattern | ( | char const * | in_name, |
LinePatternOptionsKit const & | in_options | ||
) |
Specifies the pattern of lines.
in_name | The name of a line pattern, defined in a portfolio that is accessible. |
in_options | A set of options that modify how the named line pattern is applied. |
LineAttributeKit& HPS::LineAttributeKit::SetWeight | ( | float | in_weight, |
Line::SizeUnits | in_units = Line::SizeUnits::ScaleFactor |
||
) |
Sets the weight of lines.
in_weight | The weight value for lines. |
in_units | The units applied to in_weight. |
void HPS::LineAttributeKit::Show | ( | LineAttributeKit & | out_kit | ) | const |
Copies all settings from this LineAttributeKit into the given LineAttributeKit.
out_kit | The LineAttributeKit to populate with the contents of this object. |
bool HPS::LineAttributeKit::ShowPattern | ( | UTF8 & | out_pattern, |
LinePatternOptionsKit & | out_options | ||
) | const |
Shows the pattern used to draw lines.
out_pattern | The name of a line pattern, defined in a portfolio that is accessible. |
out_options | A set of options that modify how the named line pattern is applied. |
bool HPS::LineAttributeKit::ShowWeight | ( | float & | out_weight, |
Line::SizeUnits & | out_units | ||
) | const |
Shows the weight of lines.
out_weight | The weight value for lines. |
out_units | The units applied to in_weight. |
|
inlinevirtualinherited |
This function returns the true type of the underlying object.
This function is useful for finding the type of smart pointer objects that have been cast to more generic types.
Reimplemented from HPS::Object.
LineAttributeKit& HPS::LineAttributeKit::UnsetEverything | ( | ) |
Removes all settings from this object.
LineAttributeKit& HPS::LineAttributeKit::UnsetPattern | ( | ) |
Removes the line pattern setting for lines.
LineAttributeKit& HPS::LineAttributeKit::UnsetWeight | ( | ) |
Removes the weight setting for lines.
|
static |