#ifndef IMAGEBUTTON_MCC_H
#define IMAGEBUTTON_MCC_H



#include <exec/types.h>


#define MUIC_ImageButton  "ImageButton.mcc"
#define ImageButtonObject MUI_NewObject(MUIC_ImageButton


#define MUIA_ImageButton_Image    0x85b9001d /* [ISG] struct MUIS_ImageButton_Image * */
#define MUIA_ImageButton_Label    0x85b9001e /* [ISG] STRPTR                          */
#define MUIA_ImageButton_LabelPos 0x85b9001f /* [ISG] ULONG                           */


#define MUIV_ImageButton_LabelPos_Bottom 0 /* default */
#define MUIV_ImageButton_LabelPos_Right  1
#define MUIV_ImageButton_LabelPos_Left   2
#define MUIV_ImageButton_LabelPos_Top    3

#define MUIV_ImageButton_ImageType_File  0
#define MUIV_ImageButton_ImageType_Body  1
#define MUIV_ImageButton_ImageType_Image 2

#define MUIV_ImageButton_Transparent_None -1


struct MUIS_ImageButton_Image
{
  ULONG ibi_ImageType;
  LONG  ibi_Precision;
  BOOL  ibi_UseFriend;

  union
  {
    struct
    {
      STRPTR ibi_filename;
      UWORD  reserved1[13];
    } ibi_filestuff;

    struct
    {
      UBYTE *ibi_body;
      ULONG  ibi_width,
             ibi_height,
             ibi_depth;
      UBYTE  ibi_masking,
             ibi_compression;
      LONG   ibi_transparent;
      ULONG *ibi_sourcecolors;
      UBYTE *ibi_mappingtable;
    } ibi_bodystuff;

    struct
    {
      BOOL          ibi_fontmatchwidth,
                    ibi_fontmatchheight,
                    ibi_freehoriz,
                    ibi_freevert;
      struct Image *ibi_oldimage;
      STRPTR        ibi_spec;
      LONG          ibi_state;
      UWORD         reserved2[5];
    } ibi_imagestuff;
  } ibi_stuff;

  ULONG reserved[10];
};

#define ibi_Filename        ibi_stuff.ibi_filestuff.ibi_filename

#define ibi_Body            ibi_stuff.ibi_bodystuff.ibi_body
#define ibi_Width           ibi_stuff.ibi_bodystuff.ibi_width
#define ibi_Height          ibi_stuff.ibi_bodystuff.ibi_height
#define ibi_Depth           ibi_stuff.ibi_bodystuff.ibi_depth
#define ibi_Masking         ibi_stuff.ibi_bodystuff.ibi_masking
#define ibi_Compression     ibi_stuff.ibi_bodystuff.ibi_compression
#define ibi_Transparent     ibi_stuff.ibi_bodystuff.ibi_transparent
#define ibi_SourceColors    ibi_stuff.ibi_bodystuff.ibi_sourcecolors
#define ibi_MappingTable    ibi_stuff.ibi_bodystuff.ibi_mappingtable

#define ibi_FontMatchWidth  ibi_stuff.ibi_imagestuff.ibi_fontmatchwidth
#define ibi_FontMatchHeight ibi_stuff.ibi_imagestuff.ibi_fontmatchheight
#define ibi_FreeHoriz       ibi_stuff.ibi_imagestuff.ibi_freehoriz
#define ibi_FreeVert        ibi_stuff.ibi_imagestuff.ibi_freevert
#define ibi_OldImage        ibi_stuff.ibi_imagestuff.ibi_oldimage
#define ibi_Spec            ibi_stuff.ibi_imagestuff.ibi_spec
#define ibi_State           ibi_stuff.ibi_imagestuff.ibi_state



#endif   /* IMAGEBUTTON_MCC_H */
