Init (class MKI_ICON_DATA) New in Version 2026.1

www.CAD6.com

C++ Syntax

void

MKI_IDENTDATA::Init(

 MKI_BITMAP_PTR f_pBitmap,

 __int32 f_nIconIndex = 0,

 __int32 f_nColumns = 1 );

 

Initializes the structure with specific icon position data.

 

Parameters

f_pBitmap

[MKI_BITMAP_PTR] This bitmap handle identifies the bitmap that contains the icon. If nullptr, the structure will be initialized with "empty" data, i.e. m_nIconMode = -1.

When used as a plug-in's command or menu icon, the bitmap must be defined with 32-bit RGBA colors. Use MKI_BitmapLoadImage() to load PNG files with alpha channel as icon bitmaps. This bitmap handle must then be valid throughout the plug-in's lifetime, i.e. it should have been be created inside the MKI_PlugInInit procedure and should not be deleted until inside the MKI_PlugInExit procedure!

f_pIconIndex

[__int32] Zero-based index of the icon within the bitmap. A standard command icon has a size of MKI_ICON_COMMAND_SIZE (80) by MKI_ICON_COMMAND_SIZE (80) pixels, centered on a square grid space of MKI_ICON_COMMAND_OFFSET (100) by MKI_ICON_COMMAND_OFFSET (100) pixels. Index 0 is in the top left corner of the bitmap. Default is 0.

f_nColumns

[__int32] Number of columns of MKI_ICON_COMMAND_OFFSET (100) pixels in the icon bitmap. Default is 1.

 

CAD6interface 2026.1 - Copyright 2026 Malz++Kassner® GmbH