MKI_HATCHDEF (Entity Data Classes) Changed in Version 2023.2

www.CAD6.com

C++ Syntax

class MKI_HATCHDEF

{

  public:

 

  MKI_HATCHNAME m_szHatchName;

  MKI_COMMENTSHORT m_szHatchComment;

 

  bool   m_fHatchLines1Active;

  double m_dHatchLines1Rotate;

  MKI_HATCHLINELIST m_cHatchLines1;

  __int32 m_nHatchLineIndex1;

 

  bool   m_fHatchLines2Active;

  double m_dHatchLines2Rotate;

  MKI_HATCHLINELIST m_cHatchLines2;

  __int32 m_nHatchLineIndex2;

 

  bool   m_fHatchBlockActive;

  MKI_LIBRARYNAME m_szHatchLibraryName;

  MKI_BLOCKNAME m_szHatchBlockName;

  double m_dHatchBlockRotate,

         m_dHatchBlockScale,

         m_dHatchXStep1,

         m_dHatchXStep2,

         m_dHatchYStep1,

         m_dHatchYStep2,

         m_dHatchLineStep1,

         m_dHatchLineStep2;

 

  double m_dHatchRotate,

         m_dHatchOffset1,

         m_dHatchOffset2;

 

  bool   m_fHatchLocalActive;

  MKI_POINT m_cHatchLocalOrigin;

  double m_dLocalRotate;

 

  void

  Init( void );

 

  bool

  IsIdentical( const MKI_HATCHDEF& f_rData ) const; New in Version 2022.1

};

 

This structure contains a hatching type definition.

 

Element Description

m_szHatchName Changed in Version 2019.1

[MKI_HATCHNAME] Name of the hatching type, up to 63 characters.

If used within a MKI_ENTITY_HATCH, m_szHatchName contains the name of the hatching type used to create the hatching in the first place. This is NOT a dynamic link to that hatching type, but only for informational purposes.

m_szHatchComment New in Version 2023.2

[MKI_COMMENTSHORT] Comment on the hatching type, up to 63 characters.

m_fHatchLine1Active

[bool] Determines whether the first line sequence it active or not.

m_dHatchLine1Rotate

[double] Rotation angle of the first line sequence.

m_cMultiLine1 New in Version 2016.1

[MKI_HATCHLINELIST] First line sequence.

m_nHatchLineIndex1 Changed in Version 2016.1

[__int32] Index of the first line sequence to be used. No longer actively used, only provided as intermediate storage while loading older file versions!

m_fHatchLine2Active

[bool] Determines whether the second line sequence it active or not.

m_dHatchLine2Rotate

[double] Rotation angle of the second line sequence.

m_cMultiLine2 New in Version 2016.1

[MKI_HATCHLINELIST] Second line sequence.

m_nHatchLineIndex2 Changed in Version 2016.1

[__int32] Index of the second line sequence to be used. No longer actively used, only provided as intermediate storage while loading older file versions!

m_fHatchBlockActive

[bool] Determines whether a hatching block is to be used.

m_szHatchLibraryName Changed in Version 2019.1

[MKI_LIBRARYNAME] Name of the library containing the desired block, maximum 63 characters. If the desired hatching block is located inside the drawing, set this name to MKI_BLOCK_ID ("*").

m_szHatchBlockName Changed in Version 2019.1

[MKI_BLOCKNAME] Name of the block, maximum 255 characters.

m_dHatchBlockRotate

[double] This value determines the rotation of the hatching block (based on its insertion point).

m_dHatchBlockScale

[double] This value determines the scaling of the hatching block.

m_dHatchBlockXStep1

m_dHatchBlockXStep2

[double] These two values determine the horizontal advance of the block-based hatching.

m_dHatchBlockYStep1

m_dHatchBlockYStep2

[double] These two values determine the vertical advance of the block-based hatching.

m_dHatchBlockLineStep1

m_dHatchBlockLineStep2

[double] These two values determine the horizontal line offset of the block-based hatching.

m_dHatchRotate

[double] This value determines the global rotation of the complete hatching in [rad].

m_dHatchOffset1

m_dHatchOffset2

[double] These two values determine the offset of the hatching.

m_fHatchLocalActive New in Version 2021.0

[bool] If true, the following local fixed point and rotation shall be applied, otherwise not.

m_cHatchLocalOrigin New in Version 2021.0

[MKI_POINT] Local hatching fixed point in internal coordinates (will only be used instead of the global fixed point if HatchLocalActive is true).

m_dHatchLocalRotate New in Version 2021.0

[double] This value determines an additional, local rotation of the complete hatching in [rad] (will only be added to HatchRotate if HatchLocalActive is true).

 

MKD Syntax

The section =HATCH= contains up to MKI_HATCH_MAX hatching types.

 

Head of Section

=HATCH=;

TotalNum,HatchActive,HatchGlobalOrigin.x,HatchGlobalOrigin.y;

 

Entry for each Hatching Type Definition

HatchName,HatchIndex,HatchComment;

HatchLine1Active,HatchLine1[0],...,HatchLine1[7],HatchLine1Rotate;

HatchLine2Active,HatchLine2[0],...,HatchLine2[7],HatchLine2Rotate;

HatchBlockActive,HatchLibraryName,HatchBlockName,

HatchBlockRotate,HatchBlockScale,

HatchBlockXStep1,HatchBlockXStep2,

HatchBlockYStep1,HatchBlockYStep2,

HatchBlockLineStep1,HatchBlockLineStep2;

HatchRotate,HatchOffset1,HatchOffset2;

HatchLocalActive,HatchLocalOrigin.x,HatchLocalOrigin.y,HatchLocalRotate;

 

End of Section

=END=;

 

If the section =HATCH= does not exist, assume no hatching type to be defined (m_nTotalNum = 0) and hatching type 0 to be active.

 

Element Description

m_nTotalNum

[__int32] Number of hatching type definitions to follow. Valid range is 0 to MKI_HATCH_MAX inclusive.

m_nHatchActive

[__int32] Index of the hatching type that was active when the drawing was saved (referring to m_nHatchIndex). Valid range is 0 to MKI_HATCH_MAX inclusive. This value is optional and will be set to 0 if not existing!

m_cHatchGlobalOrigin

[MKI_POINT] Global fixed point point for all dynamic hatchings in internal coordinates.

m_nHatchIndex

[__int32] Index of the hatching type (1 to MKI_HATCH_MAX). Each index may be assigned to one hatching type only, as this index is used internally to identify a hatching type.

 

CAD6interface 2025.0 - Copyright 2025 Malz++Kassner® GmbH