17 #if !defined(OPENNURBS_DIMSTYLE_INC_) 18 #define OPENNURBS_DIMSTYLE_INC_ 91 void SetName(
const wchar_t* );
92 void SetName(
const char* );
95 const wchar_t* Name()
const;
101 void SetDefaultsNoExtension();
104 double ExtExtension()
const;
105 void SetExtExtension(
const double);
107 double ExtOffset()
const;
108 void SetExtOffset(
const double);
110 double ArrowSize()
const;
111 void SetArrowSize(
const double);
113 double LeaderArrowSize()
const;
114 void SetLeaderArrowSize(
const double);
116 double CenterMark()
const;
117 void SetCenterMark(
const double);
119 int TextAlignment()
const;
120 void SetTextAlignment( ON::eTextDisplayMode);
122 int ArrowType()
const;
125 int LeaderArrowType()
const;
128 int AngularUnits()
const;
129 void SetAngularUnits(
int);
131 int LengthFormat()
const;
132 void SetLengthFormat(
int);
134 int AngleFormat()
const;
135 void SetAngleFormat(
int);
137 int LengthResolution()
const;
138 void SetLengthResolution(
int);
140 int AngleResolution()
const;
141 void SetAngleResolution(
int);
143 int FontIndex()
const;
144 virtual void SetFontIndex(
int index);
146 double TextGap()
const;
147 void SetTextGap(
double gap);
149 double TextHeight()
const;
150 void SetTextHeight(
double height);
153 double LengthFactor()
const;
154 ON_DEPRECATED
void SetLengthactor(
double);
155 void SetLengthFactor(
double);
157 bool Alternate()
const;
158 void SetAlternate(
bool);
160 double AlternateLengthFactor()
const;
161 ON_DEPRECATED
void SetAlternateLengthactor(
double);
162 void SetAlternateLengthFactor(
double);
164 int AlternateLengthFormat()
const;
165 void SetAlternateLengthFormat(
int);
167 int AlternateLengthResolution()
const;
168 void SetAlternateLengthResolution(
int);
170 int AlternateAngleFormat()
const;
171 void SetAlternateAngleFormat(
int);
173 int AlternateAngleResolution()
const;
174 void SetAlternateAngleResolution(
int);
177 const wchar_t* Prefix()
const;
178 void SetPrefix(
const wchar_t*);
179 void SetPrefix(
wchar_t*);
182 const wchar_t* Suffix()
const;
183 void SetSuffix(
const wchar_t*);
184 void SetSuffix(
wchar_t*);
187 const wchar_t* AlternatePrefix()
const;
188 void SetAlternatePrefix(
const wchar_t*);
189 void SetAlternatePrefix(
wchar_t*);
192 const wchar_t* AlternateSuffix()
const;
193 void SetAlternateSuffix(
const wchar_t*);
194 void SetAlternateSuffix(
wchar_t*);
196 bool SuppressExtension1()
const;
197 void SetSuppressExtension1(
bool);
199 bool SuppressExtension2()
const;
200 void SetSuppressExtension2(
bool);
203 ON_DEPRECATED
void Composite(
const ON_DimStyle&
override);
219 fn_angularunits = 10,
220 fn_lengthformat = 11,
222 fn_angleresolution = 13,
223 fn_lengthresolution = 14,
225 fn_lengthfactor = 16,
227 fn_alternate_lengthfactor = 18,
228 fn_alternate_lengthformat = 19,
229 fn_alternate_lengthresolution = 20,
230 fn_alternate_angleformat = 21,
231 fn_alternate_angleresolution = 22,
234 fn_alternate_prefix = 25,
235 fn_alternate_suffix = 26,
236 fn_dimextension = 27,
237 fn_leaderarrowsize = 28,
238 fn_leaderarrowtype = 29,
239 fn_suppressextension1 = 30,
240 fn_suppressextension2 = 31,
245 fn_overall_scale = 33,
246 fn_ext_line_color_source = 34,
247 fn_dim_line_color_source = 35,
248 fn_arrow_color_source = 36,
249 fn_text_color_source = 37,
250 fn_ext_line_color = 38,
251 fn_dim_line_color = 39,
254 fn_ext_line_plot_color_source = 42,
255 fn_dim_line_plot_color_source = 43,
256 fn_arrow_plot_color_source = 44,
257 fn_text_plot_color_source = 45,
258 fn_ext_line_plot_color = 46,
259 fn_dim_line_plot_color = 47,
260 fn_arrow_plot_color = 48,
261 fn_text_plot_color = 49,
262 fn_ext_line_plot_weight_source = 50,
263 fn_dim_line_plot_weight_source = 51,
264 fn_ext_line_plot_weight_mm = 52,
265 fn_dim_line_plot_weight_mm = 53,
266 fn_tolerance_style = 54,
267 fn_tolerance_resolution = 55,
268 fn_tolerance_upper_value = 56,
269 fn_tolerance_lower_value = 57,
270 fn_tolerance_height_scale = 58,
271 fn_baseline_spacing = 59,
276 fn_mask_color_source = 61,
283 fn_dimscale_source = 65,
288 fn_really_last = 0xFFFF
293 ON_DEPRECATED
void InvalidateField(
eField field);
294 ON_DEPRECATED
void InvalidateAllFields();
295 ON_DEPRECATED
void ValidateField(
eField field);
296 ON_DEPRECATED
bool IsFieldValid(
eField)
const;
299 double DimExtension()
const;
300 void SetDimExtension(
const double);
307 bool IsFieldOverride(
eField field_id)
const;
313 bool HasOverrides()
const;
329 bool IsChildDimstyle()
const;
333 bool IsChildOf(
const ON_UUID& parent_uuid)
const;
334 bool IsChildOf(
ON_UUID& parent_uuid)
const;
339 void SetParentId(
ON_UUID parent_uuid);
340 ON_DEPRECATED
void SetParent(
ON_UUID& parent_uuid);
349 int ToleranceStyle()
const;
350 int ToleranceResolution()
const;
351 double ToleranceUpperValue()
const;
352 double ToleranceLowerValue()
const;
353 double ToleranceHeightScale()
const;
355 double BaselineSpacing()
const;
357 void SetToleranceStyle(
int style);
358 void SetToleranceResolution(
int resolution);
359 void SetToleranceUpperValue(
double upper_value);
360 void SetToleranceLowerValue(
double lower_value);
361 void SetToleranceHeightScale(
double scale);
363 void SetBaselineSpacing(
double spacing =
false);
366 bool DrawTextMask()
const;
367 void SetDrawTextMask(
bool bDraw);
372 int MaskColorSource()
const;
373 void SetMaskColorSource(
int source);
380 void SetDimScaleSource(
int source);
381 int DimScaleSource()
const;
382 void SetDimScale(
double scale);
383 double DimScale()
const;
388 double MaskOffsetFactor()
const;
390 void Scale(
double scale);
394 void SetSourceDimstyle(
ON_UUID source_uuid);
395 ON_UUID SourceDimstyle()
const;
398 static int DefaultToleranceStyle();
399 static int DefaultToleranceResolution();
400 static double DefaultToleranceUpperValue();
401 static double DefaultToleranceLowerValue();
402 static double DefaultToleranceHeightScale();
403 static double DefaultBaselineSpacing();
404 static bool DefaultDrawTextMask();
405 static int DefaultMaskColorSource();
407 static double DefaultDimScale();
408 static int DefaultDimScaleSource();
410 bool CompareFields(
const ON_DimStyle& other)
const;
449 unsigned int m_valid;
464 class ON_DimStyleExtra* DimStyleExtension();
465 const class ON_DimStyleExtra* DimStyleExtension()
const;
virtual ON_BOOL32 IsValid(ON_TextLog *text_log=NULL) const =0
virtual ON_UUID ModelObjectId() const
bool m_bSuppressExtension1
virtual ON_BOOL32 Read(ON_BinaryArchive &binary_archive)
virtual ON_BOOL32 Write(ON_BinaryArchive &binary_archive) const
ON_Object & operator=(const ON_Object &)
int m_alternate_angleresolution
ON_wString m_dimstyle_name
bool m_bSuppressExtension2
int m_alternate_angleformat
int m_alternate_lengthresolution
int m_alternate_lengthformat
double m_alternate_lengthfactor
virtual void Dump(ON_TextLog &) const
ON_wString m_alternate_suffix
ON_wString m_alternate_prefix