Palette.mui Class Reference¶
BOOPSI custom class Palette.mui (MUI 3.8 dev). Each ### sub-section below documents one of the class's attributes or methods. Sub-classes of Palette.mui are listed at the end under Sub-classes; the class hierarchy itself is documented in the MUI classes index.
Function index¶
Class definition
Attributes
Palette.mui¶
MUIA_Palette_Entries¶
**MUIA_Palette_Entries -- (V6 ) [I.G], struct MUI_Palette_Entry ***
Function
Specify the colors that the user should be able to adjust with this palette object. You supply an array of MUI_Palette_Structures here, each entry defining one color: struct MUI_Palette_Entry { LONG mpe_ID; ULONG mpe_Red; ULONG mpe_Green; ULONG mpe_Blue; LONG mpe_Group; }; mpe_ID : This entry is not used by palette class, you can put in whatever you want, except the value MUIV_Palette_Entry_End (==-1), which terminates the array. mpe_Red : 32-bit red component of the current color. This field will be changed by palette class whenever the user edits the color. mpe_Green: 32-bit green component of the current color. This field will be changed by palette class whenever the user edits the color. mpe_Blue : 32-bit blue component of the current color. This field will be changed by palette class whenever the user edits the color. mpe_Group: Entries with the same mpe_Group value are concatenated. Whenever a new color in the listview is selected, all other colors with the same mpe_Group get selected as well and get adjusted all at once. Entry concatenation can be changed by the user, as long as you don't disable this feature with the MUIA_Palette_Groupable attribute.
Example
static struct MUI_Palette_Entry SystemDefaultPalette[] =
{
{ TEXTPEN ,0x00000000,0x00000000,0x00000000,0 },
{ SHINEPEN ,0xffffffff,0xffffffff,0xffffffff,1 },
{ SHADOWPEN ,0x00000000,0x00000000,0x00000000,0 },
{ FILLPEN ,0x66666666,0x88888888,0xbbbbbbbb,2 },
{ FILLTEXTPEN ,0xffffffff,0xffffffff,0xffffffff,1 },
{ BACKGROUNDPEN ,0xaaaaaaaa,0xaaaaaaaa,0xaaaaaaaa,3 },
{ HIGHLIGHTTEXTPEN,0xffffffff,0xffffffff,0xffffffff,1 },
{ BARDETAILPEN ,0x00000000,0x00000000,0x00000000,0 },
{ BARBLOCKPEN ,0xffffffff,0xffffffff,0xffffffff,1 },
{ BARTRIMPEN ,0x00000000,0x00000000,0x00000000,0 },
{ MUIV_Palette_Entry_End,0,0,0,0 },
};
See also
MUIA_Palette_Names
MUIA_Palette_Groupable¶
MUIA_Palette_Groupable -- (V6 ) [ISG], BOOL
Function
Enables/disables palette color grouping. Defaults to TRUE.
See also
MUIA_Palette_Entries
MUIA_Palette_Names¶
MUIA_Palette_Names -- (V6 ) [ISG], char **
Function
Specify the names of a palette objects color entries.
Without names, the color listview just displays
"Color
Example
static struct MUI_Palette_Entry ColorEntries[] =
{
{ TEXTPEN ,0x00000000,0x00000000,0x00000000,2 },
{ SHINEPEN ,0xffffffff,0xffffffff,0xffffffff,4 },
{ SHADOWPEN ,0x00000000,0x00000000,0x00000000,5 },
{ FILLPEN ,0x66666666,0x88888888,0xbbbbbbbb,3 },
{ FILLTEXTPEN ,0xffffffff,0xffffffff,0xffffffff,6 },
{ BACKGROUNDPEN ,0x00000000,0x00000000,0x00000000,7 },
{ HIGHLIGHTTEXTPEN,0xffffffff,0xffffffff,0xffffffff,8 },
{ BARDETAILPEN ,0x00000000,0x00000000,0x00000000,9 },
{ BARBLOCKPEN ,0xffffffff,0xffffffff,0xffffffff,1 },
{ BARTRIMPEN ,0x00000000,0x00000000,0x00000000,0 },
{ MUIV_Palette_Entry_End,0,0,0,0 },
};
static const char *ColorNames[] =
{
"Text" ,
"Bright Edges" ,
"Dark Edges" ,
"Active Window Bars" ,
"Active Window Titles",
"Background" ,
"Important Text" ,
"Menu Text" ,
"Menu Background" ,
"Menu Line"
};
po = PaletteObject,
MUIA_Palette_Entries, ColorEntries,
MUIA_Palette_Names , ColorNames,
End;
See also
MUIA_Palette_Entries