HPS::Publish::ArtworkKit

class HPS::Publish::ArtworkKit : public HPS::SprocketKit

The ArtworkKit class is a user space object. It acts as the container for all data that can be on an artwork in a Publish PDF.

Public Functions

ArtworkKit &AddView(ViewKit const &in_view)

Adds a view to the artwork. This will append the view to any existing views on the artwork. These correspond to values that will be passed to A3DPDF3DArtworkAddView.

Parameters

in_view – The view to add to the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &AddViews(size_t in_count, ViewKit const in_views[])

Adds views to the artwork. This will append the views to any existing views on the artwork. These correspond to values that will be passed to A3DPDF3DArtworkAddView.

Parameters
  • in_count – Size of the following array.

  • in_views – The views to add to the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &AddViews(ViewKitArray const &in_views)

Adds views to the artwork. This will append the views to any existing views on the artwork. These correspond to values that will be passed to A3DPDF3DArtworkAddView.

Parameters

in_views – The views to add to the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit()

The default constructor creates an empty ArtworkKit object.

ArtworkKit(ArtworkKit &&in_kit)

The move constructor creates an ArtworkKit by transferring the underlying object of the rvalue reference to this ArtworkKit.

Parameters

in_kit – An rvalue reference to an ArtworkKit to take the underlying object from.

ArtworkKit(ArtworkKit const &in_kit)

The copy constructor creates a new ArtworkKit object that contains the same settings as the source ArtworkKit.

Parameters

in_kit – The source ArtworkKit to copy.

virtual bool Empty() const

Indicates whether this ArtworkKit has any values set on it.

Returns

true if no values are set on this ArtworkKit, false otherwise.

bool Equals(ArtworkKit const &in_kit) const

Check if the source ArtworkKit is equivalent to this ArtworkKit.

Parameters

in_kit – The source ArtworkKit to compare to this ArtworkKit.

Returns

true if the objects are equivalent, false otherwise.

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.

bool operator!=(ArtworkKit const &in_kit) const

Check if the source ArtworkKit is not equivalent to this ArtworkKit.

Parameters

in_kit – The source ArtworkKit to compare to this ArtworkKit.

Returns

true if the objects are not equivalent, false otherwise.

ArtworkKit &operator=(ArtworkKit &&in_kit)

The move assignment operator transfers the underlying object of the rvalue reference to this ArtworkKit.

Parameters

in_kit – An rvalue reference to an ArtworkKit to take the underlying object from.

Returns

A reference to this ArtworkKit.

ArtworkKit &operator=(ArtworkKit const &in_kit)

Copies the source ArtworkKit into this ArtworkKit.

Parameters

in_kit – The source ArtworkKit to copy.

Returns

A reference to this ArtworkKit.

bool operator==(ArtworkKit const &in_kit) const

Check if the source ArtworkKit is equivalent to this ArtworkKit.

Parameters

in_kit – The source ArtworkKit to compare to this ArtworkKit.

Returns

true if the objects are equivalent, false otherwise.

void Set(ArtworkKit const &in_kit)

Copies the source ArtworkKit into this ArtworkKit.

Parameters

in_kit – The source ArtworkKit to copy.

ArtworkKit &SetAnimationStyle(Animation::Style in_style)

Sets the animation style for the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_eAnimationStyle.

Parameters

in_style – The animation style for the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetDefaultViewPreference(Artwork::View::Preference in_preference)

Sets the default view preference for the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_bKeepNativeDefaultView.

Parameters

in_preference – The default view preference for the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetDisplayPreference(Artwork::Display::Preference in_preference)

Sets the display preference for the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_bUseRuntimeDisplaySettings.

Parameters

in_preference – The display preference for the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetJavaScript(char const *in_source, Source::Type in_type = Source::Type::Code)

Sets the JavaScript source or file for the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_pcJavaScriptFileName.

Parameters
  • in_source – The JavaScript source or file (depending on the next argument) for the artwork.

  • in_type – The type of the preceding argument. Defaults to Source::Type::Code.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetPMIColor(HPS::RGBColor const &in_pmi_color)

Sets the PMI color for this artwork. This correspond to value that will be passed to A3DPDF3DArtworkData::m_sPMIColor .

Parameters

in_pmi_color – The color to apply to PMIs for this artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetPMICrossHighlighting(bool in_state)

Sets the whether to enable PMI cross-highlighting for the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_bActivatePMICrossHighlight.

Parameters

in_state – Whether to highlight the geometry associated with a piece of PMI when that PMI is selected.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetPMISemanticInformation(bool in_state)

Sets the whether to include semantic PMI information in the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkData::m_bAddPMISemanticInformation.

Parameters

in_state – Whether to include semantic PMI information in the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetView(ViewKit const &in_view)

Adds a view to the artwork. This will replace all views (if any) on the artwork. This corresponds to the value that will be passed to A3DPDF3DArtworkAddView.

Parameters

in_view – The view to add to the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetViews(size_t in_count, ViewKit const in_views[])

Adds views to the artwork. This will replace all views (if any) on the artwork. These correspond to values that will be passed to A3DPDF3DArtworkAddView.

Parameters
  • in_count – Size of the following array.

  • in_views – The views to add to the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &SetViews(ViewKitArray const &in_views)

Adds views to the artwork. This will replace all views (if any) on the artwork. These correspond to values that will be passed to A3DPDF3DArtworkAddView.

Parameters

in_views – The views to add to the artwork.

Returns

A reference to this ArtworkKit.

void Show(ArtworkKit &out_kit) const

Copies this ArtworkKit into the given ArtworkKit.

Parameters

out_kit – The ArtworkKit to populate with the contents of this ArtworkKit.

bool ShowAnimationStyle(Animation::Style &out_style) const

Shows the animation style setting.

Parameters

out_style – The animation style of the artwork.

Returns

true if an animation style was specified, false otherwise.

bool ShowDefaultViewPreference(Artwork::View::Preference &out_preference) const

Shows the default view preference setting.

Parameters

out_preference – The default view preference for the artwork.

Returns

true if a default view preference was specified, false otherwise.

bool ShowDisplayPreference(Artwork::Display::Preference &out_preference) const

Shows the display preference setting.

Parameters

out_preference – The display preference for the artwork.

Returns

true if a display preference was specified, false otherwise.

bool ShowJavaScript(UTF8 &out_source, Source::Type &out_type) const

Shows the JavaScript setting.

Parameters
  • out_source – The JavaScript source or file (depending on the next argument) for the artwork.

  • out_type – The type of the preceding argument.

Returns

true if a JavaScript source or file was specified, false otherwise.

bool ShowPMIColor(HPS::RGBColor &out_pmi_color) const

Shows the PMI color for the artwork.

Parameters

out_pmi_color – The PMI color for the artwork.

Returns

true if a PMI color was specified, false otherwise.

bool ShowPMICrossHighlighting(bool &out_state) const

Shows the PMI cross-highlighting setting.

Parameters

out_state – Whether to highlight the geometry associated with a piece of PMI when that PMI is selected.

Returns

true if a PMI cross-highlighting setting was specified, false otherwise.

bool ShowPMISemanticInformation(bool &out_state) const

Shows the semantic PMI information setting.

Parameters

out_state – Whether to include semantic PMI information in the artwork.

Returns

true if a semantic PMI information setting was specified, false otherwise.

bool ShowViews(ViewKitArray &out_views) const

Shows the views for the artwork.

Parameters

out_views – The views for the artwork.

Returns

true if views were specified, false otherwise.

ArtworkKit &UnsetAnimationStyle()

Removes the animation style setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetDefaultViewPreference()

Removes the default view preference setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetDisplayPreference()

Removes the display preference setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetEverything()

Removes all data from the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetJavaScript()

Removes the JavaScript setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetPMIColor()

Removes the PMI color setting from the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetPMICrossHighlighting()

Removes the PMI cross-highlighting setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetPMISemanticInformation()

Removes the PMI semantic information setting.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetView(size_t in_index)

Removes the view at the given index from the artwork.

Parameters

in_index – Index of the view to remove from the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetViews()

Removes all views from the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetViews(size_t in_count, size_t const in_indices[])

Removes the views at the given indices from the artwork.

Parameters
  • in_count – Size of the following array.

  • in_indices – Indices of the views to remove from the artwork.

Returns

A reference to this ArtworkKit.

ArtworkKit &UnsetViews(SizeTArray const &in_indices)

Removes the views at the given indices from the artwork.

Parameters

in_indices – Indices of the views to remove from the artwork.

Returns

A reference to this ArtworkKit.

virtual ~ArtworkKit()

Public Static Functions

static ArtworkKit GetDefault()

Creates a ArtworkKit which contains the default settings. The returned object will not necessarily have values for every setting, but it will have them where it is reasonable to have a default. These values will be used for export unless a setting is overridden by the ArtworkKit passed to File::Export.

Returns

A ArtworkKit with the default settings.

Public Static Attributes

static const HPS::Type staticType = HPS::Type::PublishArtworkKit