Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   Related Pages  

ObjCryst::WXField Class Reference

This is the abstract base class for all fields, wether they contain a floating-point parameter, or a string,... More...

#include <wxCryst.h>

Inheritance diagram for ObjCryst::WXField::

ObjCryst::WXCrystObjBasic ObjCryst::WXCostFunction ObjCryst::WXFieldChoice ObjCryst::WXFieldName ObjCryst::WXFieldOption ObjCryst::WXFieldParBase ObjCryst::WXFieldRefPar ObjCryst::WXFieldPar List of all members.

Public Methods

 WXField (wxWindow *parent, const string &label, const int field_id)
 Constructor, specifying the label of the field.

bool Layout ()
 Redo the layout of the field.

void SetLabel (const string &)
 Change the field's label.

virtual void Revert ()=0
 After a user entry, this allows to go back to the last value, if for some reason the entry was rejected (because the object is currently busy, ...).

virtual bool SetForegroundColour (const wxColour &colour)
 Change the colour of the field's title. Can be used (with parcimony) to clarify the interface.


Protected Attributes

wxBoxSizer * mpSizer
 The horizontal sizer in which the title, button, fields, are put.

wxStaticText * mpLabel
 The label.

const int mId
 The Id of this field.


Detailed Description

This is the abstract base class for all fields, wether they contain a floating-point parameter, or a string,...

All WXField have a title and an entry field.

Todo:
Currently for all fields, the user must hit the 'enter' key to validate the input, which is annoying. So it would be nice to use another way. For example by recording when some typing has been made in a field, and doing the actual reading afterwards (eg a global function should be created to read the input for all fields, and that could be complicated to handle).


The documentation for this class was generated from the following file:
Generated on Wed Nov 14 19:48:38 2001 for ObjCryst++ by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001