The HPS::SubwindowKit class is a user space object, useful for carrying a group of attribute settings related to subwindows. More...
#include <hps.h>
Public Member Functions | |
SubwindowKit () | |
Initializes an empty kit. More... | |
SubwindowKit (SubwindowKit const &in_kit) | |
Copies the kit in_kit into this kit. More... | |
SubwindowKit (SubwindowKit &&in_that) | |
The move constructor creates a SubwindowKit by transferring the underlying impl of the rvalue reference to this SubwindowKit thereby avoiding a copy and allocation. More... | |
SubwindowKit & | operator= (SubwindowKit &&in_that) |
The move assignment operator transfers the underlying impl of the rvalue reference to this SubwindowKit thereby avoiding a copy. More... | |
virtual | ~SubwindowKit () |
Destroy this kit. More... | |
HPS::Type | ObjectType () const |
void | Set (SubwindowKit const &in_kit) |
Copies the source SubwindowKit into this object. More... | |
void | Show (SubwindowKit &out_kit) const |
Copies this object into the given SubwindowKit. More... | |
SubwindowKit & | operator= (SubwindowKit const &in_kit) |
Copies the source SubwindowKit into this object. More... | |
bool | Empty () const |
Indicates whether this object has any values set on it. More... | |
bool | Equals (SubwindowKit const &in_kit) const |
Check if the source SubwindowKit is equivalent to this object. More... | |
bool | operator== (SubwindowKit const &in_kit) const |
Check if the source SubwindowKit is equivalent to this object. More... | |
bool | operator!= (SubwindowKit const &in_kit) const |
Check if the source SubwindowKit is not equivalent to this object. More... | |
SubwindowKit & | SetSubwindow (Rectangle const &in_subwindow_position, Subwindow::Type in_subwindow_type=Subwindow::Type::Standard) |
Defines a portion of the containing window to act as a subwindow. More... | |
SubwindowKit & | SetSubwindow (Rectangle const &in_subwindow_position, IntRectangle const &in_subwindow_offsets, Subwindow::Type in_subwindow_type=Subwindow::Type::Standard) |
Defines a portion of the containing window to act as a subwindow. More... | |
SubwindowKit & | SetBackground (Subwindow::Background in_bg_type, char const *in_definition_name="") |
Controls the type of background to be used for subwindows originating from this segment. More... | |
SubwindowKit & | SetBorder (Subwindow::Border in_border_type) |
Controls the type of border, if any, that should be drawn for subwindows originating from this segment. More... | |
SubwindowKit & | SetRenderingAlgorithm (Subwindow::RenderingAlgorithm in_hsra) |
Determines the algorithm used to remove objects (or parts of objects) that are hidden from view by other objects. More... | |
SubwindowKit & | SetModelCompareMode (bool in_state, SegmentKey const &in_source1=SegmentKey(), SegmentKey const &in_source2=SegmentKey()) |
Sets 'model compare' rendering mode which displays a visual diff between the two source segments in this subwindow. More... | |
SubwindowKit & | SetModelCompareMode (SegmentKey const &in_source1, SegmentKey const &in_source2) |
Sets 'model compare' rendering mode which displays a visual diff between the two source segments in this subwindow. More... | |
SubwindowKit & | UnsetSubwindow () |
Removes a subwindow setting. More... | |
SubwindowKit & | UnsetBackground () |
Removes a subwindow background setting. More... | |
SubwindowKit & | UnsetBorder () |
Removes a subwindow border setting. More... | |
SubwindowKit & | UnsetRenderingAlgorithm () |
Removes a rendering algorithm setting. More... | |
SubwindowKit & | UnsetModelCompareMode () |
Removes model compare setting. More... | |
SubwindowKit & | UnsetEverything () |
Removes all settings from this object. More... | |
bool | ShowSubwindow (Rectangle &out_subwindow_position, IntRectangle &out_subwindow_offsets, Subwindow::Type &out_subwindow_type) const |
Shows the subwindow setting. More... | |
bool | ShowSubwindow (Rectangle &out_subwindow_position, Subwindow::Type &out_subwindow_type) const |
Shows the subwindow setting. More... | |
bool | ShowBackground (Subwindow::Background &out_bg_type, UTF8 &out_definition_name) const |
Shows the window background setting. More... | |
bool | ShowBorder (Subwindow::Border &out_border_type) const |
Shows the subwindow border setting. More... | |
bool | ShowRenderingAlgorithm (Subwindow::RenderingAlgorithm &out_hsra) const |
Shows the rendering algorithm setting. More... | |
bool | ShowModelCompareMode (bool &out_state, SegmentKey &out_source1, SegmentKey &out_source2) const |
Shows the model compare setting. 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 SubwindowKit | GetDefault () |
Creates a SubwindowKit 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::SubwindowKit |
The HPS::SubwindowKit class is a user space object, useful for carrying a group of attribute settings related to subwindows.
Calling HPS::SubwindowKit::GetDefault() will return a kit with values found in this table.
HPS::SubwindowKit::SubwindowKit | ( | ) |
Initializes an empty kit.
HPS::SubwindowKit::SubwindowKit | ( | SubwindowKit const & | in_kit | ) |
Copies the kit in_kit into this kit.
HPS::SubwindowKit::SubwindowKit | ( | SubwindowKit && | in_that | ) |
The move constructor creates a SubwindowKit by transferring the underlying impl of the rvalue reference to this SubwindowKit thereby avoiding a copy and allocation.
in_that | An rvalue reference to a SubwindowKit 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::SubwindowKit::Equals | ( | SubwindowKit const & | in_kit | ) | const |
Check if the source SubwindowKit is equivalent to this object.
in_kit | The source SubwindowKit to compare to this object. |
|
inherited |
Returns a unique identifier that is shared by all objects of the same class.
|
static |
Creates a SubwindowKit 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::SubwindowKit::operator!= | ( | SubwindowKit const & | in_kit | ) | const |
Check if the source SubwindowKit is not equivalent to this object.
in_kit | The source SubwindowKit to compare to this object. |
SubwindowKit& HPS::SubwindowKit::operator= | ( | SubwindowKit && | in_that | ) |
The move assignment operator transfers the underlying impl of the rvalue reference to this SubwindowKit thereby avoiding a copy.
in_that | An rvalue reference to a SubwindowKit to take the impl from. |
SubwindowKit& HPS::SubwindowKit::operator= | ( | SubwindowKit const & | in_kit | ) |
Copies the source SubwindowKit into this object.
in_kit | The source SubwindowKit to copy. |
bool HPS::SubwindowKit::operator== | ( | SubwindowKit const & | in_kit | ) | const |
Check if the source SubwindowKit is equivalent to this object.
in_kit | The source SubwindowKit 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::SubwindowKit::Set | ( | SubwindowKit const & | in_kit | ) |
Copies the source SubwindowKit into this object.
in_kit | The source object to copy. |
SubwindowKit& HPS::SubwindowKit::SetBackground | ( | Subwindow::Background | in_bg_type, |
char const * | in_definition_name = "" |
||
) |
Controls the type of background to be used for subwindows originating from this segment.
This has no effect when applied to segments without a subwindow present.
in_bg_type | The type of background to be used for subwindows originating from this segment. |
in_definition_name | the name of a definition to be used in the background. Only relevant if in_bg_type is Image or Cubemap. |
SubwindowKit& HPS::SubwindowKit::SetBorder | ( | Subwindow::Border | in_border_type | ) |
Controls the type of border, if any, that should be drawn for subwindows originating from this segment.
This has no effect when applied to segments without a subwindow present.
in_border_type | The type of border, if any, that should be drawn for subwindows originating from this segment. |
SubwindowKit& HPS::SubwindowKit::SetModelCompareMode | ( | bool | in_state, |
SegmentKey const & | in_source1 = SegmentKey() , |
||
SegmentKey const & | in_source2 = SegmentKey() |
||
) |
Sets 'model compare' rendering mode which displays a visual diff between the two source segments in this subwindow.
in_state | Toggles compare mode on or off. |
in_source1 | The first source model. |
in_source2 | The second source model. |
SubwindowKit& HPS::SubwindowKit::SetModelCompareMode | ( | SegmentKey const & | in_source1, |
SegmentKey const & | in_source2 | ||
) |
Sets 'model compare' rendering mode which displays a visual diff between the two source segments in this subwindow.
in_source1 | The first source model. |
in_source2 | The second source model. |
SubwindowKit& HPS::SubwindowKit::SetRenderingAlgorithm | ( | Subwindow::RenderingAlgorithm | in_hsra | ) |
Determines the algorithm used to remove objects (or parts of objects) that are hidden from view by other objects.
This has no effect when applied to segments without a subwindow present.
in_hsra | The algorithm used to identify and remove hidden surfaces. |
SubwindowKit& HPS::SubwindowKit::SetSubwindow | ( | Rectangle const & | in_subwindow_position, |
Subwindow::Type | in_subwindow_type = Subwindow::Type::Standard |
||
) |
Defines a portion of the containing window to act as a subwindow.
Window segments have an implicit subwindow of -1 to 1 in both x and y directions that cannot be changed. Other segments can be constrained to some portion of that space. Most other subwindow-related settings are only relevant if they are applied on a segment that also contains a subwindow.
in_subwindow_position | The portion of the containing window that should be reserved for a subwindow. The subwindow is defined in the context of a rectangle extending out a single unit in each direction from the origin. For example, a subwindow rectangle defined as Rectangle(0, 1, -1, 0) would occupy the lower right quarter of the containing window. |
in_subwindow_type | The type of subwindow to create. |
SubwindowKit& HPS::SubwindowKit::SetSubwindow | ( | Rectangle const & | in_subwindow_position, |
IntRectangle const & | in_subwindow_offsets, | ||
Subwindow::Type | in_subwindow_type = Subwindow::Type::Standard |
||
) |
Defines a portion of the containing window to act as a subwindow.
Window segments have an implicit subwindow of -1 to 1 in both x and y directions that cannot be changed. Other segments can be constrained to some portion of that space. Most other subwindow-related settings are only relevant if they are applied on a segment that also contains a subwindow.
in_subwindow_position | The portion of the containing window that should be reserved for a subwindow. The subwindow is defined in the context of a rectangle extending out a single unit in each direction from the origin. For example, a subwindow rectangle defined as Rectangle(0, 1, -1, 0) would occupy the lower right quarter of the containing window. |
in_subwindow_offsets | The pixel-space offsets to apply to each side of the given window position. |
in_subwindow_type | The type of subwindow to create. |
void HPS::SubwindowKit::Show | ( | SubwindowKit & | out_kit | ) | const |
Copies this object into the given SubwindowKit.
out_kit | The SubwindowKit to populate with the contents of this object. |
bool HPS::SubwindowKit::ShowBackground | ( | Subwindow::Background & | out_bg_type, |
UTF8 & | out_definition_name | ||
) | const |
Shows the window background setting.
out_bg_type | The type of background to be used for subwindows originating from this segment. |
out_definition_name | the name of a definition to be used in the background. |
bool HPS::SubwindowKit::ShowBorder | ( | Subwindow::Border & | out_border_type | ) | const |
Shows the subwindow border setting.
out_border_type | The type of border, if any, that should be drawn for subwindows originating from this segment. |
bool HPS::SubwindowKit::ShowModelCompareMode | ( | bool & | out_state, |
SegmentKey & | out_source1, | ||
SegmentKey & | out_source2 | ||
) | const |
Shows the model compare setting.
out_state | The model compare enabled state. |
out_source1 | The first source model. |
out_source2 | The second source model. |
bool HPS::SubwindowKit::ShowRenderingAlgorithm | ( | Subwindow::RenderingAlgorithm & | out_hsra | ) | const |
Shows the rendering algorithm setting.
out_hsra | The algorithm used to identify and remove hidden surfaces. |
bool HPS::SubwindowKit::ShowSubwindow | ( | Rectangle & | out_subwindow_position, |
IntRectangle & | out_subwindow_offsets, | ||
Subwindow::Type & | out_subwindow_type | ||
) | const |
Shows the subwindow setting.
out_subwindow_position | The portion of the containing window that should be reserved for a subwindow. |
out_subwindow_offsets | The pixel-space offsets being applied to the subwindow position. |
out_subwindow_type | The type of subwindow to create. |
bool HPS::SubwindowKit::ShowSubwindow | ( | Rectangle & | out_subwindow_position, |
Subwindow::Type & | out_subwindow_type | ||
) | const |
Shows the subwindow setting.
out_subwindow_position | The portion of the containing window that should be reserved for a subwindow. |
out_subwindow_type | The type of subwindow to create. |
|
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.
SubwindowKit& HPS::SubwindowKit::UnsetBackground | ( | ) |
Removes a subwindow background setting.
SubwindowKit& HPS::SubwindowKit::UnsetBorder | ( | ) |
Removes a subwindow border setting.
SubwindowKit& HPS::SubwindowKit::UnsetEverything | ( | ) |
Removes all settings from this object.
SubwindowKit& HPS::SubwindowKit::UnsetModelCompareMode | ( | ) |
Removes model compare setting.
SubwindowKit& HPS::SubwindowKit::UnsetRenderingAlgorithm | ( | ) |
Removes a rendering algorithm setting.
SubwindowKit& HPS::SubwindowKit::UnsetSubwindow | ( | ) |
Removes a subwindow setting.
|
static |