ToolButtonItem Class Reference

ToolButtonItem Class Reference

#include <custcont.h>

Class Description

This class describes the properties of a 3ds Max custom toolbar button.

Each one of these items represents a UI widget on a Toolbar in 3dsmax user interface.

See also
Class ToolItem, Class MAXBmpFileIcon, Custom User Interface Controls.
+ Inheritance diagram for ToolButtonItem:

Public Member Functions

Constructors
 ToolButtonItem (ToolItemType t, int iOE, int iIE, int iOD, int iID, int iW, int iH, int wd, int ht, int ID, DWORD hID=0, const MCHAR *lbl=NULL, int ori=CTB_HORIZ|CTB_VERT|CTB_FLOAT)
 Constructor. More...
 
 ToolButtonItem (ToolItemType t, MaxBmpFileIcon *pIcon, int iW, int iH, int wd, int ht, int ID, DWORD hID=0, const MCHAR *lbl=NULL, int ori=CTB_HORIZ|CTB_VERT|CTB_FLOAT)
 Constructor. More...
 
 ToolButtonItem (ToolItemType t, MaxBmpFileIcon *pIcon, MaxBmpFileIcon *pInIcon, int iW, int iH, int wd, int ht, int ID, DWORD hID=0, const MCHAR *lbl=NULL, int ori=CTB_HORIZ|CTB_VERT|CTB_FLOAT)
 Constructor. More...
 
- Public Member Functions inherited from ToolItem
virtual ~ToolItem ()
 

Public Attributes

ImageList Members
int iOutEn
 The following four data members (iOutEn, iInEn, iOutDis, iInDis) are indices into the image list. More...
 
int iInEn
 In Enabled. More...
 
int iOutDis
 Out Disabled. More...
 
int iInDis
 In Disabled. More...
 
Dimensions
int iw
 The width of the button image. More...
 
int ih
 The height of the button image. More...
 
Pointer Members
const MCHARlabel
 The label describing the tool button item. More...
 
MaxBmpFileIconmpIcon
 A pointer to the icon image associated with the button. More...
 
MaxBmpFileIconmpInIcon
 A pointer to the pressed (or in) icon image associated with the button. More...
 
- Public Attributes inherited from ToolItem
ToolItemType type
 
int id
 
DWORD helpID
 
int w
 
int h
 
int orient
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 

Constructor & Destructor Documentation

ToolButtonItem ( ToolItemType  t,
int  iOE,
int  iIE,
int  iOD,
int  iID,
int  iW,
int  iH,
int  wd,
int  ht,
int  ID,
DWORD  hID = 0,
const MCHAR lbl = NULL,
int  ori = CTB_HORIZ|CTB_VERT|CTB_FLOAT 
)
inline

Constructor.

Parameters
t- See Tool Item Types.
iOE- The Out&Enabled index.
iIE- The In&Enabled index.
iOD- The Out&Disabled index.
iID- The In&Disabled index.
iW- The image width (size of the bitmap in the ImageList).
iH- The image height (size of the bitmap in the ImageList).
wd- The width of the button.
ht- The height of the button.
ID- The ID of the control.
hID- The help ID. For plug-in developers this id should be set to 0.
*lbl= NULL - The label of the button.
ori= CTB_HORIZ|CTB_VERT|CTB_FLOAT - The allowable orientation of the item. This may be one or more of the following: CTB_HORIZ - Horizontal, CTB_VERT - Vertical CTB_FLOAT - Floating (not docked)
3617  {
3618  type = t;
3619  orient = ori;
3620  iOutEn = iOE; iInEn = iIE; iOutDis = iOD; iInDis = iID;
3621  iw = iW; ih = iH; w = wd; h = ht; id = ID; helpID = hID;
3622  label = lbl;
3623  mpIcon = mpInIcon = NULL;
3624  }
MaxBmpFileIcon * mpIcon
A pointer to the icon image associated with the button.
Definition: custcont.h:3590
int orient
Definition: custcont.h:3548
int iInEn
In Enabled.
Definition: custcont.h:3570
int w
Definition: custcont.h:3547
#define NULL
Definition: autoptr.h:20
int iOutDis
Out Disabled.
Definition: custcont.h:3572
const MCHAR * label
The label describing the tool button item.
Definition: custcont.h:3588
ToolItemType type
Definition: custcont.h:3544
int iInDis
In Disabled.
Definition: custcont.h:3574
int iOutEn
The following four data members (iOutEn, iInEn, iOutDis, iInDis) are indices into the image list...
Definition: custcont.h:3568
MaxBmpFileIcon * mpInIcon
A pointer to the pressed (or in) icon image associated with the button.
Definition: custcont.h:3592
int ih
The height of the button image.
Definition: custcont.h:3582
int iw
The width of the button image.
Definition: custcont.h:3580
int h
Definition: custcont.h:3547
DWORD helpID
Definition: custcont.h:3546
ToolButtonItem ( ToolItemType  t,
MaxBmpFileIcon pIcon,
int  iW,
int  iH,
int  wd,
int  ht,
int  ID,
DWORD  hID = 0,
const MCHAR lbl = NULL,
int  ori = CTB_HORIZ|CTB_VERT|CTB_FLOAT 
)
inline

Constructor.

Parameters
t- See Tool Item Types.
*pIcon- A pointer to the icon associated with the button.
iW- The image width (size of the bitmap in the ImageList).
iH- The image height (size of the bitmap in the ImageList).
wd- The width of the button.
ht- The height of the button.
ID- The ID of the control.
hID- The help ID. For plug-in developers this id should be set to 0.
lbl- The label of the button.
ori- The orientation of the button item.
3641  {
3642  type = t;
3643  orient = ori;
3644  mpIcon = pIcon;
3645  mpInIcon = NULL;
3646  iOutEn = iInEn = iOutDis = iInDis = -1;
3647  iw = iW; ih = iH; w = wd; h = ht; id = ID; helpID = hID;
3648  label = lbl;
3649  }
MaxBmpFileIcon * mpIcon
A pointer to the icon image associated with the button.
Definition: custcont.h:3590
int orient
Definition: custcont.h:3548
int iInEn
In Enabled.
Definition: custcont.h:3570
int w
Definition: custcont.h:3547
#define NULL
Definition: autoptr.h:20
int iOutDis
Out Disabled.
Definition: custcont.h:3572
const MCHAR * label
The label describing the tool button item.
Definition: custcont.h:3588
ToolItemType type
Definition: custcont.h:3544
int iInDis
In Disabled.
Definition: custcont.h:3574
int iOutEn
The following four data members (iOutEn, iInEn, iOutDis, iInDis) are indices into the image list...
Definition: custcont.h:3568
MaxBmpFileIcon * mpInIcon
A pointer to the pressed (or in) icon image associated with the button.
Definition: custcont.h:3592
int ih
The height of the button image.
Definition: custcont.h:3582
int iw
The width of the button image.
Definition: custcont.h:3580
int h
Definition: custcont.h:3547
DWORD helpID
Definition: custcont.h:3546
ToolButtonItem ( ToolItemType  t,
MaxBmpFileIcon pIcon,
MaxBmpFileIcon pInIcon,
int  iW,
int  iH,
int  wd,
int  ht,
int  ID,
DWORD  hID = 0,
const MCHAR lbl = NULL,
int  ori = CTB_HORIZ|CTB_VERT|CTB_FLOAT 
)
inline

Constructor.

Parameters
t- See Tool Item Types.
pIcon- A pointer to the icon associated with the button.
pInIcon- A pointer to the in icon associated with the button.
iW- The image width (size of the bitmap in the ImageList).
iH- The image height (size of the bitmap in the ImageList).
wd- The width of the button.
ht- The height of the button.
ID- The ID of the control.
hID- The help ID. For plug-in developers this id should be set to 0.
lbl- The label of the button.
ori- The orientation of the button item.
3668  {
3669  type = t;
3670  orient = ori;
3671  mpIcon = pIcon;
3672  mpInIcon = pInIcon;
3673  iOutEn = iInEn = iOutDis = iInDis = -1;
3674  iw = iW; ih = iH; w = wd; h = ht; id = ID; helpID = hID;
3675  label = lbl;
3676  }
MaxBmpFileIcon * mpIcon
A pointer to the icon image associated with the button.
Definition: custcont.h:3590
int orient
Definition: custcont.h:3548
int iInEn
In Enabled.
Definition: custcont.h:3570
int w
Definition: custcont.h:3547
int iOutDis
Out Disabled.
Definition: custcont.h:3572
const MCHAR * label
The label describing the tool button item.
Definition: custcont.h:3588
ToolItemType type
Definition: custcont.h:3544
int iInDis
In Disabled.
Definition: custcont.h:3574
int iOutEn
The following four data members (iOutEn, iInEn, iOutDis, iInDis) are indices into the image list...
Definition: custcont.h:3568
MaxBmpFileIcon * mpInIcon
A pointer to the pressed (or in) icon image associated with the button.
Definition: custcont.h:3592
int ih
The height of the button image.
Definition: custcont.h:3582
int iw
The width of the button image.
Definition: custcont.h:3580
int h
Definition: custcont.h:3547
DWORD helpID
Definition: custcont.h:3546

Member Data Documentation

int iOutEn

The following four data members (iOutEn, iInEn, iOutDis, iInDis) are indices into the image list.

They indicate which images to use for each of the four possible button states. You may specify a unique image for each one of these states by passing a different index for each state. Or you may supply a single image to be used for all the states by specifying the same index four times. Out Enabled

int iInEn

In Enabled.

int iOutDis

Out Disabled.

int iInDis

In Disabled.

int iw

The width of the button image.

int ih

The height of the button image.

const MCHAR* label

The label describing the tool button item.

MaxBmpFileIcon* mpIcon

A pointer to the icon image associated with the button.

MaxBmpFileIcon* mpInIcon

A pointer to the pressed (or in) icon image associated with the button.