Classes | Public Types | Public Member Functions | Public Attributes | List of all members
ViewDisplayOverrides Struct Reference

This sub-structure describes the 'overrides' part of a display style. More...

#include <DisplayStyleManager.h>

Classes

struct  OverrideFlags
 

Public Types

enum  { HiddenEdgeWeight_SameAsVisible = 0xffff }
 

Public Member Functions

 ViewDisplayOverrides ()
 
 ~ViewDisplayOverrides ()
 
void SetDisplayStyleHandlerP (struct DisplayStyleHandler const *handler)
 Change the display style handler. More...
 
void SetDisplayStyleHandlerSettingsPtr (RefCountedPtr< struct DisplayStyleHandlerSettings > settings)
 Change the display style handler setting. More...
 
void ResolveDisplayStyleHandler () const
 Reloads the display style handler and settings from the handler id. More...
 
void SetDisplayStyleHandlerById (XAttributeHandlerId id)
 Change the display style handler Id. More...
 
DisplayStyleHandler const * GetDisplayStyleHandlerCP () const
 Get the display style handler pointer. More...
 
XAttributeHandlerId GetDisplayStyleHandlerId () const
 Get the display style handler Id. More...
 
DisplayStyleHandlerSettingsPtr GetDisplayStyleHandlerSettingsPtr () const
 Get the display style handler setting "smart pointer". More...
 
ViewDisplayOverrides Clone (DgnFileR sourceDgnFile, DgnFileR destinationDgnFile) const
 Performs a deep clone. More...
 
bool Equals (ViewDisplayOverridesCR rhs) const
 Performs a deep by-value equality check between this object and another. More...
 
bool Equals (ViewDisplayOverridesCR rhs, DgnFileR sourceDgnFile, DgnFileR rhsDgnFile) const
 Performs a deep by-value equality check between this object and another. More...
 
bool AreFlagsEqual (ViewDisplayOverridesCR rhs) const
 Performs a by-value equality check between this object's flags and another's. More...
 
void ExtractMaterialPaletteAndName (WStringR paletteName, WStringR materialName, DgnFileR dgnFile) const
 Resolves the material palette name and material name for this object's material ID. More...
 
bool HiddenEdgeWeightSameAsVisible () const
 Return true if hidden edge weight should be same as visible. More...
 

Public Attributes

OverrideFlags m_flags
 
UInt32 m_visibleEdgeColor
 Override edge color (not just visible anymore – must defer name change at this time) More...
 
UInt32 m_visibleEdgeWeight
 Override visible edge weight. More...
 
UInt32 m_hiddenEdgeWeight
 override hidden edge weight (0xffff == same as visible). More...
 
double m_transparency
 Override element transparency (0..1 inclusive) More...
 
UInt32 m_elementColor
 Override element color. More...
 
UInt32 m_lineStyle
 Override element line style. More...
 
UInt32 m_lineWeight
 Override element line weight. More...
 
ElementId m_material
 Override element material. More...
 
UInt32 m_backgroundColor
 Override view background color. More...
 
double m_hLineTransparencyThreshold
 

Detailed Description

This sub-structure describes the 'overrides' part of a display style.

The display-relevant data stored in a display style is separated into several groups. The 'overrides' describe the color/style/weight that a display style applies to its underlying rendering parameters ('flags').

This structure is file-dependent, meaning that it stores indices and not fully qualified values. It itself does not store a reference to a file (since DisplayStyle does, and this structure should only exist in the context of a DisplayStyle), and any method that could depend on resolved values accepts file references as parameter(s).

Remarks
Required library : DgnPlatform<ApiNumber>.lib i.e. DgnPlatform5.lib

Member Enumeration Documentation

anonymous enum
Enumerator
HiddenEdgeWeight_SameAsVisible 

Constructor & Destructor Documentation

Member Function Documentation

bool AreFlagsEqual ( ViewDisplayOverridesCR  rhs) const

Performs a by-value equality check between this object's flags and another's.

Parameters
[in]rhsthe object to compare flags with
Returns
true if this object's flags and the rhs parameter's flags are equal by-value; false otherwise
ViewDisplayOverrides Clone ( DgnFileR  sourceDgnFile,
DgnFileR  destinationDgnFile 
) const

Performs a deep clone.

Parameters
[in]sourceDgnFilethe source DGN file (used for color and material index remapping)
[in]destinationDgnFilethe destination DGN file (used for color and material index remapping)
Returns
a deep copy of this object
bool Equals ( ViewDisplayOverridesCR  rhs) const

Performs a deep by-value equality check between this object and another.

Note that this overload is file-invariant, meaning that color and material indices will NOT be remapped to equivalent values if the objects are from different files.

Parameters
[in]rhsthe object to compare with
Returns
true if this object and the rhs parameter are equal by-value; false otherwise
bool Equals ( ViewDisplayOverridesCR  rhs,
DgnFileR  sourceDgnFile,
DgnFileR  rhsDgnFile 
) const

Performs a deep by-value equality check between this object and another.

Note that this overload is file-dependent, meaning that color and material indices WILL be remapped to equivalent values if the objects are from different files.

Parameters
[in]rhsthe object to compare with
[in]sourceDgnFilethe DGN file that this object is associated with
[in]rhsDgnFilethe DGN file that the rhs parameter is associated with
Returns
true if this object and the rhs parameter are equal by-value; false otherwise
void ExtractMaterialPaletteAndName ( WStringR  paletteName,
WStringR  materialName,
DgnFileR  dgnFile 
) const

Resolves the material palette name and material name for this object's material ID.

Note that the lookup is done based on the file given.

Parameters
[out]paletteNamethe resolved material palette name
[out]materialNamethe resolved material name
[in]dgnFilethe context to resolve material indices with
DisplayStyleHandler const* GetDisplayStyleHandlerCP ( ) const

Get the display style handler pointer.

Returns
the object of DisplayStyleHandler
XAttributeHandlerId GetDisplayStyleHandlerId ( ) const

Get the display style handler Id.

Returns
the object of Element::XAttributeHandlerId
DisplayStyleHandlerSettingsPtr GetDisplayStyleHandlerSettingsPtr ( ) const

Get the display style handler setting "smart pointer".

Returns
the object of DisplayStyleHandlerSettingsPtr
bool HiddenEdgeWeightSameAsVisible ( ) const

Return true if hidden edge weight should be same as visible.

+------------—+------------—+------------—+------------—+------------—+---—

void ResolveDisplayStyleHandler ( ) const

Reloads the display style handler and settings from the handler id.

void SetDisplayStyleHandlerById ( XAttributeHandlerId  id)

Change the display style handler Id.

Parameters
idIN the object of Element::XAttributeHandlerId
void SetDisplayStyleHandlerP ( struct DisplayStyleHandler const *  handler)

Change the display style handler.

Parameters
handlerIN the object of DisplayStyleHandler
void SetDisplayStyleHandlerSettingsPtr ( RefCountedPtr< struct DisplayStyleHandlerSettings >  settings)

Change the display style handler setting.

Parameters
settingsIN the object of DisplayStyleHandlerSettings as smart pointer.

Member Data Documentation

UInt32 m_backgroundColor

Override view background color.

UInt32 m_elementColor

Override element color.

OverrideFlags m_flags
UInt32 m_hiddenEdgeWeight

override hidden edge weight (0xffff == same as visible).

double m_hLineTransparencyThreshold
UInt32 m_lineStyle

Override element line style.

UInt32 m_lineWeight

Override element line weight.

ElementId m_material

Override element material.

double m_transparency

Override element transparency (0..1 inclusive)

UInt32 m_visibleEdgeColor

Override edge color (not just visible anymore – must defer name change at this time)

UInt32 m_visibleEdgeWeight

Override visible edge weight.


The documentation for this struct was generated from the following file:

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.