wxPropertyGridPopulator Class Reference

Allows populating wxPropertyGrid from arbitrary text source. More...

#include <propgrid.h>

List of all members.

Public Member Functions

wxPGPropertyAdd (const wxString &propClass, const wxString &propLabel, const wxString &propName, const wxString *propValue, wxPGChoices *pChoices=NULL)
bool AddAttribute (const wxString &name, const wxString &type, const wxString &value)
void AddChildren (wxPGProperty *property)
virtual void DoScanForChildren ()=0
wxPGPropertyGetCurParent () const
const wxPropertyGridStateGetState () const
wxPropertyGridStateGetState ()
wxPGChoices ParseChoices (const wxString &choicesString, const wxString &idString)
virtual void ProcessError (const wxString &msg)
void SetGrid (wxPropertyGrid *pg)
void SetState (wxPropertyGridState *state)
 wxPropertyGridPopulator ()
virtual ~wxPropertyGridPopulator ()

Static Public Member Functions

static bool ToLongPCT (const wxString &s, long *pval, long max)

Protected Attributes

wxPGHashMapS2P m_dictIdChoices
wxPropertyGridm_pg
wxArrayPGProperty m_propHierarchy
wxPropertyGridStatem_state

Detailed Description

Allows populating wxPropertyGrid from arbitrary text source.

Definition at line 8385 of file propgrid.h.


Constructor & Destructor Documentation

wxPropertyGridPopulator::wxPropertyGridPopulator (  ) 

Default constructor.

virtual wxPropertyGridPopulator::~wxPropertyGridPopulator (  )  [virtual]

Destructor.


Member Function Documentation

wxPGProperty* wxPropertyGridPopulator::Add ( const wxString &  propClass,
const wxString &  propLabel,
const wxString &  propName,
const wxString *  propValue,
wxPGChoices pChoices = NULL 
)

Appends a new property under bottommost parent.

Parameters:
propClass Property class as string.
bool wxPropertyGridPopulator::AddAttribute ( const wxString &  name,
const wxString &  type,
const wxString &  value 
)

Adds attribute to the bottommost property.

Parameters:
type Allowed values: "string", (same as string), "int", "bool". Empty string mean autodetect.
void wxPropertyGridPopulator::AddChildren ( wxPGProperty property  ) 

Pushes property to the back of parent array (ie. it becomes bottommost parent), and starts scanning/adding children for it. When finished, parent array is returned to the original state.

virtual void wxPropertyGridPopulator::DoScanForChildren (  )  [pure virtual]

Called once in AddChildren.

wxPGProperty* wxPropertyGridPopulator::GetCurParent (  )  const [inline]

Returns id of parent property for which children can currently be added.

Definition at line 8429 of file propgrid.h.

const wxPropertyGridState* wxPropertyGridPopulator::GetState (  )  const [inline]

Definition at line 8435 of file propgrid.h.

wxPropertyGridState* wxPropertyGridPopulator::GetState (  )  [inline]

Definition at line 8434 of file propgrid.h.

wxPGChoices wxPropertyGridPopulator::ParseChoices ( const wxString &  choicesString,
const wxString &  idString 
)

Parses strings of format "choice1"[=value1] ... "choiceN"[=valueN] into wxPGChoices. Registers parsed result using idString (if not empty). Also, if choices with given id already registered, then don't parse but return those choices instead.

virtual void wxPropertyGridPopulator::ProcessError ( const wxString &  msg  )  [virtual]

Implement in derived class to do custom process when an error occurs. Default implementation uses wxLogError.

void wxPropertyGridPopulator::SetGrid ( wxPropertyGrid pg  ) 
void wxPropertyGridPopulator::SetState ( wxPropertyGridState state  ) 
static bool wxPropertyGridPopulator::ToLongPCT ( const wxString &  s,
long *  pval,
long  max 
) [static]

Like wxString::ToLong, except allows N% in addition of N.


Member Data Documentation

wxPGHashMapS2P wxPropertyGridPopulator::m_dictIdChoices [protected]

Hashmap for string-id to wxPGChoicesData mapping.

Definition at line 8466 of file propgrid.h.

Used property grid.

Definition at line 8457 of file propgrid.h.

wxArrayPGProperty wxPropertyGridPopulator::m_propHierarchy [protected]

Tree-hierarchy of added properties (that can have children).

Definition at line 8463 of file propgrid.h.

Used property grid state.

Definition at line 8460 of file propgrid.h.


The documentation for this class was generated from the following file:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


wxpropgrid
Author(s): Jaakko Salli
autogenerated on Fri Jan 11 09:34:08 2013