Rhino C++ API  8.12
Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Friends | List of all members
ON_DimStyle Class Reference

#include <opennurbs_dimensionstyle.h>

Inheritance diagram for ON_DimStyle:
ON_ModelComponent ON_Object CRhinoDimStyle

Classes

class  DimstyleField
 

Public Types

enum  : unsigned int { FieldCount = (unsigned int)field::Count }
 
enum  angle_format : unsigned char { angle_format::DecimalDegrees = 0, angle_format::DegMinSec = 1, angle_format::Radians = 2, angle_format::Grads = 3 }
 Display format for angles More...
 
enum  arrow_fit : unsigned char { arrow_fit::Auto = 0, arrow_fit::ArrowsInside = 1, arrow_fit::ArrowsOutside = 2 }
 Arrow display position inside or outside extension lines More...
 
enum  centermark_style : unsigned char { centermark_style::None = 0, centermark_style::Mark = 1, centermark_style::MarkAndLines = 2 }
 Style for drawing centermark for Radial dimensions and Centermark objects More...
 
enum  ContentAngleStyle : unsigned char { ContentAngleStyle::Horizontal = 0, ContentAngleStyle::Aligned = 1, ContentAngleStyle::Rotated = 2 }
 Angle for text or other leader or dimension content More...
 
enum  field : unsigned int {
  field::Unset = 0, field::Name = 1, field::Index = 2, field::ExtensionLineExtension = 3,
  field::ExtensionLineOffset = 4, field::Arrowsize = 5, field::LeaderArrowsize = 6, field::Centermark = 7,
  field::TextGap = 8, field::TextHeight = 9, field::DimTextLocation = 10, field::MaskFrameType = 11,
  field::LengthResolution = 12, field::AngleFormat = 13, field::AngleResolution = 14, field::Font = 15,
  field::LengthFactor = 16, field::Alternate = 17, field::AlternateLengthFactor = 18, field::AlternateLengthResolution = 20,
  field::Prefix = 21, field::Suffix = 22, field::AlternatePrefix = 23, field::AlternateSuffix = 24,
  field::DimensionLineExtension = 25, field::SuppressExtension1 = 26, field::SuppressExtension2 = 27, field::ExtLineColorSource = 28,
  field::DimLineColorSource = 29, field::ArrowColorSource = 30, field::TextColorSource = 31, field::ExtLineColor = 32,
  field::DimLineColor = 33, field::ArrowColor = 34, field::TextColor = 35, field::ExtLinePlotColorSource = 36,
  field::DimLinePlotColorSource = 37, field::ArrowPlotColorSource = 38, field::TextPlotColorSource = 39, field::ExtLinePlotColor = 40,
  field::DimLinePlotColor = 41, field::ArrowPlotColor = 42, field::TextPlotColor = 43, field::ExtLinePlotWeightSource = 44,
  field::DimLinePlotWeightSource = 45, field::ExtLinePlotWeight_mm = 46, field::DimLinePlotWeight_mm = 47, field::ToleranceFormat = 48,
  field::ToleranceResolution = 49, field::ToleranceUpperValue = 50, field::ToleranceLowerValue = 51, field::AltToleranceResolution = 52,
  field::ToleranceHeightScale = 53, field::BaselineSpacing = 54, field::DrawMask = 55, field::MaskColorSource = 56,
  field::MaskColor = 57, field::MaskBorder = 58, field::DimensionScale = 59, field::DimscaleSource = 60,
  field::FixedExtensionLength = 61, field::FixedExtensionOn = 62, field::TextRotation = 63, field::SuppressArrow1 = 64,
  field::SuppressArrow2 = 65, field::TextmoveLeader = 66, field::ArclengthSymbol = 67, field::StackTextheightScale = 68,
  field::StackFormat = 69, field::AltRound = 70, field::Round = 71, field::AngularRound = 72,
  field::AltZeroSuppress = 73, field::AngleZeroSuppress = 75, field::ZeroSuppress = 76, field::AltBelow = 77,
  field::ArrowType1 = 78, field::ArrowType2 = 79, field::LeaderArrowType = 80, field::ArrowBlockId1 = 81,
  field::ArrowBlockId2 = 82, field::LeaderArrowBlock = 83, field::DimRadialTextLocation = 84, field::TextVerticalAlignment = 85,
  field::LeaderTextVerticalAlignment = 86, field::LeaderContentAngleStyle = 87, field::LeaderCurveType = 88, field::LeaderContentAngle = 89,
  field::LeaderHasLanding = 90, field::LeaderLandingLength = 91, field::MaskFlags = 92, field::CentermarkStyle = 93,
  field::TextHorizontalAlignment = 94, field::LeaderTextHorizontalAlignment = 95, field::DrawForward = 96, field::SignedOrdinate = 97,
  field::UnitSystem = 98, field::TextMask = 99, field::TextOrientation = 100, field::LeaderTextOrientation = 101,
  field::DimTextOrientation = 102, field::DimRadialTextOrientation = 103, field::DimTextAngleStyle = 104, field::DimRadialTextAngleStyle = 105,
  field::TextUnderlined = 106, field::DimensionLengthDisplay = 109, field::AlternateDimensionLengthDisplay = 110, field::ForceDimLine = 111,
  field::ArrowFit = 112, field::TextFit = 113, field::DecimalSeparator = 114, field::Count = 115
}
 Field identifiers used for file i/o and getting/setting values More...
 
enum  leader_curve_type : unsigned char { leader_curve_type::None = 0, leader_curve_type::Polyline = 1, leader_curve_type::Spline = 2 }
 Type of leader curve More...
 
enum  LengthDisplay : unsigned int {
  LengthDisplay::ModelUnits = 0, LengthDisplay::Millmeters = 3, LengthDisplay::Centimeters = 4, LengthDisplay::Meters = 5,
  LengthDisplay::Kilometers = 6, LengthDisplay::InchesDecimal = 7, LengthDisplay::InchesFractional = 1, LengthDisplay::FeetDecimal = 8,
  LengthDisplay::FeetAndInches = 2, LengthDisplay::Miles = 9
}
 Interface. More...
 
enum  OBSOLETE_length_format : unsigned char { OBSOLETE_length_format::Decimal = 0, OBSOLETE_length_format::Fractional = 1, OBSOLETE_length_format::FeetInches = 2, OBSOLETE_length_format::FeetDecimalInches = 3 }
 Obsolete format for length display - use ON_DimStyle::DimensionLengthDisplay instead More...
 
enum  stack_format : unsigned char { stack_format::None = 0, stack_format::StackHorizontal = 1, stack_format::StackDiagonal = 2 }
 Format of stacked fractions More...
 
enum  suppress_zero : unsigned char {
  suppress_zero::None = 0, suppress_zero::SuppressLeading = 1, suppress_zero::SuppressTrailing = 2, suppress_zero::SuppressLeadingAndTrailing = 3,
  suppress_zero::SuppressZeroFeet = 4, suppress_zero::SuppressZeroInches = 8, suppress_zero::SuppressZeroFeetAndZeroInches = 12
}
 Marks leading and trailing zeros for removal. More...
 
enum  text_fit : unsigned char {
  text_fit::Auto = 0, text_fit::TextInside = 1, text_fit::TextRight = 2, text_fit::TextLeft = 3,
  text_fit::TextHintRight = 4, text_fit::TextHintLeft = 5
}
 Text display position inside or outside extension lines More...
 
enum  TextLocation : unsigned char { TextLocation::AboveDimLine = 0, TextLocation::InDimLine = 1, TextLocation::BelowDimLine = 2 }
 The location of text in linear, angular, radial, and ordinate dimensions. More...
 
enum  tolerance_format : unsigned char { tolerance_format::None = 0, tolerance_format::Symmetrical = 1, tolerance_format::Deviation = 2, tolerance_format::Limits = 3 }
 Style of tolerance display for dimensions More...
 
- Public Types inherited from ON_ModelComponent
enum  Attributes : unsigned int {
  NoAttributes = 0U, ComponentSerialNumberAttribute = 0x0001U, TypeAttribute = 0x0002U, ModelSerialNumberAttribute = 0x0004U,
  IdAttribute = 0x0008U, IndexAttribute = 0x0010U, NameAttribute = 0x0020U, ParentIdAttribute = 0x0040U,
  DeletedNameAttribute = 0x0080U, ComponentStatusAttribute = 0x0100U, BinaryArchiveAttributes = 0x78U, AllAttributes = 0x1FFU,
  SystemComponentAttribute = 0x8000U
}
 
enum  Type : unsigned char {
  Type::Unset = 0, Type::Image = 1, Type::TextureMapping = 2, Type::Material = 3,
  Type::RenderMaterial = Material, Type::LinePattern = 4, Type::Layer = 5, Type::Group = 6,
  Type::TextStyle = 7, Type::DimStyle = 8, Type::RenderLight = 9, Type::HatchPattern = 10,
  Type::InstanceDefinition = 11, Type::ModelGeometry = 12, Type::HistoryRecord = 13, Type::RenderContent = 14,
  Type::EmbeddedFile = 15, Type::ObsoleteValue = 16, Type::SectionStyle = 17, Type::NumOf,
  Type::Mixed = 0xFE
}
 The ON_ModelComponent::Type enum has a value for each explicit component type and two special values, Unset and Mixed. Use an ON_ModelComponentTypeIterator instance to iterate over the ON_ModelComponent::Type values. /summary> More...
 
- Public Types inherited from ON_Object
enum  UserDataConflictResolution : unsigned char {
  UserDataConflictResolution::destination_object = 0, UserDataConflictResolution::source_object = 1, UserDataConflictResolution::source_copycount_gt = 2, UserDataConflictResolution::source_copycount_ge = 3,
  UserDataConflictResolution::destination_copycount_gt = 4, UserDataConflictResolution::destination_copycount_ge = 5, UserDataConflictResolution::delete_item = 6
}
 

Public Member Functions

 ON_DimStyle ()
 Default constructor result is identical to ON_DimStyle::Unset;. More...
 
 ON_DimStyle (const ON_3dmAnnotationSettings &src)
 
 ON_DimStyle (const ON_DimStyle &src)=default
 
 ON_DimStyle (ON::LengthUnitSystem model_length_unit_system, const class ON_V5x_DimStyle &src)
 Used when reading V5 and earlier archives. More...
 
 ~ON_DimStyle ()=default
 
bool Alternate () const
 Additional measurement display toggle. More...
 
bool AlternateBelow () const
 
ON_DimStyle::LengthDisplay AlternateDimensionLengthDisplay () const
 Set dimension length units and format /summary> More...
 
ON::LengthUnitSystem AlternateDimensionLengthDisplayUnit (unsigned int model_sn) const
 Parameters: model_sn - 0, a model serial number, or ON_UNSET_UINT_INDEX to use the dimstyle's ModelSerialNumber() value. Returns Unit system for dimension length display. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn > 0, then the value of ON::LengthUnitSystemFromModelSerialNumber(model_sn) is returned. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn == 0, then ON::LengthUnitSystem::None is returned. /summary> More...
 
double AlternateLengthFactor () const
 AlternateLengthFactor is a rarely used. See Length factor for a description of this property. /summary> More...
 
int AlternateLengthResolution () const
 Display resolution for alternate length measurements. More...
 
const ON_wStringAlternatePrefix () const
 Dimension alternate prefix text. More...
 
double AlternateRoundOff () const
 
const ON_wStringAlternateSuffix () const
 Dimension alternate suffix text. More...
 
int AlternateToleranceResolution () const
 
ON_DimStyle::suppress_zero AlternateZeroSuppress () const
 
angle_format AngleFormat () const
 
int AngleResolution () const
 Display resolution for angle measurements. More...
 
double AngleRoundOff () const
 
ON_DimStyle::suppress_zero AngleZeroSuppress () const
 
int ArcLengthSymbol () const
 
ON_UUID ArrowBlockId1 () const
 
ON_UUID ArrowBlockId2 () const
 
ON_Color ArrowColor () const
 
ON::object_color_source ArrowColorSource () const
 
ON_DimStyle::arrow_fit ArrowFit () const
 
ON_Color ArrowPlotColor () const
 
ON::plot_color_source ArrowPlotColorSource () const
 
double ArrowSize () const
 Arrow size. More...
 
ON_Arrowhead::arrow_type ArrowType1 () const
 
ON_Arrowhead::arrow_type ArrowType2 () const
 
double BaselineSpacing () const
 
double CenterMark () const
 Centermark size. More...
 
ON_DimStyle::centermark_style CenterMarkStyle () const
 Centermark style. More...
 
void ClearAllFieldOverrides ()
 
bool CompareDimstyle (const ON_DimStyle &src) const
 
bool CompareFields (const ON_DimStyle &src) const
 
const class ON_SHA1_HashContentHash () const
 
const ON_DimStyle CreateOverrideCandidate () const
 
wchar_t DecimalSeparator () const
 
ON_DimStyle::LengthDisplay DimensionLengthDisplay () const
 Dimension length units and format /summary> More...
 
ON::LengthUnitSystem DimensionLengthDisplayUnit (unsigned int model_sn) const
 Parameters: model_sn - 0, a model serial number, or ON_UNSET_UINT_INDEX to use the dimstyle's ModelSerialNumber() value. Returns Unit system for dimension length display. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn > 0, then the value of ON::LengthUnitSystemFromModelSerialNumber(model_sn) is returned. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn == 0, then ON::LengthUnitSystem::None is returned. /summary> More...
 
ON_Color DimensionLineColor () const
 
ON::object_color_source DimensionLineColorSource () const
 
ON_Color DimensionLinePlotColor () const
 
ON::plot_color_source DimensionLinePlotColorSource () const
 
double DimensionLinePlotWeight () const
 
ON::plot_weight_source DimensionLinePlotWeightSource () const
 
double DimExtension () const
 Extension of dimension line past extension lines. More...
 
ON_DimStyle::ContentAngleStyle DimRadialTextAngleStyle () const
 
ON_DimStyle::TextLocation DimRadialTextLocation () const
 The location of text relative to the dimension line in radial dimensions. More...
 
ON::TextOrientation DimRadialTextOrientation () const
 
double DimScale () const
 
int DimScaleSource () const
 0: Global DimScale, 1: DimStyle DimScale More...
 
ON_DimStyle::ContentAngleStyle DimTextAngleStyle () const
 
ON_DimStyle::TextLocation DimTextLocation () const
 The location of text relative to the dimension line in linear, angular, and ordinate dimensions. More...
 
ON::TextOrientation DimTextOrientation () const
 
bool DrawForward () const
 
bool DrawTextMask () const
 Determines whether or not to draw a Text Mask. More...
 
void Dump (ON_TextLog &) const override
 virtual More...
 
void EmergencyDestroy ()
 Interface. More...
 
ON_Color ExtensionLineColor () const
 
ON::object_color_source ExtensionLineColorSource () const
 
ON_Color ExtensionLinePlotColor () const
 
ON::plot_color_source ExtensionLinePlotColorSource () const
 
double ExtensionLinePlotWeight () const
 
ON::plot_weight_source ExtensionLinePlotWeightSource () const
 
double ExtExtension () const
 Extension line extension. More...
 
double ExtOffset () const
 Extension line offset. More...
 
double FixedExtensionLen () const
 
bool FixedExtensionLenOn () const
 
const class ON_FontFont () const
 
const class ON_FontFontCharacteristics () const
 
const bool FontSubstituted () const
 
bool ForceDimLine () const
 
bool HasOverrides () const
 
void InheritFields (const ON_DimStyle &parent)
 
bool IsChildDimstyle () const
 Test if this dimstyle is the child of any other dimstyle. More...
 
bool IsChildOf (const ON_UUID &parent_id) const
 
bool IsFieldOverride (ON_DimStyle::field field_id) const
 
bool IsOverrideDimStyleCandidate (ON_UUID parent_id, bool bRequireSetOverrides, ON_wString *error_description=nullptr) const
 
bool IsValid (class ON_TextLog *text_log=nullptr) const override
 virtual More...
 
ON_UUID LeaderArrowBlockId () const
 
double LeaderArrowSize () const
 Arrow size. More...
 
ON_Arrowhead::arrow_type LeaderArrowType () const
 
double LeaderContentAngleDegrees () const
 
double LeaderContentAngleRadians () const
 
ON_DimStyle::ContentAngleStyle LeaderContentAngleStyle () const
 was contentalignment More...
 
ON_DimStyle::leader_curve_type LeaderCurveType () const
 
bool LeaderHasLanding () const
 
double LeaderLandingLength () const
 
ON::TextHorizontalAlignment LeaderTextHorizontalAlignment () const
 
ON::TextOrientation LeaderTextOrientation () const
 
ON::TextVerticalAlignment LeaderTextVerticalAlignment () const
 was attachstyle More...
 
double LengthFactor () const
 LengthFactor is a rarely used. It applies when a model is being drawn to a scale and the dimension length values should be reverse scaled. For example, if a model is drawn at 1/4 scale, a line 5 units long indicates the real world line is 20 units long. In this case setting LengthFactor to 4 would cause a linear dimension applied to that line to display a value of 20. /summary> More...
 
int LengthResolution () const
 Display resolution for distance measurements. More...
 
double MaskBorder () const
 
ON_Color MaskColor () const
 
ON_TextMask::MaskType MaskFillType () const
 Determines where to get the color to draw a Text Mask. More...
 
ON_TextMask::MaskFrame MaskFrameType () const
 Determines whether to draw a frame around a Text Mask. More...
 
ON_DimStyleoperator= (const ON_DimStyle &)=default
 
ON__UINT32 OverrideCount () const
 
void OverrideFields (const ON_DimStyle &source, const ON_DimStyle &parent)
 
void OverrideFieldsWithDifferentValues (const ON_DimStyle &source, const ON_DimStyle &parent)
 
const ON_SHA1_HashParentContentHash () const
 
const class ON_FontParentDimStyleFont () const
 
const ON_wStringPrefix () const
 Dimension prefix text. More...
 
bool Read (ON_BinaryArchive &) override
 virtual More...
 
double RoundOff () const
 
void Scale (double scale)
 
double ScaleLeftLength_mm () const
 
double ScaleRightLength_mm () const
 
const ON_ScaleValueScaleValue () const
 
void SetAlternate (bool)
 
void SetAlternateBelow (bool below)
 
void SetAlternateDimensionLengthDisplay (ON_DimStyle::LengthDisplay length_display)
 Set alternate dimension length units and format /summary> More...
 
void SetAlternateLengthFactor (double)
 AlternateLengthFactor is a rarely used. See Length factor for a description of this property. /summary> More...
 
void SetAlternateLengthResolution (int)
 
void SetAlternatePrefix (const wchar_t *)
 
void SetAlternateRoundOff (double r)
 
void SetAlternateSuffix (const wchar_t *)
 
void SetAlternateToleranceResolution (int r)
 
void SetAlternateZeroSuppress (ON_DimStyle::suppress_zero s)
 
void SetAngleFormat (angle_format format)
 
void SetAngleResolution (int)
 
void SetAngleRoundOff (double r)
 
void SetAngleZeroSuppress (ON_DimStyle::suppress_zero s)
 
void SetArcLengthSymbol (int m)
 
void SetArrowBlockId1 (ON_UUID id)
 
void SetArrowBlockId2 (ON_UUID id)
 
void SetArrowColor (ON_Color c)
 
void SetArrowColorSource (const ON::object_color_source src)
 
void SetArrowFit (ON_DimStyle::arrow_fit arrowfit)
 
void SetArrowPlotColor (ON_Color c)
 
void SetArrowPlotColorSource (const ON::plot_color_source src)
 
void SetArrowSize (const double)
 
void SetArrowType1 (ON_Arrowhead::arrow_type)
 
void SetArrowType1And2 (ON_Arrowhead::arrow_type)
 
void SetArrowType2 (ON_Arrowhead::arrow_type)
 
void SetBaselineSpacing (double spacing)
 
void SetCenterMark (const double)
 
void SetCenterMarkStyle (ON_DimStyle::centermark_style style)
 
void SetDecimalSeparator (wchar_t separator)
 
void SetDimensionLengthDisplay (ON_DimStyle::LengthDisplay length_display)
 Alternate dimension length units and format /summary> More...
 
void SetDimensionLineColor (ON_Color c)
 
void SetDimensionLineColorSource (const ON::object_color_source src)
 
void SetDimensionLinePlotColor (ON_Color c)
 
void SetDimensionLinePlotColorSource (const ON::plot_color_source src)
 
void SetDimensionLinePlotWeight (double w)
 
void SetDimensionLinePlotWeightSource (const ON::plot_weight_source src)
 
void SetDimExtension (const double e)
 
void SetDimRadialTextAngleStyle (ON_DimStyle::ContentAngleStyle style)
 
void SetDimRadialTextLocation (ON_DimStyle::TextLocation)
 
void SetDimRadialTextOrientation (ON::TextOrientation)
 
void SetDimScale (double left_val, ON::LengthUnitSystem left_us, double right_val, ON::LengthUnitSystem right_us)
 
void SetDimScale (double scale)
 
void SetDimScale (ON_ScaleValue sv)
 
void SetDimScaleSource (int source)
 
void SetDimTextAngleStyle (ON_DimStyle::ContentAngleStyle style)
 
void SetDimTextLocation (ON_DimStyle::TextLocation)
 
void SetDimTextOrientation (ON::TextOrientation)
 
void SetDrawForward (bool drawforward)
 
void SetDrawTextMask (bool bDraw)
 
void SetExtensionLineColor (ON_Color c)
 
void SetExtensionLineColorSource (const ON::object_color_source src)
 
void SetExtensionLinePlotColor (ON_Color c)
 
void SetExtensionLinePlotColorSource (const ON::plot_color_source src)
 
void SetExtensionLinePlotWeight (double w)
 
void SetExtensionLinePlotWeightSource (const ON::plot_weight_source src)
 
void SetExtExtension (const double)
 
void SetExtOffset (const double)
 
void SetFieldOverride (ON_DimStyle::field field_id, bool bOverrideParent)
 
void SetFieldOverrideAll (bool bOverrideParent)
 
void SetFixedExtensionLen (double l)
 
void SetFixedExtensionLenOn (bool on)
 
void SetFont (const class ON_Font &font_characteristics)
 
void SetForceDimLine (bool forcedimline)
 
void SetLeaderArrowBlockId (ON_UUID id)
 
void SetLeaderArrowSize (const double)
 
void SetLeaderArrowType (ON_Arrowhead::arrow_type)
 
void SetLeaderContentAngleDegrees (double angle_degrees)
 
void SetLeaderContentAngleRadians (double angle_radians)
 
void SetLeaderContentAngleStyle (ON_DimStyle::ContentAngleStyle style)
 
void SetLeaderCurveType (ON_DimStyle::leader_curve_type type)
 
void SetLeaderHasLanding (bool landing)
 
void SetLeaderLandingLength (double length)
 
void SetLeaderTextHorizontalAlignment (ON::TextHorizontalAlignment halign)
 
void SetLeaderTextOrientation (ON::TextOrientation)
 
void SetLeaderTextVerticalAlignment (ON::TextVerticalAlignment style)
 
void SetLengthFactor (double)
 LengthFactor is a rarely used. It applies when a model is being drawn to a scale and the dimension length values should be reverse scaled. For example, if a model is drawn at 1/4 scale, a line 5 units long indicates the real world line is 20 units long. In this case setting LengthFactor to 4 would cause a linear dimension applied to that line to display a value of 20. /summary> More...
 
void SetLengthResolution (int)
 
void SetMaskBorder (double offset)
 
void SetMaskColor (ON_Color color)
 Does not return viewport background color. More...
 
void SetMaskFillType (ON_TextMask::MaskType source)
 
void SetMaskFrameType (ON_TextMask::MaskFrame source)
 
void SetPrefix (const wchar_t *)
 
void SetRoundOff (double r)
 
void SetSignedOrdinate (bool allowsigned)
 
void SetSourceDimstyle (ON_UUID source_uuid)
 
void SetStackFractionFormat (ON_DimStyle::stack_format f)
 
void SetStackHeightScale (double f)
 
void SetSuffix (const wchar_t *)
 
void SetSuppressArrow1 (bool s)
 
void SetSuppressArrow2 (bool s)
 
void SetSuppressExtension1 (bool)
 
void SetSuppressExtension2 (bool)
 
void SetTextColor (ON_Color c)
 
void SetTextColorSource (const ON::object_color_source src)
 
void SetTextFit (ON_DimStyle::text_fit textfit)
 
void SetTextGap (double gap)
 
void SetTextHeight (double height)
 
void SetTextHorizontalAlignment (ON::TextHorizontalAlignment halign)
 
void SetTextMask (const ON_TextMask &text_mask)
 
void SetTextMoveLeader (int m)
 
void SetTextOrientation (ON::TextOrientation)
 
void SetTextPlotColor (ON_Color c)
 
void SetTextPlotColorSource (const ON::object_color_source src)
 
void SetTextRotation (double r)
 
void SetTextUnderlined (bool underlined)
 
void SetTextVerticalAlignment (ON::TextVerticalAlignment style)
 
void SetToleranceFormat (ON_DimStyle::tolerance_format format)
 
void SetToleranceHeightScale (double scale)
 
void SetToleranceLowerValue (double lower_value)
 
void SetToleranceResolution (int resolution)
 
void SetToleranceUpperValue (double upper_value)
 
void SetToleranceZeroSuppress (ON_DimStyle::suppress_zero s)
 
void SetUnitSystem (ON::LengthUnitSystem us)
 NOTE WELL: A dimstyle unit system was added in V6, but has never been fully used. The idea was this would make it easier to figure out what text height/ arrow size, ... actually meant. Especially in situations where model space and page space have different unit systems, and in more complex cases like text in instance definitions and inserting annotation from models with mismatched unit systems. It is used internally to get some scales properly set and use in limited merging contexts. More...
 
void SetUnitSystemFromContext (bool bUseName, ON::LengthUnitSystem source_unit_system, ON::LengthUnitSystem destination_unit_system)
 
void SetZeroSuppress (ON_DimStyle::suppress_zero s)
 
bool SignedOrdinate () const
 
ON_UUID SourceDimstyle () const
 
ON_DimStyle::stack_format StackFractionFormat () const
 
double StackHeightScale () const
 
const ON_wStringSuffix () const
 Dimension suffix text. More...
 
bool SuppressArrow1 () const
 
bool SuppressArrow2 () const
 
bool SuppressExtension1 () const
 Suppress first dimension extension line. More...
 
bool SuppressExtension2 () const
 Suppress second dimension extension line. More...
 
double TextAdvanceOfCodePoint (unsigned unicode_code_point) const
 
ON_Color TextColor () const
 
ON::object_color_source TextColorSource () const
 
ON_DimStyle::text_fit TextFit () const
 
double TextGap () const
 Distance from dimension lines to text. More...
 
double TextHeight () const
 Height of dimension text. More...
 
ON::TextHorizontalAlignment TextHorizontalAlignment () const
 
const ON_TextMaskTextMask () const
 
int TextMoveLeader () const
 
ON::TextOrientation TextOrientation () const
 
ON_Color TextPlotColor () const
 
ON::object_color_source TextPlotColorSource () const
 
const class ON_SHA1_Hash TextPositionPropertiesHash () const
 
double TextRotation () const
 
bool TextUnderlined () const
 
ON::TextVerticalAlignment TextVerticalAlignment () const
 
double TextWidthOfEmSpace () const
 
double TextWidthOfEnSpace () const
 
double TextWidthOfFigureSpace () const
 
double TextWidthOfIdeographicSpace () const
 
double TextWidthOfMediumMathematicalSpace () const
 
double TextWidthOfSpace () const
 
tolerance_format ToleranceFormat () const
 
double ToleranceHeightScale () const
 
double ToleranceLowerValue () const
 
int ToleranceResolution () const
 
double ToleranceUpperValue () const
 
ON_DimStyle::suppress_zero ToleranceZeroSuppress () const
 
ON::LengthUnitSystem UnitSystem () const
 NOTE WELL: A dimstyle unit system was added in V6, but has never been fully used. The idea was this would make it easier to figure out what text height/ arrow size, ... actually meant. Especially in situations where model space and page space have different unit systems, and in more complex cases like text in instance definitions and inserting annotation from models with mismatched unit systems. It is used internally to get some scales properly set and use in limited merging contexts. More...
 
bool UnitSystemIsSet () const
 
bool Write (ON_BinaryArchive &) const override
 virtual More...
 
ON_DimStyle::suppress_zero ZeroSuppress () const
 
- Public Member Functions inherited from ON_ModelComponent
 ON_ModelComponent () ON_NOEXCEPT
 
 ON_ModelComponent (const ON_ModelComponent &source)
 
 ON_ModelComponent (ON_ModelComponent::Type component_type) ON_NOEXCEPT
 
 ON_ModelComponent (ON_ModelComponent::Type component_type, const ON_ModelComponent &source) ON_NOEXCEPT
 Locked status of source attributes is not copied to permit copy and modify operations. More...
 
 ~ON_ModelComponent ()=default
 
bool ChangeName (const wchar_t *new_name, class ON_ComponentManifest *manifest)
 
bool ClearComponentType ()
 
bool ClearId ()
 
bool ClearIndex ()
 
unsigned int ClearModelComponentAttributes (unsigned int attributes_filter)
 
bool ClearModelComponentStatus ()
 
bool ClearModelSerialNumber ()
 
bool ClearName ()
 
bool ClearParentId ()
 
int CompareName (const ON_UUID &other_parent_id, const wchar_t *other_name) const
 
int CompareName (const wchar_t *other_name) const
 
int CompareNameExact (const ON_UUID &other_parent_id, const wchar_t *other_name) const
 
int CompareNameExact (const wchar_t *other_name) const
 
ON_ModelComponent::Type ComponentType () const
 
bool ComponentTypeIsLocked () const
 
bool ComponentTypeIsSet () const
 
ON__UINT64 ContentVersionNumber () const
 
unsigned int CopyFrom (const ON_ModelComponent &src, unsigned int attributes_filter)
 
ON__UINT32 DataCRC (ON__UINT32 current_remainder) const override
 
const ON_wString DeletedName () const
 
const ON_NameHashDeletedNameHash () const
 
bool DeletedNameIsSet () const
 
bool DeleteName ()
 
void Dump (ON_TextLog &) const override
 
bool EraseIdentification (bool bIgnoreLocks)
 
const wchar_tGetName (ON_wString &component_name) const
 
const ON_UUIDId () const
 
bool IdIsLocked () const
 
bool IdIsNil () const
 
bool IdIsNotNil () const
 
bool IdIsSet () const
 
const ON_UUIDIfIdIsNilSetId ()
 
int Index () const
 
int Index (int unset_index_value) const
 
bool IndexIsLocked () const
 
bool IndexIsSet () const
 
unsigned int InstanceDefinitionModelSerialNumber () const
 
bool IsDeleted () const
 
bool IsHidden () const
 
bool IsLocked () const
 
bool IsReferenceComponent () const
 
bool IsSystemComponent () const
 
bool IsValid (class ON_TextLog *text_log=nullptr) const override
 
void LockAllSettingsExceptName ()
 
void LockComponentType ()
 
void LockId ()
 
void LockIndex ()
 
void LockModelComponentStatus ()
 
void LockModelSerialNumber ()
 
void LockName ()
 
void LockParentId ()
 
ON_ComponentStatus ModelComponentStatus () const
 
bool ModelComponentStatusIsLocked () const
 
bool ModelComponentStatusIsSet () const
 
ON_UUID ModelObjectId () const override
 
unsigned int ModelSerialNumber () const
 
bool ModelSerialNumberIsLocked () const
 
bool ModelSerialNumberIsSet () const
 
const ON_wString Name () const
 
const wchar_tNameAsPointer () const
 
const ON_NameHashNameHash () const
 
bool NameIsEmpty () const
 
bool NameIsLocked () const
 
bool NameIsNotEmpty () const
 
bool NameIsSet () const
 
const ON_NameHash NewNameHash (const wchar_t *new_name) const
 
ON_ModelComponentoperator= (const ON_ModelComponent &source)
 
const ON_UUIDParentId () const
 
bool ParentIdIsLocked () const
 
bool ParentIdIsNil () const
 
bool ParentIdIsNotNil () const
 
bool ParentIdIsSet () const
 
bool ReadModelComponentAttributes (class ON_BinaryArchive &archive)
 
unsigned int ReferenceModelSerialNumber () const
 
ON__UINT64 RuntimeSerialNumber () const
 
const ON_UUIDSetAndLockId ()
 
bool SetAsSystemComponent ()
 
bool SetAsUnsetSystemComponent ()
 
bool SetComponentType (ON_ModelComponent::Type component_component_type)
 
bool SetDeletedModelComponentState (bool bDeleted, class ON_ComponentManifest *manifest)
 
void SetHiddenModelComponentState (bool bHidden)
 
const ON_UUIDSetId ()
 
bool SetId (const ON_UUID &component_id)
 
bool SetIdentification (const class ON_ComponentManifestItem &manifest_item, const wchar_t *manifest_name, bool bSetId, bool bParentId, bool bSetName, bool bSetIndex)
 
bool SetIndex (int component_index)
 
bool SetLocalizedSystemComponentName (const wchar_t *system_component_localized_name)
 
void SetLockedModelComponentState (bool bLocked)
 
bool SetModelComponentStatus (ON_ComponentStatus component_status)
 
bool SetModelSerialNumber (unsigned int model_serial_number)
 
bool SetModelSerialNumber (unsigned int model_serial_number, unsigned int reference_model_serial_number, unsigned int instance_definition_model_serial_number)
 
bool SetName (const wchar_t *component_name)
 
bool SetParentId (const ON_UUID &parent_id)
 
unsigned int SizeOf () const override
 
bool UndeleteName ()
 
bool WriteModelComponentAttributes (class ON_BinaryArchive &archive, unsigned int attributes_filter) const
 
- Public Member Functions inherited from ON_Object
 ON_Object () ON_NOEXCEPT
 
 ON_Object (const ON_Object &)
 
virtual ~ON_Object ()
 
virtual ON_AggregateComponentStatus AggregateComponentStatus () const
 
bool AttachUserData (class ON_UserData *pUserData)
 
unsigned int ClearAllComponentStates () const
 
virtual unsigned int ClearComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_clear) const
 
virtual unsigned int ClearComponentStates (ON_ComponentStatus states_to_clear) const
 
void CopyUserData (const ON_Object &source_object)
 
unsigned int CopyUserData (const ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution)
 
virtual bool DeleteComponents (const ON_COMPONENT_INDEX *ci_list, size_t ci_count)
 
virtual void DestroyRuntimeCache (bool bDelete=true)
 
bool DetachUserData (class ON_UserData *pUserData)
 
void EmergencyDestroy ()
 
class ON_UserDataFirstUserData () const
 
virtual unsigned int GetComponentsWithSetStates (ON_ComponentStatus states_filter, bool bAllEqualStates, ON_SimpleArray< ON_COMPONENT_INDEX > &components) const
 
class ON_UserDataGetUserData (const ON_UUID &userdata_uuid) const
 
bool GetUserString (const wchar_t *key, ON_wString &string_value) const
 
int GetUserStringKeys (ON_ClassArray< ON_wString > &user_string_keys) const
 
int GetUserStrings (ON_ClassArray< ON_UserString > &user_strings) const
 
bool IsCorrupt (bool bRepair, bool bSilentError, class ON_TextLog *text_log) const
 
bool IsKindOf (const ON_ClassId *pClassId) const
 
virtual void MarkAggregateComponentStatusAsNotCurrent () const
 
virtual void MemoryRelocate ()
 
void MoveUserData (ON_Object &source_object)
 
unsigned int MoveUserData (ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution, bool bDeleteAllSourceItems)
 
virtual ON::object_type ObjectType () const
 
ON_Objectoperator= (const ON_Object &)
 
void PurgeUserData ()
 
virtual unsigned int SetComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_set) const
 
virtual unsigned int SetComponentStatus (ON_COMPONENT_INDEX component_index, ON_ComponentStatus status_to_copy) const
 
bool SetUserString (const wchar_t *key, const wchar_t *string_value)
 
int SetUserStrings (int count, const ON_UserString *user_strings, bool bReplace)
 
bool ThisIsNullptr (bool bSilentError) const
 
void TransformUserData (const class ON_Xform &xform)
 
virtual bool UpdateReferencedComponents (const class ON_ComponentManifest &source_manifest, const class ON_ComponentManifest &destination_manifest, const class ON_ManifestMap &manifest_map)
 
int UserStringCount () const
 

Static Public Member Functions

static ON_DimStyle::angle_format AngleFormatFromUnsigned (unsigned int format_as_unsigned)
 
static ON_DimStyle::arrow_fit ArrowFitFromUnsigned (unsigned int arrow_fit_as_unsigned)
 
static ON_DimStyle::centermark_style CentermarkStyleFromUnsigned (unsigned int centermark_as_unsigned)
 
static ON_DimStyle::ContentAngleStyle ContentAngleStyleFromUnsigned (unsigned int alignment_as_unsigned)
 
static ON_DimStyleCreateFromFont (const ON_Font *font_characteristics, double model_space_text_scale, const ON_DimStyle *dimstyle_settings, const class ON_ComponentManifest *manifest, ON_DimStyle *destination)
 
static const ON_DimStyle CreateFromProperties (const ON_DimStyle &parent_dim_style, ON::AnnotationType annotation_type, const ON_Font *font, double model_space_text_scale, double text_height, ON::LengthUnitSystem text_height_unit_system)
 
static const ON_DimStyle CreateFromProperties (const ON_DimStyle &parent_dim_style, ON::AnnotationType annotation_type, const ON_Font *font, double model_space_text_scale, double text_height, ON::LengthUnitSystem text_height_unit_system, ON::TextVerticalAlignment valign, ON::TextHorizontalAlignment halign)
 
static const ON_DimStyle CreateFromProperties (const ON_DimStyle &parent_dim_style, ON::AnnotationType annotation_type, const ON_Font *font, double model_space_text_scale, double text_height, ON::LengthUnitSystem text_height_unit_system, ON::TextVerticalAlignment valign, ON::TextHorizontalAlignment halign, ON::TextOrientation orientation, ON_DimStyle::TextLocation dim_text_location)
 
static const class ON_DimStyleDimStyleOrDefault (const class ON_DimStyle *dimstyle)
 
static ON::OBSOLETE_DistanceDisplayMode DistanceDisplayModeFromLengthFormat (ON_DimStyle::OBSOLETE_length_format)
 convert ON_DimStyle::OBSOLETE_length_format enum to ON::OBSOLETE_DistanceDisplayMode enum More...
 
static ON_DimStyle::field FieldFromUnsigned (unsigned int field_as_unsigned)
 
static const ON_DimStyleFromModelComponentRef (const class ON_ModelComponentReference &model_component_reference, const ON_DimStyle *none_return_value)
 
static ON_DimStyle::leader_curve_type LeaderCurveTypeFromUnsigned (unsigned int type_as_unsigned)
 
static ON_DimStyle::LengthDisplay LengthDisplayFromUnitsAndFormat (ON::LengthUnitSystem units, ON_DimStyle::OBSOLETE_length_format lengthformat)
 
static ON_DimStyle::LengthDisplay LengthDisplayFromUnsigned (unsigned int length_display_as_unsigned)
 
static bool LengthDisplayIsDecimal (ON_DimStyle::LengthDisplay dimension_length_display)
 
static ON_DimStyle::OBSOLETE_length_format LengthFormatFromDistanceDisplayMode (ON::OBSOLETE_DistanceDisplayMode)
 convert ON::OBSOLETE_DistanceDisplayMode enum to ON_DimStyle::OBSOLETE_length_format enum More...
 
static ON::LengthUnitSystem LengthUnitSystemFromLengthDisplay (ON_DimStyle::LengthDisplay dimension_length_display)
 
static ON_DimStyle::OBSOLETE_length_format OBSOLETE_LengthFormatFromLengthDisplay (ON_DimStyle::LengthDisplay dimension_length_display, ON::LengthUnitSystem model_unit_system)
 
static ON_DimStyle::OBSOLETE_length_format OBSOLETE_LengthFormatFromLengthDisplay (ON_DimStyle::LengthDisplay dimension_length_display, unsigned int model_serial_number)
 
static ON_DimStyle::OBSOLETE_length_format OBSOLETE_LengthFormatFromUnsigned (unsigned int format_as_unsigned)
 
static ON_DimStyle::stack_format StackFormatFromUnsigned (unsigned int format_as_unsigned)
 
static const ON_DimStyleSystemDimstyleFromContentHash (const ON_SHA1_Hash &content_hash)
 
static const ON_DimStyleSystemDimstyleFromId (ON_UUID id)
 
static const ON_DimStyleSystemDimstyleFromIndex (int index)
 
static const ON_DimStyleSystemDimstyleFromName (const ON_NameHash &name_hash)
 
static ON_DimStyle::text_fit TextFitFromUnsigned (unsigned int text_fit_as_unsigned)
 
static ON_DimStyle::TextLocation TextLocationFromUnsigned (unsigned int dim_text_location_as_unsigned)
 
static ON_DimStyle::tolerance_format ToleranceFormatFromUnsigned (unsigned int format_as_unsigned)
 
static int V5AngleFormat (ON_DimStyle::angle_format v6format)
 
static int V5ArrowType (ON_Arrowhead::arrow_type v6type)
 For converting to and from V5 Dimstyles. More...
 
static int V5LengthFormat (ON_DimStyle::OBSOLETE_length_format v6format)
 
static int V5MaskColorSourceFromV6MaskType (ON_TextMask::MaskType mask_type)
 
static int V5ToleranceFormat (ON_DimStyle::tolerance_format v6format)
 
static ON_DimStyle::angle_format V6AngleFormat (int v5format)
 
static ON_Arrowhead::arrow_type V6ArrowType (int v5type)
 
static ON_DimStyle::OBSOLETE_length_format V6LengthFormat (int v5format)
 
static ON_TextMask::MaskType V6MaskTypeFromV5MaskColorSource (int v5_mask_color_source)
 
static ON_DimStyle::tolerance_format V6ToleranceFormat (int v5format)
 
static ON_DimStyle::suppress_zero ZeroSuppressFromUnsigned (unsigned int suppress_ero_as_unsigned)
 
static bool ZeroSuppressMatchesLengthDisplay (ON_DimStyle::suppress_zero zero_suppress, ON_DimStyle::LengthDisplay length_display)
 
- Static Public Member Functions inherited from ON_ModelComponent
static int CompareId (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareIdAndName (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareName (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareNameAndId (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareNameExact (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static ON_ModelComponent::Type ComponentTypeFromUnsigned (unsigned int component_type_as_unsigned)
 
static bool ComponentTypeIsValid (ON_ModelComponent::Type component_type)
 
static bool ComponentTypeIsValidAndNotMixed (ON_ModelComponent::Type component_type)
 
static const ON_wString ComponentTypeToString (ON_ModelComponent::Type)
 
static bool IndexRequired (ON_ModelComponent::Type component_type)
 
static unsigned int Internal_SystemComponentHelper ()
 For internal use. Never call this function. More...
 
static const wchar_tIsNamePathSeparator (const wchar_t *s)
 
*static const wchar_tIsReferencePrefixDelimiter (const wchar_t *s)
 
static const wchar_tIsReferencePrefixSeparator (const wchar_t *s)
 
static bool IsValidComponentName (const class ON_ComponentManifest &model_manfest, const ON_ModelComponent &model_component, bool bPermitReferencePrefix, ON_wString &valid_name)
 
static bool IsValidComponentName (const ON_wString &candidate_component_name)
 
static bool IsValidComponentName (const wchar_t *candidate_component_name)
 
static bool IsValidComponentName (size_t length, const wchar_t *candidate_component_name)
 
static bool IsValidComponentNameFirstCodePoint (int length, const wchar_t *candidate_component_name)
 
static bool IsValidComponentNameFirstCodePoint (ON__UINT32 unicode_code_point)
 
static const ON_wString NameLeaf (const wchar_t *name)
 
static const ON_wString NameParent (const wchar_t *name, bool bIncludeReference)
 
static const ON_wString NameReferencePrefix (const wchar_t *name)
 
static ON__UINT64 NextRuntimeSerialNumber ()
 
static const ON_wString RemoveAllReferencePrefixDelimiters (const wchar_t *name)
 
static const ON_wString RemoveReferencePrefix (const wchar_t *name)
 
static const ON_wString RemoveTrailingNamePathSeparator (const wchar_t *name)
 
static const ON_wString RemoveTrailingReferencePrefixDelimiter (const wchar_t *name)
 
static const ON_wString RemoveTrailingReferencePrefixSeparator (const wchar_t *name)
 
static void SplitName (const wchar_t *name, ON_wString &reference_prefix, ON_wString &name_parent, ON_wString &name_leaf)
 
static bool UniqueNameIgnoresCase (ON_ModelComponent::Type component_type)
 
static bool UniqueNameIncludesParent (ON_ModelComponent::Type component_type)
 
static bool UniqueNameRequired (ON_ModelComponent::Type component_type)
 

Static Public Attributes

static const ON_DimStyle Default
 index = -1, unique and persistent id. More...
 
static const ON_DimStyle DefaultFeetDecimal
 index = -8, unique and persistent id. More...
 
static const ON_DimStyle DefaultFeetEngrave
 index = -9, unique and persistent id. More...
 
static const ON_DimStyle DefaultFootInchArchitecture
 index = -4, unique and persistent id. More...
 
static const ON_DimStyle DefaultInchDecimal
 index = -2, unique and persistent id. More...
 
static const ON_DimStyle DefaultInchFractional
 index = -3, unique and persistent id. More...
 
static const ON_DimStyle DefaultMillimeterArchitecture
 index = -7, unique and persistent id. More...
 
static const ON_DimStyle DefaultMillimeterEngrave
 index = -10, unique and persistent id. More...
 
static const ON_DimStyle DefaultMillimeterLarge
 index = -6, unique and persistent id. More...
 
static const ON_DimStyle DefaultMillimeterSmall
 index = -5, unique and persistent id. More...
 
static const ON_DimStyle DefaultModelUnitsDecimal
 index = -11, unique and persistent id. More...
 
static const ON_DimStyle DefaultModelUnitsEngrave
 index = -12, unique and persistent id. More...
 
static const ON_DimStyle Unset
 Predefined default dimension styles always available. More...
 
- Static Public Attributes inherited from ON_ModelComponent
static const ON_wString NamePathSeparator
 
static const ON_wString ReferencePrefixDelimiter
 
static const ON_wString ReferencePrefixSeparator
 
static const ON_ModelComponent Unset
 
*static const ON_wString WorksessionReferencePrefix *const wchar_t
 

Friends

class ON_V5x_DimStyle
 

Additional Inherited Members

- Protected Member Functions inherited from ON_ModelComponent
void IncrementContentVersionNumber () const
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum : unsigned int
Enumerator
FieldCount 

must be 1 + the maximum value of an ON_DimStyle::field enum value.

◆ angle_format

enum ON_DimStyle::angle_format : unsigned char
strong

Display format for angles

Enumerator
DecimalDegrees 

Decimal Degrees

DegMinSec 

Degrees Minutes Seconds

Radians 

Decimal Radians

Grads 

Decimal Gradians

◆ arrow_fit

enum ON_DimStyle::arrow_fit : unsigned char
strong

Arrow display position inside or outside extension lines

Enumerator
Auto 

Auto - Display when space permits

ArrowsInside 

Force arrows inside extensions

ArrowsOutside 

Force arrows outside extensions

◆ centermark_style

enum ON_DimStyle::centermark_style : unsigned char
strong

Style for drawing centermark for Radial dimensions and Centermark objects

Enumerator
None 

No centermark display

Mark 
  • mark only
MarkAndLines 
  • mark and lines to radius

◆ ContentAngleStyle

enum ON_DimStyle::ContentAngleStyle : unsigned char
strong

Angle for text or other leader or dimension content

Enumerator
Horizontal 

Annotation text is horizontal in annotation object's plane

Aligned 

Aligned with last leader direction or dimension line

Rotated 

Explicit angle

◆ field

enum ON_DimStyle::field : unsigned int
strong

Field identifiers used for file i/o and getting/setting values

Don't change these enum values. They are used in file reading and writing.

Enumerator
Unset 
Name 

Dimension style Name property. Cannot be inherited from parent.

Index 

Dimension style runtime model component index property. Cannot be inherited from parent.

ExtensionLineExtension 
ExtensionLineOffset 
Arrowsize 
LeaderArrowsize 
Centermark 
TextGap 
TextHeight 
DimTextLocation 

Linear, angular, and ordinate dimension text location above/in/below

MaskFrameType 

Text mask frame

OBSOLETE_LengthFormat_ = 11,

LengthResolution 
AngleFormat 
AngleResolution 
Font 
LengthFactor 

LengthFactor is a rarely used. It applies when a model is being drawn to a scale and the dimension length values should be reverse scaled. For example, if a model is drawn at 1/4 scale, a line 5 units long indicates the real world line is 20 units long. In this case setting LengthFactor to 4 would cause a linear dimension applied to that line to display a value of 20. /summary>

Alternate 
AlternateLengthFactor 

AlternateLengthFactor is a rarely used. See Length factor for a description of this property. /summary>

AlternateLengthResolution 

OBSOLETE_AlternateLengthFormat_ = 19,.

Prefix 
Suffix 
AlternatePrefix 
AlternateSuffix 
DimensionLineExtension 
SuppressExtension1 
SuppressExtension2 
ExtLineColorSource 
DimLineColorSource 
ArrowColorSource 
TextColorSource 
ExtLineColor 
DimLineColor 
ArrowColor 
TextColor 
ExtLinePlotColorSource 
DimLinePlotColorSource 
ArrowPlotColorSource 
TextPlotColorSource 
ExtLinePlotColor 
DimLinePlotColor 
ArrowPlotColor 
TextPlotColor 
ExtLinePlotWeightSource 
DimLinePlotWeightSource 
ExtLinePlotWeight_mm 
DimLinePlotWeight_mm 
ToleranceFormat 
ToleranceResolution 
ToleranceUpperValue 
ToleranceLowerValue 
AltToleranceResolution 
ToleranceHeightScale 
BaselineSpacing 
DrawMask 
MaskColorSource 
MaskColor 
MaskBorder 
DimensionScale 
DimscaleSource 
FixedExtensionLength 
FixedExtensionOn 
TextRotation 
SuppressArrow1 
SuppressArrow2 
TextmoveLeader 
ArclengthSymbol 
StackTextheightScale 
StackFormat 
AltRound 
Round 
AngularRound 
AltZeroSuppress 
AngleZeroSuppress 

OBSOLETE ToleranceZeroSuppress = 74,.

ZeroSuppress 
AltBelow 
ArrowType1 
ArrowType2 
LeaderArrowType 
ArrowBlockId1 
ArrowBlockId2 
LeaderArrowBlock 
DimRadialTextLocation 

Radial dimension text location above/in/below

TextVerticalAlignment 
LeaderTextVerticalAlignment 
LeaderContentAngleStyle 
LeaderCurveType 
LeaderContentAngle 
LeaderHasLanding 
LeaderLandingLength 
MaskFlags 
CentermarkStyle 
TextHorizontalAlignment 
LeaderTextHorizontalAlignment 
DrawForward 
SignedOrdinate 
UnitSystem 

Unit system for dimension rendering sizes like TextHeight, TextGap, ArrowSize, ExtOffset, and dozens of other properties that control the appearance and placement of the components used to render a dimension. /summary>

TextMask 
TextOrientation 
LeaderTextOrientation 


DimTextOrientation 
DimRadialTextOrientation 
DimTextAngleStyle 
DimRadialTextAngleStyle 
TextUnderlined 
DimensionLengthDisplay 

Dimension length display. See ON_DimStyle::DimensionLengthDisplay() for a description of this parameter.

OBSOLETE_DimensionUnitSystem_ = 107, OBSOLETE_AlternateDimensionUnitSystem_ = 108,

AlternateDimensionLengthDisplay 

Alternate dimension length display. See ON_DimStyle::AlternateDimensionLengthDisplay() for a description of this parameter.

ForceDimLine 

Force dimension line to draw when text is moved outside

ArrowFit 

Arrow position when arrows won't fit between extensions

TextFit 

Text position when text won't fit between extensions

DecimalSeparator 

Character to use for decimal separator in dimension text

Count 

Every enum UINT value that identifies a valid dimension style property is less than the UINT value of Count.

◆ leader_curve_type

enum ON_DimStyle::leader_curve_type : unsigned char
strong

Type of leader curve

Enumerator
None 
</summary> 
Polyline 
</summary> 
Spline 
</summary> 

◆ LengthDisplay

enum ON_DimStyle::LengthDisplay : unsigned int
strong

Interface.

Dimension display length unit system and style

Enumerator
ModelUnits 

Decimal current model units

Millmeters 

Decimal Millimeters

Centimeters 

Decimal Centimeters

Meters 

Decimal Meters

Kilometers 

Decimal Kilometers

InchesDecimal 

Decimal Inches

InchesFractional 

Fractional Inches ( 1.75 inches displays as 1-3/4 )

FeetDecimal 

Decimal Feet

FeetAndInches 

Feet and Inches ( 14.75 inches displays as 1'-2-3/4" )

Miles 

Decimal Miles

◆ OBSOLETE_length_format

enum ON_DimStyle::OBSOLETE_length_format : unsigned char
strong

Obsolete format for length display - use ON_DimStyle::DimensionLengthDisplay instead

Enumerator
Decimal 

Obsolete - use ON_DimStyle::DimensionLengthDisplay::ModelUnits.

Fractional 

Obsolete - use ON_DimStyle::DimensionLengthDisplay::InchesFractional

FeetInches 

Obsolete - use ON_DimStyle::DimensionLengthDisplay::FeetAndInches

FeetDecimalInches 

Obsolete - use ON_DimStyle::DimensionLengthDisplay::FeetAndInches enum.

◆ stack_format

enum ON_DimStyle::stack_format : unsigned char
strong

Format of stacked fractions

Enumerator
None 

No stacking

StackHorizontal 

Stack with horizontal line

StackDiagonal 

Stack with angled line

◆ suppress_zero

enum ON_DimStyle::suppress_zero : unsigned char
strong

Marks leading and trailing zeros for removal.

Enumerator
None 

No zero suppression.

SuppressLeading 

Suppress leading zeros.

SuppressTrailing 

Suppress trailing zeros.

SuppressLeadingAndTrailing 

Suppress leading and trailing zeros.

SuppressZeroFeet 

Suppress zero feet.

SuppressZeroInches 

Suppress zero inches.

SuppressZeroFeetAndZeroInches 

Suppress zero feet and zero inches.

◆ text_fit

enum ON_DimStyle::text_fit : unsigned char
strong

Text display position inside or outside extension lines

Enumerator
Auto 

Auto - Display inside when space permits

TextInside 

Force text inside extensions

TextRight 

Force text outside to the right of extensions

TextLeft 

Force text outside to the left of extensions

TextHintRight 

Move text outside to the right of extensions when it won't fit inside

TextHintLeft 

Move text outside to the left of extensions when it won't fit inside

◆ TextLocation

enum ON_DimStyle::TextLocation : unsigned char
strong

The location of text in linear, angular, radial, and ordinate dimensions.

Enumerator
AboveDimLine 

Text is above dimension line.

InDimLine 

Text is centered in dimension line.

BelowDimLine 

Text is below dimension line.

◆ tolerance_format

enum ON_DimStyle::tolerance_format : unsigned char
strong

Style of tolerance display for dimensions

Enumerator
None 

No tolerance display

Symmetrical 

Symmetrical +/- tolerance

Deviation 

Distance +tol, -tol

Limits 

Distance upper and lower limits

Constructor & Destructor Documentation

◆ ON_DimStyle() [1/4]

ON_DimStyle::ON_DimStyle ( )

Default constructor result is identical to ON_DimStyle::Unset;.

◆ ~ON_DimStyle()

ON_DimStyle::~ON_DimStyle ( )
default

◆ ON_DimStyle() [2/4]

ON_DimStyle::ON_DimStyle ( const ON_DimStyle src)
default

◆ ON_DimStyle() [3/4]

ON_DimStyle::ON_DimStyle ( ON::LengthUnitSystem  model_length_unit_system,
const class ON_V5x_DimStyle src 
)

Used when reading V5 and earlier archives.

◆ ON_DimStyle() [4/4]

ON_DimStyle::ON_DimStyle ( const ON_3dmAnnotationSettings src)

Member Function Documentation

◆ Alternate()

bool ON_DimStyle::Alternate ( ) const

Additional measurement display toggle.

◆ AlternateBelow()

bool ON_DimStyle::AlternateBelow ( ) const

◆ AlternateDimensionLengthDisplay()

ON_DimStyle::LengthDisplay ON_DimStyle::AlternateDimensionLengthDisplay ( ) const

Set dimension length units and format /summary>

◆ AlternateDimensionLengthDisplayUnit()

ON::LengthUnitSystem ON_DimStyle::AlternateDimensionLengthDisplayUnit ( unsigned int  model_sn) const

Parameters: model_sn - 0, a model serial number, or ON_UNSET_UINT_INDEX to use the dimstyle's ModelSerialNumber() value. Returns Unit system for dimension length display. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn > 0, then the value of ON::LengthUnitSystemFromModelSerialNumber(model_sn) is returned. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn == 0, then ON::LengthUnitSystem::None is returned. /summary>

◆ AlternateLengthFactor()

double ON_DimStyle::AlternateLengthFactor ( ) const

AlternateLengthFactor is a rarely used. See Length factor for a description of this property. /summary>

Distance scale factor for alternate display

◆ AlternateLengthResolution()

int ON_DimStyle::AlternateLengthResolution ( ) const

Display resolution for alternate length measurements.

◆ AlternatePrefix()

const ON_wString& ON_DimStyle::AlternatePrefix ( ) const

Dimension alternate prefix text.

◆ AlternateRoundOff()

double ON_DimStyle::AlternateRoundOff ( ) const

◆ AlternateSuffix()

const ON_wString& ON_DimStyle::AlternateSuffix ( ) const

Dimension alternate suffix text.

◆ AlternateToleranceResolution()

int ON_DimStyle::AlternateToleranceResolution ( ) const

◆ AlternateZeroSuppress()

ON_DimStyle::suppress_zero ON_DimStyle::AlternateZeroSuppress ( ) const

◆ AngleFormat()

angle_format ON_DimStyle::AngleFormat ( ) const

◆ AngleFormatFromUnsigned()

static ON_DimStyle::angle_format ON_DimStyle::AngleFormatFromUnsigned ( unsigned int  format_as_unsigned)
static

◆ AngleResolution()

int ON_DimStyle::AngleResolution ( ) const

Display resolution for angle measurements.

◆ AngleRoundOff()

double ON_DimStyle::AngleRoundOff ( ) const

◆ AngleZeroSuppress()

ON_DimStyle::suppress_zero ON_DimStyle::AngleZeroSuppress ( ) const

◆ ArcLengthSymbol()

int ON_DimStyle::ArcLengthSymbol ( ) const

◆ ArrowBlockId1()

ON_UUID ON_DimStyle::ArrowBlockId1 ( ) const

◆ ArrowBlockId2()

ON_UUID ON_DimStyle::ArrowBlockId2 ( ) const

◆ ArrowColor()

ON_Color ON_DimStyle::ArrowColor ( ) const

◆ ArrowColorSource()

ON::object_color_source ON_DimStyle::ArrowColorSource ( ) const

◆ ArrowFit()

ON_DimStyle::arrow_fit ON_DimStyle::ArrowFit ( ) const

◆ ArrowFitFromUnsigned()

static ON_DimStyle::arrow_fit ON_DimStyle::ArrowFitFromUnsigned ( unsigned int  arrow_fit_as_unsigned)
static

◆ ArrowPlotColor()

ON_Color ON_DimStyle::ArrowPlotColor ( ) const

◆ ArrowPlotColorSource()

ON::plot_color_source ON_DimStyle::ArrowPlotColorSource ( ) const

◆ ArrowSize()

double ON_DimStyle::ArrowSize ( ) const

Arrow size.

◆ ArrowType1()

ON_Arrowhead::arrow_type ON_DimStyle::ArrowType1 ( ) const

◆ ArrowType2()

ON_Arrowhead::arrow_type ON_DimStyle::ArrowType2 ( ) const

◆ BaselineSpacing()

double ON_DimStyle::BaselineSpacing ( ) const

◆ CenterMark()

double ON_DimStyle::CenterMark ( ) const

Centermark size.

◆ CenterMarkStyle()

ON_DimStyle::centermark_style ON_DimStyle::CenterMarkStyle ( ) const

Centermark style.

◆ CentermarkStyleFromUnsigned()

static ON_DimStyle::centermark_style ON_DimStyle::CentermarkStyleFromUnsigned ( unsigned int  centermark_as_unsigned)
static

◆ ClearAllFieldOverrides()

void ON_DimStyle::ClearAllFieldOverrides ( )

Description: All dimension style settings identified the ON_DimStyle::field enum, except Name and Id, are inherited from the parent dimension style.

◆ CompareDimstyle()

bool ON_DimStyle::CompareDimstyle ( const ON_DimStyle src) const

Returns: True: "this" and src have identical names, dimension style appearance attributes, and identical attributes inherited from the same parent dimension style. ON_ModelComponent settings other than Name() and ParentId() are not compared. Remaraks: A better name for this function would be EqualForAllPracticalPurposes().

◆ CompareFields()

bool ON_DimStyle::CompareFields ( const ON_DimStyle src) const

Returns: True if this and src have identical dimension style appearance attributes and the same parent dimension style id. CompareFields() ignores Name, Index, Id() values. CompareFields() ignores differences in IsOverride(field_id) values. Remaraks: A better name for this function would be EqualAppearanceSettings().

◆ ContentAngleStyleFromUnsigned()

static ON_DimStyle::ContentAngleStyle ON_DimStyle::ContentAngleStyleFromUnsigned ( unsigned int  alignment_as_unsigned)
static

◆ ContentHash()

const class ON_SHA1_Hash& ON_DimStyle::ContentHash ( ) const

Description: Two dimension styles have identical content if and only if they have identical values of ContentHash(). Returns: A SHA-1 hash of the information that controls annotation appearance. Remarks: Independent of id, parent id, name, and index.

◆ CreateFromFont()

static ON_DimStyle* ON_DimStyle::CreateFromFont ( const ON_Font font_characteristics,
double  model_space_text_scale,
const ON_DimStyle dimstyle_settings,
const class ON_ComponentManifest manifest,
ON_DimStyle destination 
)
static

Description: Create a clean dimension style that has the specified font. With the exception of the name, the resulting dimension style will have an unset ON_ModelComponent properties (id, index, ...). Parameters: font_characteristics - [in] If nullptr, then &ON_Font::Default is used. model_space_text_scale - [in] If model_space_text_scale is > 0.0, then it is used to set the DimScale() value. dimstyle_settings - [in] Setting for non-font dimstyle properties. If nullptr, then &ON_DimStyle::Default is used. manifest - [in] If manifest is not nullptr, then it is used to generate a unique name. destination - [in] If destination is not nullptr, the result is stored here. Otherwise operator new is used to construct an ON_DimStyle on the heap.

◆ CreateFromProperties() [1/3]

static const ON_DimStyle ON_DimStyle::CreateFromProperties ( const ON_DimStyle parent_dim_style,
ON::AnnotationType  annotation_type,
const ON_Font font,
double  model_space_text_scale,
double  text_height,
ON::LengthUnitSystem  text_height_unit_system 
)
static

◆ CreateFromProperties() [2/3]

static const ON_DimStyle ON_DimStyle::CreateFromProperties ( const ON_DimStyle parent_dim_style,
ON::AnnotationType  annotation_type,
const ON_Font font,
double  model_space_text_scale,
double  text_height,
ON::LengthUnitSystem  text_height_unit_system,
ON::TextVerticalAlignment  valign,
ON::TextHorizontalAlignment  halign 
)
static

Description: Get an ON_DimStyle with the specified properties. Parameters: parent_dim_style - [in] If you are getting ready to modify and existing annotation object, a good options for this parameter is the dimstyle returned by ON_Annotation.DimStyle(); If you are getting ready to create a new annotation object, then get an ON_DimStyleContext class and pass ON_DimStyleContext.CurrentDimStyle(). In Rhino, use CRhinoDoc.DimStyleContext() to get an ON_DimStyleContext. In an ONX_Model, use ONX_Model.DimStyleContext() to get an ON_DimStyleContext. In other situations, you can pass on of the system dimstyles like ON_DimStyle::DefaultMillimeterSmall or ON_DimStyle::DefaultMillimeterArchitectural. The worst possible choices are ON_DimStyle::Default or ON_DimStyle::Unset. annotation_type - [in] ON::AnnotationType::Unset if style will be used for multiple types of annotation or a specific type. For example, if you are making a text object, pass ON::AnnotationType::Text; if you are making a leader, pass ON::AnnotationType::Leader, and so on. font - [in] nullptr for current default or specify the font you want. When in doubt, pass nullptr model_space_text_scale - [in] If > 0, then ON_DimStyle.DimScale() is set, otherwise current default is used. When in doubt, pass ON_UNSET_VALUE. text_height - [in] text_height_unit_system - [in] If text_height > 0, then ON_DimStyle.TextHeight() is set, otherwise current default is used. When in doubt, pass ON_UNSET_VALUE. valign - [in] halign - [in] valign and halign control placement of text in text objects and leaders. The value of the annotation_type parameter determines which objects use the valign and halign settings. text_orientation - [in] dim_text_location - [in] Controls placement of text in linear, angular, radial and ordinate dimensions. When in doubt, pass parent_dim_style.DimTextLocation(). Returns: A dimstyle with the specified text properties. Remarks: This is a useful tool for creating the dimension style parameters to CRhinoDoc.AddTextObject() and CRhinoDoc.AddLeaderObject().

◆ CreateFromProperties() [3/3]

static const ON_DimStyle ON_DimStyle::CreateFromProperties ( const ON_DimStyle parent_dim_style,
ON::AnnotationType  annotation_type,
const ON_Font font,
double  model_space_text_scale,
double  text_height,
ON::LengthUnitSystem  text_height_unit_system,
ON::TextVerticalAlignment  valign,
ON::TextHorizontalAlignment  halign,
ON::TextOrientation  orientation,
ON_DimStyle::TextLocation  dim_text_location 
)
static

◆ CreateOverrideCandidate()

const ON_DimStyle ON_DimStyle::CreateOverrideCandidate ( ) const

Description: Create a dimstyle from this that is configured to be customized for use in creating a new annotation object. Example: ON_DimStyleContext = dim_style_context = ...; ON_DimStyle my_dim_style = dim_style_context.CurrentDimStyle().CreateOverrideCandidate(). / Customize my_dim_style my_dim_style.Set...(...); Returns: An ON_DimStyle configured to be modified and used as an override dimstyle for annotation objects.

◆ DecimalSeparator()

wchar_t ON_DimStyle::DecimalSeparator ( ) const

◆ DimensionLengthDisplay()

ON_DimStyle::LengthDisplay ON_DimStyle::DimensionLengthDisplay ( ) const

Dimension length units and format /summary>

◆ DimensionLengthDisplayUnit()

ON::LengthUnitSystem ON_DimStyle::DimensionLengthDisplayUnit ( unsigned int  model_sn) const

Parameters: model_sn - 0, a model serial number, or ON_UNSET_UINT_INDEX to use the dimstyle's ModelSerialNumber() value. Returns Unit system for dimension length display. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn > 0, then the value of ON::LengthUnitSystemFromModelSerialNumber(model_sn) is returned. If DimensionLengthDisplay() == ON_DimStyle::LengthDisplay::ModelUnits and model_sn == 0, then ON::LengthUnitSystem::None is returned. /summary>

◆ DimensionLineColor()

ON_Color ON_DimStyle::DimensionLineColor ( ) const

◆ DimensionLineColorSource()

ON::object_color_source ON_DimStyle::DimensionLineColorSource ( ) const

◆ DimensionLinePlotColor()

ON_Color ON_DimStyle::DimensionLinePlotColor ( ) const

◆ DimensionLinePlotColorSource()

ON::plot_color_source ON_DimStyle::DimensionLinePlotColorSource ( ) const

◆ DimensionLinePlotWeight()

double ON_DimStyle::DimensionLinePlotWeight ( ) const

◆ DimensionLinePlotWeightSource()

ON::plot_weight_source ON_DimStyle::DimensionLinePlotWeightSource ( ) const

◆ DimExtension()

double ON_DimStyle::DimExtension ( ) const

Extension of dimension line past extension lines.

◆ DimRadialTextAngleStyle()

ON_DimStyle::ContentAngleStyle ON_DimStyle::DimRadialTextAngleStyle ( ) const

◆ DimRadialTextLocation()

ON_DimStyle::TextLocation ON_DimStyle::DimRadialTextLocation ( ) const

The location of text relative to the dimension line in radial dimensions.

◆ DimRadialTextOrientation()

ON::TextOrientation ON_DimStyle::DimRadialTextOrientation ( ) const

◆ DimScale()

double ON_DimStyle::DimScale ( ) const

◆ DimScaleSource()

int ON_DimStyle::DimScaleSource ( ) const

0: Global DimScale, 1: DimStyle DimScale

◆ DimStyleOrDefault()

static const class ON_DimStyle& ON_DimStyle::DimStyleOrDefault ( const class ON_DimStyle dimstyle)
static

Parameters: dimstyle - [in] Returns: If dimstyle not nullptr, then dimstyle is returned. Otherwise a non-null pointer to a persistent dimstyle is returned. A null pointer is never returned. Remarks: This function is used when a dimension style is required.

◆ DimTextAngleStyle()

ON_DimStyle::ContentAngleStyle ON_DimStyle::DimTextAngleStyle ( ) const

◆ DimTextLocation()

ON_DimStyle::TextLocation ON_DimStyle::DimTextLocation ( ) const

The location of text relative to the dimension line in linear, angular, and ordinate dimensions.

◆ DimTextOrientation()

ON::TextOrientation ON_DimStyle::DimTextOrientation ( ) const

◆ DistanceDisplayModeFromLengthFormat()

static ON::OBSOLETE_DistanceDisplayMode ON_DimStyle::DistanceDisplayModeFromLengthFormat ( ON_DimStyle::OBSOLETE_length_format  )
static

◆ DrawForward()

bool ON_DimStyle::DrawForward ( ) const

◆ DrawTextMask()

bool ON_DimStyle::DrawTextMask ( ) const

Determines whether or not to draw a Text Mask.

◆ Dump()

void ON_DimStyle::Dump ( ON_TextLog ) const
overridevirtual

virtual

for debugging

Reimplemented from ON_Object.

◆ EmergencyDestroy()

void ON_DimStyle::EmergencyDestroy ( )

Interface.

◆ ExtensionLineColor()

ON_Color ON_DimStyle::ExtensionLineColor ( ) const

◆ ExtensionLineColorSource()

ON::object_color_source ON_DimStyle::ExtensionLineColorSource ( ) const

◆ ExtensionLinePlotColor()

ON_Color ON_DimStyle::ExtensionLinePlotColor ( ) const

◆ ExtensionLinePlotColorSource()

ON::plot_color_source ON_DimStyle::ExtensionLinePlotColorSource ( ) const

◆ ExtensionLinePlotWeight()

double ON_DimStyle::ExtensionLinePlotWeight ( ) const

◆ ExtensionLinePlotWeightSource()

ON::plot_weight_source ON_DimStyle::ExtensionLinePlotWeightSource ( ) const

◆ ExtExtension()

double ON_DimStyle::ExtExtension ( ) const

Extension line extension.

◆ ExtOffset()

double ON_DimStyle::ExtOffset ( ) const

Extension line offset.

◆ FieldFromUnsigned()

static ON_DimStyle::field ON_DimStyle::FieldFromUnsigned ( unsigned int  field_as_unsigned)
static

◆ FixedExtensionLen()

double ON_DimStyle::FixedExtensionLen ( ) const

◆ FixedExtensionLenOn()

bool ON_DimStyle::FixedExtensionLenOn ( ) const

◆ Font()

const class ON_Font& ON_DimStyle::Font ( ) const

Returns: The managed font used to render text.

◆ FontCharacteristics()

const class ON_Font& ON_DimStyle::FontCharacteristics ( ) const

Returns: A copy of the font_characteristics information. Remarks: You probably want to use Font(). This function is only useful in isolated situations and is typically used to study font substitutions when a model moves between computers or platforms.

◆ FontSubstituted()

const bool ON_DimStyle::FontSubstituted ( ) const

Returns: True if the font returned by Font() is a substitute for the font passed to SetFont(). Remarks: Font substitution can occur when a model is moved between computers that have different fonts installed.

◆ ForceDimLine()

bool ON_DimStyle::ForceDimLine ( ) const

◆ FromModelComponentRef()

static const ON_DimStyle* ON_DimStyle::FromModelComponentRef ( const class ON_ModelComponentReference model_component_reference,
const ON_DimStyle none_return_value 
)
static

Parameters: model_component_reference - [in] none_return_value - [in] value to return if ON_DimStyle::Cast(model_component_ref.ModelComponent()) is nullptr Returns: If ON_DimStyle::Cast(model_component_ref.ModelComponent()) is not nullptr, that pointer is returned. Otherwise, none_return_value is returned.

◆ HasOverrides()

bool ON_DimStyle::HasOverrides ( ) const

Returns: false: (default) Every setting identified by a ON_DimStyle::field enum value, except name and id, is inherited from the parent dimension style identified by ParentId(). true: At least one setting identified by a ON_DimStyle::field enum value is is independent of any parent dimension style.

◆ InheritFields()

void ON_DimStyle::InheritFields ( const ON_DimStyle parent)

Description: Set the parent dimension style id to parent.Id() and copies all inherited appearance properties from parent. Parameters: parent - [in] If this->IsFieldOverride(field_id) is false, then the dimension style property value corresponding to field_id is copied from parent to "this".
Remarks: Identical to calling this->OverrideFields(*this,parent).

◆ IsChildDimstyle()

bool ON_DimStyle::IsChildDimstyle ( ) const

Test if this dimstyle is the child of any other dimstyle.

◆ IsChildOf()

bool ON_DimStyle::IsChildOf ( const ON_UUID parent_id) const

Returns: True if parent_id is not nil and parent_id == this->ParentId().

◆ IsFieldOverride()

bool ON_DimStyle::IsFieldOverride ( ON_DimStyle::field  field_id) const

Parameters: field_id - [in] Returns: false: (default) The setting identified by field_id is inherited from the parent dimension style identified by ParentId(). true: The setting identified by field_id is independent of any parent dimension style.

◆ IsOverrideDimStyleCandidate()

bool ON_DimStyle::IsOverrideDimStyleCandidate ( ON_UUID  parent_id,
bool  bRequireSetOverrides,
ON_wString error_description = nullptr 
) const

◆ IsValid()

bool ON_DimStyle::IsValid ( class ON_TextLog text_log = nullptr) const
overridevirtual

virtual

ON_Object overrides

Reimplemented from ON_Object.

◆ LeaderArrowBlockId()

ON_UUID ON_DimStyle::LeaderArrowBlockId ( ) const

◆ LeaderArrowSize()

double ON_DimStyle::LeaderArrowSize ( ) const

Arrow size.

◆ LeaderArrowType()

ON_Arrowhead::arrow_type ON_DimStyle::LeaderArrowType ( ) const

◆ LeaderContentAngleDegrees()

double ON_DimStyle::LeaderContentAngleDegrees ( ) const

◆ LeaderContentAngleRadians()

double ON_DimStyle::LeaderContentAngleRadians ( ) const

◆ LeaderContentAngleStyle()

ON_DimStyle::ContentAngleStyle ON_DimStyle::LeaderContentAngleStyle ( ) const

was contentalignment

◆ LeaderCurveType()

ON_DimStyle::leader_curve_type ON_DimStyle::LeaderCurveType ( ) const

◆ LeaderCurveTypeFromUnsigned()

static ON_DimStyle::leader_curve_type ON_DimStyle::LeaderCurveTypeFromUnsigned ( unsigned int  type_as_unsigned)
static

◆ LeaderHasLanding()

bool ON_DimStyle::LeaderHasLanding ( ) const

◆ LeaderLandingLength()

double ON_DimStyle::LeaderLandingLength ( ) const

◆ LeaderTextHorizontalAlignment()

ON::TextHorizontalAlignment ON_DimStyle::LeaderTextHorizontalAlignment ( ) const

◆ LeaderTextOrientation()

ON::TextOrientation ON_DimStyle::LeaderTextOrientation ( ) const

◆ LeaderTextVerticalAlignment()

ON::TextVerticalAlignment ON_DimStyle::LeaderTextVerticalAlignment ( ) const

was attachstyle

◆ LengthDisplayFromUnitsAndFormat()

static ON_DimStyle::LengthDisplay ON_DimStyle::LengthDisplayFromUnitsAndFormat ( ON::LengthUnitSystem  units,
ON_DimStyle::OBSOLETE_length_format  lengthformat 
)
static

◆ LengthDisplayFromUnsigned()

static ON_DimStyle::LengthDisplay ON_DimStyle::LengthDisplayFromUnsigned ( unsigned int  length_display_as_unsigned)
static

◆ LengthDisplayIsDecimal()

static bool ON_DimStyle::LengthDisplayIsDecimal ( ON_DimStyle::LengthDisplay  dimension_length_display)
static

Returns: true if length_display selects a decimal format. false if length_display is ON_DimStyle::LengthDisplay::FeetAndInches or ON_DimStyle::LengthDisplay::InchesFractional.

◆ LengthFactor()

double ON_DimStyle::LengthFactor ( ) const

LengthFactor is a rarely used. It applies when a model is being drawn to a scale and the dimension length values should be reverse scaled. For example, if a model is drawn at 1/4 scale, a line 5 units long indicates the real world line is 20 units long. In this case setting LengthFactor to 4 would cause a linear dimension applied to that line to display a value of 20. /summary>

◆ LengthFormatFromDistanceDisplayMode()

static ON_DimStyle::OBSOLETE_length_format ON_DimStyle::LengthFormatFromDistanceDisplayMode ( ON::OBSOLETE_DistanceDisplayMode  )
static

◆ LengthResolution()

int ON_DimStyle::LengthResolution ( ) const

Display resolution for distance measurements.

◆ LengthUnitSystemFromLengthDisplay()

static ON::LengthUnitSystem ON_DimStyle::LengthUnitSystemFromLengthDisplay ( ON_DimStyle::LengthDisplay  dimension_length_display)
static

◆ MaskBorder()

double ON_DimStyle::MaskBorder ( ) const

Offset for the border around text to the rectangle used to draw the mask This number is the offset on each side of the tight rectangle around the text characters to the mask rectangle.

◆ MaskColor()

ON_Color ON_DimStyle::MaskColor ( ) const

Only works right if MaskColorSource returns 1.

◆ MaskFillType()

ON_TextMask::MaskType ON_DimStyle::MaskFillType ( ) const

Determines where to get the color to draw a Text Mask.

◆ MaskFrameType()

ON_TextMask::MaskFrame ON_DimStyle::MaskFrameType ( ) const

Determines whether to draw a frame around a Text Mask.

◆ OBSOLETE_LengthFormatFromLengthDisplay() [1/2]

static ON_DimStyle::OBSOLETE_length_format ON_DimStyle::OBSOLETE_LengthFormatFromLengthDisplay ( ON_DimStyle::LengthDisplay  dimension_length_display,
ON::LengthUnitSystem  model_unit_system 
)
static

◆ OBSOLETE_LengthFormatFromLengthDisplay() [2/2]

static ON_DimStyle::OBSOLETE_length_format ON_DimStyle::OBSOLETE_LengthFormatFromLengthDisplay ( ON_DimStyle::LengthDisplay  dimension_length_display,
unsigned int  model_serial_number 
)
static

Parameters: dimension_length_display - [in] model_serial_number - [in] 0: Ignore model settings >0: dimstyle.ModelSerialNumber()

◆ OBSOLETE_LengthFormatFromUnsigned()

static ON_DimStyle::OBSOLETE_length_format ON_DimStyle::OBSOLETE_LengthFormatFromUnsigned ( unsigned int  format_as_unsigned)
static

◆ operator=()

ON_DimStyle& ON_DimStyle::operator= ( const ON_DimStyle )
default

◆ OverrideCount()

ON__UINT32 ON_DimStyle::OverrideCount ( ) const

Returns: The number of DimStyle fields that are overridden. Name, Id and Index are not counted.

◆ OverrideFields()

void ON_DimStyle::OverrideFields ( const ON_DimStyle source,
const ON_DimStyle parent 
)

Description: For every dimension style property identified by a field_id ON_DimStyle::field enum, except Name and Index, do the following:

if ( source.IsFieldOverride(field_id) ) copy corresponding value from source to this else copy corresponding value from parent to this

Set this->ParentId() = parent.Id(). Parameters: src - [in] It is permitted for src to be this. parent - [in] It is permitted for parent to be this.

◆ OverrideFieldsWithDifferentValues()

void ON_DimStyle::OverrideFieldsWithDifferentValues ( const ON_DimStyle source,
const ON_DimStyle parent 
)

Description: For every dimension style property identified by a field_id ON_DimStyle::field enum, except Name and Index, if source and parent have different values, then set the field override for that property to true. Parameters: src - [in] It is permitted for src to be this. parent - [in] It is permitted for parent to be this.

◆ ParentContentHash()

const ON_SHA1_Hash& ON_DimStyle::ParentContentHash ( ) const

Returns: The content hash of the parent dimstyle. If there is no parent dimstyle, then ON_SHA1_Hash::EmptyContent is returned.

◆ ParentDimStyleFont()

const class ON_Font& ON_DimStyle::ParentDimStyleFont ( ) const

Returns: If a parent dimstyle is in play, this is the managed font used by the parent dimstyle. Otherwise, this is the font returned by Font().

◆ Prefix()

const ON_wString& ON_DimStyle::Prefix ( ) const

Dimension prefix text.

◆ Read()

bool ON_DimStyle::Read ( ON_BinaryArchive )
overridevirtual

virtual

Reimplemented from ON_Object.

◆ RoundOff()

double ON_DimStyle::RoundOff ( ) const

◆ Scale()

void ON_DimStyle::Scale ( double  scale)

◆ ScaleLeftLength_mm()

double ON_DimStyle::ScaleLeftLength_mm ( ) const

◆ ScaleRightLength_mm()

double ON_DimStyle::ScaleRightLength_mm ( ) const

◆ ScaleValue()

const ON_ScaleValue& ON_DimStyle::ScaleValue ( ) const

◆ SetAlternate()

void ON_DimStyle::SetAlternate ( bool  )

◆ SetAlternateBelow()

void ON_DimStyle::SetAlternateBelow ( bool  below)

◆ SetAlternateDimensionLengthDisplay()

void ON_DimStyle::SetAlternateDimensionLengthDisplay ( ON_DimStyle::LengthDisplay  length_display)

Set alternate dimension length units and format /summary>

◆ SetAlternateLengthFactor()

void ON_DimStyle::SetAlternateLengthFactor ( double  )

AlternateLengthFactor is a rarely used. See Length factor for a description of this property. /summary>

◆ SetAlternateLengthResolution()

void ON_DimStyle::SetAlternateLengthResolution ( int  )

◆ SetAlternatePrefix()

void ON_DimStyle::SetAlternatePrefix ( const wchar_t )

◆ SetAlternateRoundOff()

void ON_DimStyle::SetAlternateRoundOff ( double  r)

◆ SetAlternateSuffix()

void ON_DimStyle::SetAlternateSuffix ( const wchar_t )

◆ SetAlternateToleranceResolution()

void ON_DimStyle::SetAlternateToleranceResolution ( int  r)

◆ SetAlternateZeroSuppress()

void ON_DimStyle::SetAlternateZeroSuppress ( ON_DimStyle::suppress_zero  s)

◆ SetAngleFormat()

void ON_DimStyle::SetAngleFormat ( angle_format  format)

◆ SetAngleResolution()

void ON_DimStyle::SetAngleResolution ( int  )

◆ SetAngleRoundOff()

void ON_DimStyle::SetAngleRoundOff ( double  r)

◆ SetAngleZeroSuppress()

void ON_DimStyle::SetAngleZeroSuppress ( ON_DimStyle::suppress_zero  s)

◆ SetArcLengthSymbol()

void ON_DimStyle::SetArcLengthSymbol ( int  m)

◆ SetArrowBlockId1()

void ON_DimStyle::SetArrowBlockId1 ( ON_UUID  id)

◆ SetArrowBlockId2()

void ON_DimStyle::SetArrowBlockId2 ( ON_UUID  id)

◆ SetArrowColor()

void ON_DimStyle::SetArrowColor ( ON_Color  c)

◆ SetArrowColorSource()

void ON_DimStyle::SetArrowColorSource ( const ON::object_color_source  src)

◆ SetArrowFit()

void ON_DimStyle::SetArrowFit ( ON_DimStyle::arrow_fit  arrowfit)

◆ SetArrowPlotColor()

void ON_DimStyle::SetArrowPlotColor ( ON_Color  c)

◆ SetArrowPlotColorSource()

void ON_DimStyle::SetArrowPlotColorSource ( const ON::plot_color_source  src)

◆ SetArrowSize()

void ON_DimStyle::SetArrowSize ( const double  )

◆ SetArrowType1()

void ON_DimStyle::SetArrowType1 ( ON_Arrowhead::arrow_type  )

◆ SetArrowType1And2()

void ON_DimStyle::SetArrowType1And2 ( ON_Arrowhead::arrow_type  )

◆ SetArrowType2()

void ON_DimStyle::SetArrowType2 ( ON_Arrowhead::arrow_type  )

◆ SetBaselineSpacing()

void ON_DimStyle::SetBaselineSpacing ( double  spacing)

◆ SetCenterMark()

void ON_DimStyle::SetCenterMark ( const double  )

◆ SetCenterMarkStyle()

void ON_DimStyle::SetCenterMarkStyle ( ON_DimStyle::centermark_style  style)

◆ SetDecimalSeparator()

void ON_DimStyle::SetDecimalSeparator ( wchar_t  separator)

◆ SetDimensionLengthDisplay()

void ON_DimStyle::SetDimensionLengthDisplay ( ON_DimStyle::LengthDisplay  length_display)

Alternate dimension length units and format /summary>

◆ SetDimensionLineColor()

void ON_DimStyle::SetDimensionLineColor ( ON_Color  c)

◆ SetDimensionLineColorSource()

void ON_DimStyle::SetDimensionLineColorSource ( const ON::object_color_source  src)

◆ SetDimensionLinePlotColor()

void ON_DimStyle::SetDimensionLinePlotColor ( ON_Color  c)

◆ SetDimensionLinePlotColorSource()

void ON_DimStyle::SetDimensionLinePlotColorSource ( const ON::plot_color_source  src)

◆ SetDimensionLinePlotWeight()

void ON_DimStyle::SetDimensionLinePlotWeight ( double  w)

◆ SetDimensionLinePlotWeightSource()

void ON_DimStyle::SetDimensionLinePlotWeightSource ( const ON::plot_weight_source  src)

◆ SetDimExtension()

void ON_DimStyle::SetDimExtension ( const double  e)

◆ SetDimRadialTextAngleStyle()

void ON_DimStyle::SetDimRadialTextAngleStyle ( ON_DimStyle::ContentAngleStyle  style)

◆ SetDimRadialTextLocation()

void ON_DimStyle::SetDimRadialTextLocation ( ON_DimStyle::TextLocation  )

◆ SetDimRadialTextOrientation()

void ON_DimStyle::SetDimRadialTextOrientation ( ON::TextOrientation  )

◆ SetDimScale() [1/3]

void ON_DimStyle::SetDimScale ( double  left_val,
ON::LengthUnitSystem  left_us,
double  right_val,
ON::LengthUnitSystem  right_us 
)

◆ SetDimScale() [2/3]

void ON_DimStyle::SetDimScale ( double  scale)

◆ SetDimScale() [3/3]

void ON_DimStyle::SetDimScale ( ON_ScaleValue  sv)

◆ SetDimScaleSource()

void ON_DimStyle::SetDimScaleSource ( int  source)

◆ SetDimTextAngleStyle()

void ON_DimStyle::SetDimTextAngleStyle ( ON_DimStyle::ContentAngleStyle  style)

◆ SetDimTextLocation()

void ON_DimStyle::SetDimTextLocation ( ON_DimStyle::TextLocation  )

◆ SetDimTextOrientation()

void ON_DimStyle::SetDimTextOrientation ( ON::TextOrientation  )

◆ SetDrawForward()

void ON_DimStyle::SetDrawForward ( bool  drawforward)

◆ SetDrawTextMask()

void ON_DimStyle::SetDrawTextMask ( bool  bDraw)

◆ SetExtensionLineColor()

void ON_DimStyle::SetExtensionLineColor ( ON_Color  c)

◆ SetExtensionLineColorSource()

void ON_DimStyle::SetExtensionLineColorSource ( const ON::object_color_source  src)

◆ SetExtensionLinePlotColor()

void ON_DimStyle::SetExtensionLinePlotColor ( ON_Color  c)

◆ SetExtensionLinePlotColorSource()

void ON_DimStyle::SetExtensionLinePlotColorSource ( const ON::plot_color_source  src)

◆ SetExtensionLinePlotWeight()

void ON_DimStyle::SetExtensionLinePlotWeight ( double  w)

◆ SetExtensionLinePlotWeightSource()

void ON_DimStyle::SetExtensionLinePlotWeightSource ( const ON::plot_weight_source  src)

◆ SetExtExtension()

void ON_DimStyle::SetExtExtension ( const double  )

◆ SetExtOffset()

void ON_DimStyle::SetExtOffset ( const double  )

◆ SetFieldOverride()

void ON_DimStyle::SetFieldOverride ( ON_DimStyle::field  field_id,
bool  bOverrideParent 
)

Parameters: field_id - [in] bOverrideParent - [in] false: The setting identified by field_id is inherited from the parent dimension style identified by ParentId(). true: The setting identified by field_id is independent of any parent dimension style.

◆ SetFieldOverrideAll()

void ON_DimStyle::SetFieldOverrideAll ( bool  bOverrideParent)

Parameters: bOverrideParent - [in] true - if a field permits overriding, set it to true. false - set all field override values to false.

◆ SetFixedExtensionLen()

void ON_DimStyle::SetFixedExtensionLen ( double  l)

◆ SetFixedExtensionLenOn()

void ON_DimStyle::SetFixedExtensionLenOn ( bool  on)

◆ SetFont()

void ON_DimStyle::SetFont ( const class ON_Font font_characteristics)

Description: Set the font used to render text. Parameters: font_characteristics - [in] This parameter does not have to be a managed font. Remarks: If the parameter is a managed font (font_characteristics.IsManagedFont() is true), then the identical value is returned by ON_DimStyle.Font(). If the parameter is not a managed font (font_characteristics.IsManagedFont() is false), then the ON_Font::GetManagedFont(font_characteristics) will be returned by ON_DimStyle.Font().

◆ SetForceDimLine()

void ON_DimStyle::SetForceDimLine ( bool  forcedimline)

◆ SetLeaderArrowBlockId()

void ON_DimStyle::SetLeaderArrowBlockId ( ON_UUID  id)

◆ SetLeaderArrowSize()

void ON_DimStyle::SetLeaderArrowSize ( const double  )

◆ SetLeaderArrowType()

void ON_DimStyle::SetLeaderArrowType ( ON_Arrowhead::arrow_type  )

◆ SetLeaderContentAngleDegrees()

void ON_DimStyle::SetLeaderContentAngleDegrees ( double  angle_degrees)

◆ SetLeaderContentAngleRadians()

void ON_DimStyle::SetLeaderContentAngleRadians ( double  angle_radians)

◆ SetLeaderContentAngleStyle()

void ON_DimStyle::SetLeaderContentAngleStyle ( ON_DimStyle::ContentAngleStyle  style)

◆ SetLeaderCurveType()

void ON_DimStyle::SetLeaderCurveType ( ON_DimStyle::leader_curve_type  type)

◆ SetLeaderHasLanding()

void ON_DimStyle::SetLeaderHasLanding ( bool  landing)

◆ SetLeaderLandingLength()

void ON_DimStyle::SetLeaderLandingLength ( double  length)

◆ SetLeaderTextHorizontalAlignment()

void ON_DimStyle::SetLeaderTextHorizontalAlignment ( ON::TextHorizontalAlignment  halign)

◆ SetLeaderTextOrientation()

void ON_DimStyle::SetLeaderTextOrientation ( ON::TextOrientation  )

◆ SetLeaderTextVerticalAlignment()

void ON_DimStyle::SetLeaderTextVerticalAlignment ( ON::TextVerticalAlignment  style)

◆ SetLengthFactor()

void ON_DimStyle::SetLengthFactor ( double  )

LengthFactor is a rarely used. It applies when a model is being drawn to a scale and the dimension length values should be reverse scaled. For example, if a model is drawn at 1/4 scale, a line 5 units long indicates the real world line is 20 units long. In this case setting LengthFactor to 4 would cause a linear dimension applied to that line to display a value of 20. /summary>

◆ SetLengthResolution()

void ON_DimStyle::SetLengthResolution ( int  )

◆ SetMaskBorder()

void ON_DimStyle::SetMaskBorder ( double  offset)

◆ SetMaskColor()

void ON_DimStyle::SetMaskColor ( ON_Color  color)

Does not return viewport background color.

◆ SetMaskFillType()

void ON_DimStyle::SetMaskFillType ( ON_TextMask::MaskType  source)

◆ SetMaskFrameType()

void ON_DimStyle::SetMaskFrameType ( ON_TextMask::MaskFrame  source)

◆ SetPrefix()

void ON_DimStyle::SetPrefix ( const wchar_t )

◆ SetRoundOff()

void ON_DimStyle::SetRoundOff ( double  r)

◆ SetSignedOrdinate()

void ON_DimStyle::SetSignedOrdinate ( bool  allowsigned)

◆ SetSourceDimstyle()

void ON_DimStyle::SetSourceDimstyle ( ON_UUID  source_uuid)

UUID of the dimstyle this was originally copied from so Restore Defaults has some place to look

◆ SetStackFractionFormat()

void ON_DimStyle::SetStackFractionFormat ( ON_DimStyle::stack_format  f)

◆ SetStackHeightScale()

void ON_DimStyle::SetStackHeightScale ( double  f)

◆ SetSuffix()

void ON_DimStyle::SetSuffix ( const wchar_t )

◆ SetSuppressArrow1()

void ON_DimStyle::SetSuppressArrow1 ( bool  s)

◆ SetSuppressArrow2()

void ON_DimStyle::SetSuppressArrow2 ( bool  s)

◆ SetSuppressExtension1()

void ON_DimStyle::SetSuppressExtension1 ( bool  )

◆ SetSuppressExtension2()

void ON_DimStyle::SetSuppressExtension2 ( bool  )

◆ SetTextColor()

void ON_DimStyle::SetTextColor ( ON_Color  c)

◆ SetTextColorSource()

void ON_DimStyle::SetTextColorSource ( const ON::object_color_source  src)

◆ SetTextFit()

void ON_DimStyle::SetTextFit ( ON_DimStyle::text_fit  textfit)

◆ SetTextGap()

void ON_DimStyle::SetTextGap ( double  gap)

◆ SetTextHeight()

void ON_DimStyle::SetTextHeight ( double  height)

◆ SetTextHorizontalAlignment()

void ON_DimStyle::SetTextHorizontalAlignment ( ON::TextHorizontalAlignment  halign)

◆ SetTextMask()

void ON_DimStyle::SetTextMask ( const ON_TextMask text_mask)

◆ SetTextMoveLeader()

void ON_DimStyle::SetTextMoveLeader ( int  m)

◆ SetTextOrientation()

void ON_DimStyle::SetTextOrientation ( ON::TextOrientation  )

◆ SetTextPlotColor()

void ON_DimStyle::SetTextPlotColor ( ON_Color  c)

◆ SetTextPlotColorSource()

void ON_DimStyle::SetTextPlotColorSource ( const ON::object_color_source  src)

◆ SetTextRotation()

void ON_DimStyle::SetTextRotation ( double  r)

◆ SetTextUnderlined()

void ON_DimStyle::SetTextUnderlined ( bool  underlined)

◆ SetTextVerticalAlignment()

void ON_DimStyle::SetTextVerticalAlignment ( ON::TextVerticalAlignment  style)

◆ SetToleranceFormat()

void ON_DimStyle::SetToleranceFormat ( ON_DimStyle::tolerance_format  format)

◆ SetToleranceHeightScale()

void ON_DimStyle::SetToleranceHeightScale ( double  scale)

◆ SetToleranceLowerValue()

void ON_DimStyle::SetToleranceLowerValue ( double  lower_value)

◆ SetToleranceResolution()

void ON_DimStyle::SetToleranceResolution ( int  resolution)

◆ SetToleranceUpperValue()

void ON_DimStyle::SetToleranceUpperValue ( double  upper_value)

◆ SetToleranceZeroSuppress()

void ON_DimStyle::SetToleranceZeroSuppress ( ON_DimStyle::suppress_zero  s)

OBSOLETE - The ZeroSuppress() or AlternateZeroSuppress() property is used to format tolerance display. ToleranceZeroSuppress() is ignored.

◆ SetUnitSystem()

void ON_DimStyle::SetUnitSystem ( ON::LengthUnitSystem  us)

NOTE WELL: A dimstyle unit system was added in V6, but has never been fully used. The idea was this would make it easier to figure out what text height/ arrow size, ... actually meant. Especially in situations where model space and page space have different unit systems, and in more complex cases like text in instance definitions and inserting annotation from models with mismatched unit systems. It is used internally to get some scales properly set and use in limited merging contexts.

From a user's perspective, in Rhino 6 and Rhino 7 ON_DimStyle lengths like TextHeight(), ArrowSize(), ... are with respect to the context the annotation resides in. For example, if TextHeight() = 3.5, model units = meters, page units = millimters, and DimScale() = 1, then text created in model space will be 3.5 meters high and text created in page space will be 3.5 millimeters high.

Ideally, ON_DimStyle::UnitSystem() would specify the text height units and ON_DimStyle::DimScale() cound be adjusted as model space extents require. Text in instance definitions would have a well defined height and references to those instance definitions would display predictably in both model space and page space. /summary>

◆ SetUnitSystemFromContext()

void ON_DimStyle::SetUnitSystemFromContext ( bool  bUseName,
ON::LengthUnitSystem  source_unit_system,
ON::LengthUnitSystem  destination_unit_system 
)

Description: When a dimension style unit system is not set, this function examines the context the dimension style is being used in and sets the unit system. Ideally, both source_unit_system and destination_unit_system are page space units. Less ideally, both source_unit_system and destination_unit_system are model space units. Parameters: bUseName - [in] Consider the name when assigning a unit system. For example, a dimension style name "Millimters Small" would be assigned a unit system of millimeters. source_unit_system - [in] unit system in the context where the dimension style originated. destination_unit_system - [in] unit system in the context where the dimension style will be used.

◆ SetZeroSuppress()

void ON_DimStyle::SetZeroSuppress ( ON_DimStyle::suppress_zero  s)

◆ SignedOrdinate()

bool ON_DimStyle::SignedOrdinate ( ) const

◆ SourceDimstyle()

ON_UUID ON_DimStyle::SourceDimstyle ( ) const

◆ StackFormatFromUnsigned()

static ON_DimStyle::stack_format ON_DimStyle::StackFormatFromUnsigned ( unsigned int  format_as_unsigned)
static

◆ StackFractionFormat()

ON_DimStyle::stack_format ON_DimStyle::StackFractionFormat ( ) const

◆ StackHeightScale()

double ON_DimStyle::StackHeightScale ( ) const

◆ Suffix()

const ON_wString& ON_DimStyle::Suffix ( ) const

Dimension suffix text.

◆ SuppressArrow1()

bool ON_DimStyle::SuppressArrow1 ( ) const

◆ SuppressArrow2()

bool ON_DimStyle::SuppressArrow2 ( ) const

◆ SuppressExtension1()

bool ON_DimStyle::SuppressExtension1 ( ) const

Suppress first dimension extension line.

◆ SuppressExtension2()

bool ON_DimStyle::SuppressExtension2 ( ) const

Suppress second dimension extension line.

◆ SystemDimstyleFromContentHash()

static const ON_DimStyle& ON_DimStyle::SystemDimstyleFromContentHash ( const ON_SHA1_Hash content_hash)
static

Parameters: name_hash - [in] Returns: If the id is not nil and identifies one of the above system dimstyles, that dimstyle is returned. Otherwise, ON_DimStyle::Unset is returned.

◆ SystemDimstyleFromId()

static const ON_DimStyle& ON_DimStyle::SystemDimstyleFromId ( ON_UUID  id)
static

Parameters: id - [in] Returns: If the id is not nil and identifies one of the above system dimstyles, that dimstyle is returned. Otherwise, ON_DimStyle::Unset is returned.

◆ SystemDimstyleFromIndex()

static const ON_DimStyle& ON_DimStyle::SystemDimstyleFromIndex ( int  index)
static

Parameters: index - [in] Returns: If the id is not nil and identifies one of the above system dimstyles, that dimstyle is returned. Otherwise, ON_DimStyle::Unset is returned.

◆ SystemDimstyleFromName()

static const ON_DimStyle& ON_DimStyle::SystemDimstyleFromName ( const ON_NameHash name_hash)
static

Parameters: name_hash - [in] Returns: If the id is not nil and identifies one of the above system dimstyles, that dimstyle is returned. Otherwise, ON_DimStyle::Unset is returned.

◆ TextAdvanceOfCodePoint()

double ON_DimStyle::TextAdvanceOfCodePoint ( unsigned  unicode_code_point) const

Parameters: unicode_code_point - [in] Returns: The advance for a single code point glyph in the same units as TextHeight() using the current settings for TextHeight() and Font(). Remarks: When sequences of code points are rendered, using the per glyph advance does not create the best looking text. Text rendering tools like DirectWrite that look at the entire string adjust advance based on the locale, neighboring glyphs, and other contextual information.

◆ TextColor()

ON_Color ON_DimStyle::TextColor ( ) const

◆ TextColorSource()

ON::object_color_source ON_DimStyle::TextColorSource ( ) const

◆ TextFit()

ON_DimStyle::text_fit ON_DimStyle::TextFit ( ) const

◆ TextFitFromUnsigned()

static ON_DimStyle::text_fit ON_DimStyle::TextFitFromUnsigned ( unsigned int  text_fit_as_unsigned)
static

◆ TextGap()

double ON_DimStyle::TextGap ( ) const

Distance from dimension lines to text.

◆ TextHeight()

double ON_DimStyle::TextHeight ( ) const

Height of dimension text.

◆ TextHorizontalAlignment()

ON::TextHorizontalAlignment ON_DimStyle::TextHorizontalAlignment ( ) const

◆ TextLocationFromUnsigned()

static ON_DimStyle::TextLocation ON_DimStyle::TextLocationFromUnsigned ( unsigned int  dim_text_location_as_unsigned)
static

◆ TextMask()

const ON_TextMask& ON_DimStyle::TextMask ( ) const

The ON_TextMask class contains the property values for DrawTextMask() MaskColor() MaskFillType() MaskBorder() Use the SetDrawTextMask() SetMaskColor() SetMaskFillType() SetMaskBorder() functions to modify text mask properties.

◆ TextMoveLeader()

int ON_DimStyle::TextMoveLeader ( ) const

◆ TextOrientation()

ON::TextOrientation ON_DimStyle::TextOrientation ( ) const

◆ TextPlotColor()

ON_Color ON_DimStyle::TextPlotColor ( ) const

◆ TextPlotColorSource()

ON::object_color_source ON_DimStyle::TextPlotColorSource ( ) const

◆ TextPositionPropertiesHash()

const class ON_SHA1_Hash ON_DimStyle::TextPositionPropertiesHash ( ) const

Description: Two dimension styles have identical text orientation, glyph content, and size parameters if and only if the have identical values of TextPositionPropertiesHash(). Returns: A SHA-1 hash of the information that controls text position and size. Remarks: Independent of id, parent id, name, and index.

◆ TextRotation()

double ON_DimStyle::TextRotation ( ) const

◆ TextUnderlined()

bool ON_DimStyle::TextUnderlined ( ) const

◆ TextVerticalAlignment()

ON::TextVerticalAlignment ON_DimStyle::TextVerticalAlignment ( ) const

◆ TextWidthOfEmSpace()

double ON_DimStyle::TextWidthOfEmSpace ( ) const

Returns: Width of an em space (U+2003), also called a mutton, in the same units as TextHeight() using the current settings for TextHeight() and Font().

◆ TextWidthOfEnSpace()

double ON_DimStyle::TextWidthOfEnSpace ( ) const

Returns: Width of an en space (U+2002), also called a nut, in the same units as TextHeight() using the current settings for TextHeight() and Font().

◆ TextWidthOfFigureSpace()

double ON_DimStyle::TextWidthOfFigureSpace ( ) const

Returns: Width of a figure space (U+2007) in the same units as TextHeight() using the current settings for TextHeight() and Font(). Remarks: Typically close to the average with of a decimal digit (0123456789) and used to line up columns of numeric values.

◆ TextWidthOfIdeographicSpace()

double ON_DimStyle::TextWidthOfIdeographicSpace ( ) const

Returns: Width of an ideographic space (U+3000) in the same units as TextHeight() using the current settings for TextHeight() and Font(). Remarks: The width of ideographic (CJK) characters.

◆ TextWidthOfMediumMathematicalSpace()

double ON_DimStyle::TextWidthOfMediumMathematicalSpace ( ) const

Returns: Width of a medium mathematical space (U+205F) in the same units as TextHeight() using the current settings for TextHeight() and Font().

◆ TextWidthOfSpace()

double ON_DimStyle::TextWidthOfSpace ( ) const

Returns: Width of an em space (U+2003), also called a mutton, in the same units as TextHeight() using the current settings for TextHeight() and Font().

◆ ToleranceFormat()

tolerance_format ON_DimStyle::ToleranceFormat ( ) const

◆ ToleranceFormatFromUnsigned()

static ON_DimStyle::tolerance_format ON_DimStyle::ToleranceFormatFromUnsigned ( unsigned int  format_as_unsigned)
static

◆ ToleranceHeightScale()

double ON_DimStyle::ToleranceHeightScale ( ) const

◆ ToleranceLowerValue()

double ON_DimStyle::ToleranceLowerValue ( ) const

◆ ToleranceResolution()

int ON_DimStyle::ToleranceResolution ( ) const

◆ ToleranceUpperValue()

double ON_DimStyle::ToleranceUpperValue ( ) const

◆ ToleranceZeroSuppress()

ON_DimStyle::suppress_zero ON_DimStyle::ToleranceZeroSuppress ( ) const

OBSOLETE - The ZeroSuppress() or AlternateZeroSuppress() property is used to format tolerance display. ToleranceZeroSuppress() is ignored.

◆ UnitSystem()

ON::LengthUnitSystem ON_DimStyle::UnitSystem ( ) const

NOTE WELL: A dimstyle unit system was added in V6, but has never been fully used. The idea was this would make it easier to figure out what text height/ arrow size, ... actually meant. Especially in situations where model space and page space have different unit systems, and in more complex cases like text in instance definitions and inserting annotation from models with mismatched unit systems. It is used internally to get some scales properly set and use in limited merging contexts.

From a user's perspective, in Rhino 6 and Rhino 7 ON_DimStyle lengths like TextHeight(), ArrowSize(), ... are with respect to the context the annotation resides in. For example, if TextHeight() = 3.5, model units = meters, page units = millimters, and DimScale() = 1, then text created in model space will be 3.5 meters high and text created in page space will be 3.5 millimeters high.

Ideally, ON_DimStyle::UnitSystem() would specify the text height units and ON_DimStyle::DimScale() could be adjusted as model space extents require. Text in instance definitions would have a well defined height and references to those instance definitions would display predictably in both model space and page space. /summary>

◆ UnitSystemIsSet()

bool ON_DimStyle::UnitSystemIsSet ( ) const

/ NOTE WELL: A dimstyle unit system was added in V6, but has never been fully used. / The idea was this would make it easier to figure out what text height/ arrow size, / ... actually meant. Especially in situations where model space and page space have / different unit systems, and in more complex cases like text in instance definitions / and inserting annotation from models with mismatched unit systems. / It is used internally to get some scales properly set and use in limited / merging contexts. / / From a user's perspective, in Rhino 6 and Rhino 7 ON_DimStyle lengths like TextHeight(), ArrowSize(), ... / are with respect to the context the annotation resides in. For example, if TextHeight() = 3.5, / model units = meters, page units = millimters, and DimScale() = 1, then / text created in model space will be 3.5 meters high and / text created in page space will be 3.5 millimeters high. / / Ideally, ON_DimStyle::UnitSystem() would specify the text height units / and ON_DimStyle::DimScale() cound be adjusted as model space extents require. / Text in instance definitions would have a well defined height and references / to those instance definitions would display predictably in both model space and page space. Returns: true if the unit system is set to an explicit valid length unit.

◆ V5AngleFormat()

static int ON_DimStyle::V5AngleFormat ( ON_DimStyle::angle_format  v6format)
static

◆ V5ArrowType()

static int ON_DimStyle::V5ArrowType ( ON_Arrowhead::arrow_type  v6type)
static

For converting to and from V5 Dimstyles.

double ModelSize() const; void SetModelSize(double size); double PaperSize() const; void SetPaperSize(double size);

◆ V5LengthFormat()

static int ON_DimStyle::V5LengthFormat ( ON_DimStyle::OBSOLETE_length_format  v6format)
static

◆ V5MaskColorSourceFromV6MaskType()

static int ON_DimStyle::V5MaskColorSourceFromV6MaskType ( ON_TextMask::MaskType  mask_type)
static

◆ V5ToleranceFormat()

static int ON_DimStyle::V5ToleranceFormat ( ON_DimStyle::tolerance_format  v6format)
static

◆ V6AngleFormat()

static ON_DimStyle::angle_format ON_DimStyle::V6AngleFormat ( int  v5format)
static

◆ V6ArrowType()

static ON_Arrowhead::arrow_type ON_DimStyle::V6ArrowType ( int  v5type)
static

◆ V6LengthFormat()

static ON_DimStyle::OBSOLETE_length_format ON_DimStyle::V6LengthFormat ( int  v5format)
static

◆ V6MaskTypeFromV5MaskColorSource()

static ON_TextMask::MaskType ON_DimStyle::V6MaskTypeFromV5MaskColorSource ( int  v5_mask_color_source)
static

◆ V6ToleranceFormat()

static ON_DimStyle::tolerance_format ON_DimStyle::V6ToleranceFormat ( int  v5format)
static

◆ Write()

bool ON_DimStyle::Write ( ON_BinaryArchive ) const
overridevirtual

virtual

Reimplemented from ON_Object.

◆ ZeroSuppress()

ON_DimStyle::suppress_zero ON_DimStyle::ZeroSuppress ( ) const

◆ ZeroSuppressFromUnsigned()

static ON_DimStyle::suppress_zero ON_DimStyle::ZeroSuppressFromUnsigned ( unsigned int  suppress_ero_as_unsigned)
static

◆ ZeroSuppressMatchesLengthDisplay()

static bool ON_DimStyle::ZeroSuppressMatchesLengthDisplay ( ON_DimStyle::suppress_zero  zero_suppress,
ON_DimStyle::LengthDisplay  length_display 
)
static

Description: The valid choices for ON_DimStyle::suppress_zero depend on the dimension length display. Parameters: zero_suppress - [in] length_display - [in] Returns: True if zero_suppression is a valid setting when DimensionLengthDiplay = dimension_length_display Remarks: LengthDisplay: Inch fractional – No zero suppression matches LengthDisplay : FeetAndInches – Zero suppress can be None, Suppress zero feet, Suppress zero inches or Suppress zero feet and zero inches. LengthDisplay : ModelUnits or any Decimal mode – Zero suppress can be None, Suppress leading, Suppress trailing or Suppress leading and trailing.

Friends And Related Function Documentation

◆ ON_V5x_DimStyle

friend class ON_V5x_DimStyle
friend

Member Data Documentation

◆ Default

const ON_DimStyle ON_DimStyle::Default
static

index = -1, unique and persistent id.

◆ DefaultFeetDecimal

const ON_DimStyle ON_DimStyle::DefaultFeetDecimal
static

index = -8, unique and persistent id.

◆ DefaultFeetEngrave

const ON_DimStyle ON_DimStyle::DefaultFeetEngrave
static

index = -9, unique and persistent id.

◆ DefaultFootInchArchitecture

const ON_DimStyle ON_DimStyle::DefaultFootInchArchitecture
static

index = -4, unique and persistent id.

◆ DefaultInchDecimal

const ON_DimStyle ON_DimStyle::DefaultInchDecimal
static

index = -2, unique and persistent id.

◆ DefaultInchFractional

const ON_DimStyle ON_DimStyle::DefaultInchFractional
static

index = -3, unique and persistent id.

◆ DefaultMillimeterArchitecture

const ON_DimStyle ON_DimStyle::DefaultMillimeterArchitecture
static

index = -7, unique and persistent id.

◆ DefaultMillimeterEngrave

const ON_DimStyle ON_DimStyle::DefaultMillimeterEngrave
static

index = -10, unique and persistent id.

◆ DefaultMillimeterLarge

const ON_DimStyle ON_DimStyle::DefaultMillimeterLarge
static

index = -6, unique and persistent id.

◆ DefaultMillimeterSmall

const ON_DimStyle ON_DimStyle::DefaultMillimeterSmall
static

index = -5, unique and persistent id.

◆ DefaultModelUnitsDecimal

const ON_DimStyle ON_DimStyle::DefaultModelUnitsDecimal
static

index = -11, unique and persistent id.

◆ DefaultModelUnitsEngrave

const ON_DimStyle ON_DimStyle::DefaultModelUnitsEngrave
static

index = -12, unique and persistent id.

◆ Unset

const ON_DimStyle ON_DimStyle::Unset
static

Predefined default dimension styles always available.

index = ON_UNSET_INT_INDEX, id = nil.