MGUI::FORM_EDIT_OBJECTNAME Class Reference

Form consisting of label and string edit field. More...

#include <mgui/formeditobjname.h>

Inheritance diagram for MGUI::FORM_EDIT_OBJECTNAME:

Inheritance graph
[legend]
List of all members.

Public Member Functions

void ClearValue (bool notify=true)
void Create (MGUI::LAYOUT_PANE_BASE &ParentPane, const MISTRING &label, MGUI::LAYOUT_SIZEALIGN sizealign=MGUI::LAYOUT_SIZEALIGN_FixedSize, MGUI::CTRL_LABEL::STYLE labelstyle=MGUI::CTRL_LABEL::STYLE_LeftNoWrap)
 FORM_EDIT_OBJECTNAME ()
MGUI::CTRL_EDIT_OBJECTNAMEGetEditCtrl ()
MGUI::CTRL_LABELGetLabel ()
const RVC::OBJECTNAMEGetValue () const
void IniRead (INIHANDLE IniHandle, const char *IniGroup, const char *IniField, bool notify=true)
void IniWrite (INIHANDLE IniHandle, const char *IniGroup, const char *IniField) const
void SetLabel (const MISTRING &label)
void SetSelection (int StartChar=0, int EndChar=-1, bool NoScroll=true)
void SetValidChars (const MIUNICODE *string, bool invert=false)
void SetValue (const RVC::OBJECTNAME &name, bool notify=true)
virtual ~FORM_EDIT_OBJECTNAME ()

Protected Member Functions

virtual void OnChangeValue ()
virtual bool OnValidate (MISTRING &string)

Private Attributes

CTRL_EDIT_OBJECTNAME_T< FORM_EDIT_OBJECTNAMEm_editctrl
CTRL_LABEL m_label

Detailed Description

Form consisting of label and string edit field.

Definition at line 170 of file formeditobjname.h.


Constructor & Destructor Documentation

MGUI::FORM_EDIT_OBJECTNAME::FORM_EDIT_OBJECTNAME  ) 
 

Constructor.

virtual MGUI::FORM_EDIT_OBJECTNAME::~FORM_EDIT_OBJECTNAME  )  [virtual]
 

Destructor.


Member Function Documentation

void MGUI::FORM_EDIT_OBJECTNAME::ClearValue bool  notify = true  )  [inline]
 

Clear to empty string.

Parameters:
notify  Call OnChangeValue() if control has already been created

Definition at line 181 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::Create MGUI::LAYOUT_PANE_BASE ParentPane,
const MISTRING label,
MGUI::LAYOUT_SIZEALIGN  sizealign = MGUI::LAYOUT_SIZEALIGN_FixedSize,
MGUI::CTRL_LABEL::STYLE  labelstyle = MGUI::CTRL_LABEL::STYLE_LeftNoWrap
 

Create form with label from resource lookup.

Parameters:
ParentPane  Parent pane
label  Label

MGUI::CTRL_EDIT_OBJECTNAME& MGUI::FORM_EDIT_OBJECTNAME::GetEditCtrl  )  [inline]
 

Retrieve string "edit" control for form.

Definition at line 194 of file formeditobjname.h.

MGUI::CTRL_LABEL& MGUI::FORM_EDIT_OBJECTNAME::GetLabel  )  [inline]
 

Retrieve label control for form.

Usually the label control is only retrieved for alignment purposes.

Definition at line 199 of file formeditobjname.h.

const RVC::OBJECTNAME& MGUI::FORM_EDIT_OBJECTNAME::GetValue  )  const [inline]
 

Get current string value.

Definition at line 203 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::IniRead INIHANDLE  IniHandle,
const char *  IniGroup,
const char *  IniField,
bool  notify = true
[inline]
 

Read value from INI file.

If Create() has already been performed the control's state will be updated.

Parameters:
IniHandle  Handle to INI file to read from, 0 for default
IniGroup  INI group to read from
IniField  INI field to read from
notify  Call OnChangeValue() if control has already been created

Definition at line 208 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::IniWrite INIHANDLE  IniHandle,
const char *  IniGroup,
const char *  IniField
const [inline]
 

Write current value to INI file.

Parameters:
IniHandle  Handle to INI file to write to, 0 for default
IniGroup  INI group to write to
IniField  INI field to write to

Definition at line 216 of file formeditobjname.h.

virtual void MGUI::FORM_EDIT_OBJECTNAME::OnChangeValue  )  [protected, virtual]
 

Called when value is changed after validation.

Derived class must call corresponding base class method BEFORE performing its own processing. If the user modifies the text in the edit control this will not be called until the control loses "focus".

Reimplemented in MGUI::FORM_EDIT_OBJECTNAME_T< _CT >.

virtual bool MGUI::FORM_EDIT_OBJECTNAME::OnValidate MISTRING string  )  [protected, virtual]
 

Validate the string and alter if possible/necessary.

Derived class must call corresponding base class method BEFORE performing its own processing.

Returns:
'true' if string could be validated, 'false' if not
Parameters:
string  String to be validated

Reimplemented in MGUI::FORM_EDIT_OBJECTNAME_T< _CT >.

void MGUI::FORM_EDIT_OBJECTNAME::SetLabel const MISTRING label  )  [inline]
 

Set label text using string from resource lookup.

Parameters:
label  New label text

Definition at line 223 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::SetSelection int  StartChar = 0,
int  EndChar = -1,
bool  NoScroll = true
[inline]
 

Select range of characters in string.

Parameters:
StartChar  Starting character position in string, 0 for beginning
EndChar  Ending character position, -1 for end of string
NoScroll  Indicates whether to scroll caret into view

Definition at line 228 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::SetValidChars const MIUNICODE string,
bool  invert = false
[inline]
 

Set set of 'valid' or 'invalid' characters.

This does not alter the current contents, if any.

Parameters:
string  Characters valid or invalid to enter
invert  Allow all but specified characters

Definition at line 236 of file formeditobjname.h.

void MGUI::FORM_EDIT_OBJECTNAME::SetValue const RVC::OBJECTNAME name,
bool  notify = true
[inline]
 

Set current string value with validation.

OnValidate() will be called and if valid, the string will be updated. No comparison is made with the current string value.

Parameters:
name  New string to set
notify  Call OnChangeValue() if string actually updated

Definition at line 244 of file formeditobjname.h.


Member Data Documentation

CTRL_EDIT_OBJECTNAME_T<FORM_EDIT_OBJECTNAME> MGUI::FORM_EDIT_OBJECTNAME::m_editctrl [private]
 

Definition at line 265 of file formeditobjname.h.

CTRL_LABEL MGUI::FORM_EDIT_OBJECTNAME::m_label [private]
 

Definition at line 264 of file formeditobjname.h.


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