MGUI::FORM_COLOR_EDIT_LIST Class Reference

Form for color edit list. More...

#include <mgui/coloredl.h>

Inheritance diagram for MGUI::FORM_COLOR_EDIT_LIST:

Inheritance graph
[legend]
List of all members.

Public Types

enum  CAP { CAP_NoTransparent, CAP_AllowTransparent, CAP_AllowTransparency, CAP_FromForm }
enum  LAYOUT { LAYOUT_Vertical, LAYOUT_Horizontal }

Public Member Functions

int AddItem (const ITEM &item)
void Create (MGUI::LAYOUT_PANE_BASE &ParentPane, int listrows, CAP capability=CAP_NoTransparent, LAYOUT layout=LAYOUT_Vertical)
 FORM_COLOR_EDIT_LIST ()
const COLORGetItemColor (int itemid)
UINT32 GetItemColorRef (int itemid)
virtual bool IsCreated () const
virtual bool IsEnabled () const
virtual void SetEnabled (bool enabled=true)
void SetItemColor (int itemid, const COLOR &color, bool notify=true)
virtual void SetVisible (bool visible=true)
virtual ~FORM_COLOR_EDIT_LIST ()

Protected Member Functions

virtual void OnChangeItemColor (int itemid, const COLOR &color)

Detailed Description

Form for color edit list.

This form includes a list showing color name and sample, and a set of controls to "edit" the selected color.

Definition at line 51 of file coloredl.h.


Member Enumeration Documentation

enum MGUI::FORM_COLOR_EDIT_LIST::CAP
 

Color editing capabilities.

Enumeration values:
CAP_NoTransparent  No transparency.
CAP_AllowTransparent  Allow transparency on/off control.
CAP_AllowTransparency  Allow transparency percentage control.
CAP_FromForm  Used in item construction to obtain capability from form.

Definition at line 55 of file coloredl.h.

enum MGUI::FORM_COLOR_EDIT_LIST::LAYOUT
 

Form layout.

Enumeration values:
LAYOUT_Vertical  Item edit controls below list.
LAYOUT_Horizontal  Item edit controls to right of list.

Definition at line 63 of file coloredl.h.


Constructor & Destructor Documentation

MGUI::FORM_COLOR_EDIT_LIST::FORM_COLOR_EDIT_LIST  ) 
 

Constructor.

virtual MGUI::FORM_COLOR_EDIT_LIST::~FORM_COLOR_EDIT_LIST  )  [virtual]
 

Destructor.


Member Function Documentation

int MGUI::FORM_COLOR_EDIT_LIST::AddItem const ITEM item  ) 
 

Add item to list.

Returns:
Item ID for use when retrieve color.

void MGUI::FORM_COLOR_EDIT_LIST::Create MGUI::LAYOUT_PANE_BASE ParentPane,
int  listrows,
CAP  capability = CAP_NoTransparent,
LAYOUT  layout = LAYOUT_Vertical
 

Create the form.

Note that if transparency on/off or percentage controls are required for any item in the list the desired capability must be specified when creating the form.

Parameters:
ParentPane  Parent pane for form
listrows  Number of visible rows in color list
capability  Edit capabilities

const COLOR& MGUI::FORM_COLOR_EDIT_LIST::GetItemColor int  itemid  ) 
 

Get color for specified item.

Returns:
Reference to color
Parameters:
itemid  Item ID (from AddItem())

UINT32 MGUI::FORM_COLOR_EDIT_LIST::GetItemColorRef int  itemid  ) 
 

Get color reference for specified item.

Returns:
Color reference
Parameters:
itemid  Item ID (from AddItem())

virtual bool MGUI::FORM_COLOR_EDIT_LIST::IsCreated  )  const [virtual]
 

Determine if form has been created.

Returns:
true if created, false if not.

Implements MGUI::FORM.

virtual bool MGUI::FORM_COLOR_EDIT_LIST::IsEnabled  )  const [virtual]
 

Determine if form is enabled for keyboard or mouse input.

Returns:
true if enabled, false if not, or if not yet created.

virtual void MGUI::FORM_COLOR_EDIT_LIST::OnChangeItemColor int  itemid,
const COLOR color
[protected, virtual]
 

Called when item color changed.

virtual void MGUI::FORM_COLOR_EDIT_LIST::SetEnabled bool  enabled = true  )  [virtual]
 

Set whether mouse or keyboard input to form is allowed.

Implements MGUI::FORM.

void MGUI::FORM_COLOR_EDIT_LIST::SetItemColor int  itemid,
const COLOR color,
bool  notify = true
 

Set color for specified item.

Parameters:
itemid  Item ID from AddItem()
color  New color to set
notify  Call OnChangeItemColor() if 'true' and color changed

virtual void MGUI::FORM_COLOR_EDIT_LIST::SetVisible bool  visible = true  )  [virtual]
 

Set whether form is visible or not.

Implements MGUI::FORM.


The documentation for this class was generated from the following file:
Generated on Wed May 31 15:29:53 2006 for TNTsdk by  doxygen 1.3.8-20040913