wxPropertyContainerMethods Class Reference

In order to have most same base methods, both wxPropertyGrid and wxPropertyGridManager must derive from this. More...

#include <propgrid.h>

Inheritance diagram for wxPropertyContainerMethods:

wxPropertyGrid wxPropertyGridManager wxPropertyGridPage List of all members.

Public Member Functions

void AddPropertyChoice (const wxString &name, const wxString &label, int value=INT_MAX)
void AddPropertyChoice (wxPGId id, const wxString &label, int value=INT_MAX)
void BeginAddChildren (const wxString &name)
void BeginAddChildren (wxPGId id)
void Delete (const wxString &name)
void Delete (wxPGId id)
void DeletePropertyChoice (const wxString &name, int index)
void DeletePropertyChoice (wxPGId id, int index)
void EndAddChildren (const wxString &name)
void EndAddChildren (wxPGId id)
wxPGId GetFirstChild (const wxString &name)
wxPGId GetFirstChild (wxPGId id)
wxPGId GetNextSibling (const wxString &name)
wxPGId GetNextSibling (wxPGId id)
wxString GetPropertyAttributes (wxPGId id, unsigned int flagmask=0xFFFF) const
wxPGId GetPropertyByName (const wxString &name, const wxString &subname) const
wxPGId GetPropertyByName (const wxString &name) const
wxPGId GetPropertyByNameA (const wxString &name) const
wxPGChoicesGetPropertyChoices (const wxString &name)
wxPGChoicesGetPropertyChoices (wxPGId id)
const wxChar * GetPropertyClassName (const wxString &name) const
const wxChar * GetPropertyClassName (wxPGId id) const
wxPGProperty::ClientDataType GetPropertyClientData (const wxString &name) const
wxPGProperty::ClientDataType GetPropertyClientData (wxPGId id) const
const wxPGEditorGetPropertyEditor (const wxString &name) const
const wxPGEditorGetPropertyEditor (wxPGId id) const
wxString GetPropertyHelpString (const wxString &name) const
wxString GetPropertyHelpString (wxPGId id) const
wxBitmap * GetPropertyImage (const wxString &name) const
wxBitmap * GetPropertyImage (wxPGId id) const
unsigned int GetPropertyIndex (const wxString &name)
unsigned int GetPropertyIndex (wxPGId id)
const wxString & GetPropertyLabel (const wxString &name)
const wxString & GetPropertyLabel (wxPGId id)
const wxString & GetPropertyName (wxPGId id)
wxPGId GetPropertyParent (const wxString &name)
wxPGId GetPropertyParent (wxPGId id)
int GetPropertyPriority (const wxString &name)
int GetPropertyPriority (wxPGId id)
wxPGPropertyGetPropertyPtr (const wxString &name) const
wxPGPropertyGetPropertyPtr (wxPGId id) const
wxValidator * GetPropertyValidator (const wxString &name)
wxValidator * GetPropertyValidator (wxPGId id)
wxVariant GetPropertyValue (const wxString &name)
wxVariant GetPropertyValue (wxPGId id)
const wxArrayInt & GetPropertyValueAsArrayInt (const wxString &name) const
const wxArrayString & GetPropertyValueAsArrayString (const wxString &name) const
bool GetPropertyValueAsBool (const wxString &name) const
wxDateTime GetPropertyValueAsDateTime (const wxString &name) const
double GetPropertyValueAsDouble (const wxString &name) const
int GetPropertyValueAsInt (const wxString &name) const
long GetPropertyValueAsLong (const wxString &name) const
const wxPoint & GetPropertyValueAsPoint (const wxString &name) const
const wxSize & GetPropertyValueAsSize (const wxString &name) const
wxString GetPropertyValueAsString (const wxString &name) const
const wxObject * GetPropertyValueAsWxObjectPtr (const wxString &name) const
const wxPGValueTypeGetPropertyValueType (const wxString &name)
const wxPGValueTypeGetPropertyValueType (wxPGId id)
size_t GetPVTI (const wxString &name)
size_t GetPVTI (wxPGId id)
wxString GetPVTN (const wxString &name)
wxString GetPVTN (wxPGId id)
wxPropertyGridStateGetState () const
bool HideProperty (const wxString &name)
bool HideProperty (wxPGId id, bool hide=true)
void InsertPropertyChoice (const wxString &name, const wxString &label, int index, int value=INT_MAX)
void InsertPropertyChoice (wxPGId id, const wxString &label, int index, int value=INT_MAX)
bool IsModified (const wxString &name)
bool IsModified (wxPGId id) const
bool IsPropertyCategory (const wxString &name)
bool IsPropertyCategory (wxPGId id) const
bool IsPropertyEnabled (const wxString &name)
bool IsPropertyEnabled (wxPGId id) const
bool IsPropertyExpanded (const wxString &name)
bool IsPropertyKindOf (const wxString &name, wxPGPropertyClassInfo &info)
bool IsPropertyModified (const wxString &name)
bool IsPropertyModified (wxPGId id) const
bool IsPropertyShown (const wxString &name)
bool IsPropertyShown (wxPGId id) const
bool IsPropertyUnspecified (const wxString &name)
bool IsPropertyUnspecified (wxPGId id) const
bool IsPropertyValueType (const wxString &name, const wxClassInfo *classinfo)
bool IsPropertyValueType (const wxString &name, const wxPGValueType *valuetype)
bool IsPropertyValueType (const wxString &name, const wxChar *typestr)
bool IsPropertyValueType (wxPGId id, const wxClassInfo *classinfo)
bool IsPropertyValueType (wxPGId id, const wxPGValueType *valuetype)
bool IsPropertyValueType (wxPGId id, const wxChar *typestr)
wxPGId ReplaceProperty (const wxString &name, wxPGProperty *property)
wxPGId ReplaceProperty (wxPGId id, wxPGProperty *property)
void SetPropertyAttribute (const wxString &name, int attrid, wxVariant value, long argFlags=0)
void SetPropertyAttribute (wxPGId id, int attrid, wxVariant value, long argFlags=0)
void SetPropertyAttributes (const wxString &name, const wxString &attributes) const
void SetPropertyChoices (const wxString &name, wxPGChoices &choices)
void SetPropertyChoicesExclusive (const wxString &name)
void SetPropertyChoicesExclusive (wxPGId id)
void SetPropertyClientData (const wxString &name, wxPGProperty::ClientDataType clientData)
void SetPropertyClientData (wxPGId id, wxPGProperty::ClientDataType clientData)
void SetPropertyEditor (const wxString &name, const wxString &editorName)
void SetPropertyEditor (wxPGId id, const wxString &editorName)
void SetPropertyEditor (const wxString &name, const wxPGEditor *editor)
void SetPropertyEditor (wxPGId id, const wxPGEditor *editor)
void SetPropertyHelpString (const wxString &name, const wxString &helpString)
void SetPropertyHelpString (wxPGId id, const wxString &helpString)
void SetPropertyImage (const wxString &name, wxBitmap &bmp)
void SetPropertyImage (wxPGId id, wxBitmap &bmp)
bool SetPropertyMaxLength (const wxString &name, int maxLen)
bool SetPropertyMaxLength (wxPGId id, int maxLen)
bool SetPropertyPriority (const wxString &name, int priority)
bool SetPropertyPriority (wxPGId id, int priority)
void SetPropertyReadOnly (const wxString &name, bool readOnly=true)
void SetPropertyReadOnly (wxPGId id, bool readOnly=true)
void SetPropertyValidator (const wxString &name, const wxValidator &validator)
void SetPropertyValidator (wxPGId id, const wxValidator &validator)
void TogglePropertyPriority (const wxString &name)
void TogglePropertyPriority (wxPGId id)
virtual ~wxPropertyContainerMethods ()

Static Public Member Functions

wxPGPropertyCreatePropertyByClass (const wxString &classname, const wxString &label, const wxString &name)
wxPGPropertyCreatePropertyByType (const wxString &valuetype, const wxString &label, const wxString &name)
wxPGEditorGetEditorByName (const wxString &editorName)
wxString GetPropertyShortClassName (wxPGId id)
const wxArrayInt & GetPropertyValueAsArrayInt (wxPGId id)
const wxArrayString & GetPropertyValueAsArrayString (wxPGId id)
bool GetPropertyValueAsBool (wxPGId id)
wxDateTime GetPropertyValueAsDateTime (wxPGId id)
double GetPropertyValueAsDouble (wxPGId id)
int GetPropertyValueAsInt (wxPGId id)
long GetPropertyValueAsLong (wxPGId id)
const wxLongLong & GetPropertyValueAsLongLong (wxPGId id)
const wxPoint & GetPropertyValueAsPoint (wxPGId id)
const wxSize & GetPropertyValueAsSize (wxPGId id)
wxString GetPropertyValueAsString (wxPGId id)
const wxULongLong & GetPropertyValueAsULongLong (wxPGId id)
void * GetPropertyValueAsVoidPtr (wxPGId id)
const wxObject * GetPropertyValueAsWxObjectPtr (wxPGId id)
wxPGValueTypeGetValueType (const wxString &type)
void InitAllTypeHandlers ()
bool IsPropertyExpanded (wxPGId id)
bool IsPropertyKindOf (wxPGId id, wxPGPropertyClassInfo &info)
void RegisterAdditionalEditors ()
void RegisterAdvancedPropertyClasses ()
bool RegisterPropertyClass (const wxChar *name, wxPGPropertyClassInfo *classinfo)
void SetBoolChoices (const wxChar *true_choice, const wxChar *false_choice)
void SetPropertyAttributes (wxPGId id, const wxString &attributes)
void SetPropertyChoices (wxPGId id, wxPGChoices &choices)

Protected Member Functions

virtual wxPGId DoGetPropertyByName (const wxString &name) const
virtual void RefreshProperty (wxPGProperty *p)=0

Static Protected Member Functions

void DoSetPropertyAttribute (wxPGId id, int attrid, wxVariant &value, long argFlags)

Protected Attributes

wxString m_emptyString
wxPropertyGridStatem_pState

Detailed Description

In order to have most same base methods, both wxPropertyGrid and wxPropertyGridManager must derive from this.


Constructor & Destructor Documentation

virtual wxPropertyContainerMethods::~wxPropertyContainerMethods  )  [inline, virtual]
 

Destructor.


Member Function Documentation

void wxPropertyContainerMethods::AddPropertyChoice wxPGId  id,
const wxString &  label,
int  value = INT_MAX
 

Adds choice to a property that can accept one.

Remarks:
  • If you need to make sure that you modify only the set of choices of a single property (and not also choices of other properties with initially identical set), call wxPropertyGrid::SetPropertyChoicesPrivate.
  • This usually only works for wxEnumProperty and derivatives (wxFlagsProperty can get accept new items but its items may not get updated).

void wxPropertyContainerMethods::BeginAddChildren wxPGId  id  ) 
 

Inorder to add new items into a property with fixed children (for instance, wxFlagsProperty), you need to call this method.

After populating has been finished, you need to call EndAddChildren.

wxPGProperty* wxPropertyContainerMethods::CreatePropertyByClass const wxString &  classname,
const wxString &  label,
const wxString &  name
[static]
 

Constructs a property.

Class used is given as the first string argument. It may be either normal property class name, such as "wxIntProperty" or a short one such as "Int".

wxPGProperty* wxPropertyContainerMethods::CreatePropertyByType const wxString &  valuetype,
const wxString &  label,
const wxString &  name
[static]
 

Constructs a property.

Value type name used is given as the first string argument. It may be "string", "long", etc. Any value returned by wxVariant::GetType fits there.

Otherwise, this is similar as CreatePropertyByClass.

Remarks:
Cannot generate property category.

void wxPropertyContainerMethods::Delete const wxString &  name  )  [inline]
 

Deletes a property by name.

void wxPropertyContainerMethods::Delete wxPGId  id  ) 
 

Deletes a property by id.

If category is deleted, all children are automatically deleted as well.

void wxPropertyContainerMethods::DeletePropertyChoice wxPGId  id,
int  index
 

Deletes choice from a property.

If selected item is deleted, then the value is set to unspecified.

See AddPropertyChoice for more details.

void wxPropertyContainerMethods::EndAddChildren wxPGId  id  ) 
 

Called after population of property with fixed children has finished.

wxPGId wxPropertyContainerMethods::GetFirstChild wxPGId  id  )  [inline]
 

Returns id of first child of given property.

Remarks:
Does not return sub-properties!

wxPGId wxPropertyContainerMethods::GetNextSibling wxPGId  id  )  [inline]
 

Returns next item under the same parent.

wxString wxPropertyContainerMethods::GetPropertyAttributes wxPGId  id,
unsigned int  flagmask = 0xFFFF
const [inline]
 

Returns comma-delimited string with property's attributes (both pseudo-attributes such as "Disabled" and "Modified" and real attributes such as "BoolUseCheckbox" - actual names may vary).

Parameters:
flagmask Combination of property flags that should be included (in addition to any other attributes). For example, to avoid adding Modified attribute use ~(wxPG_PROP_MODIFIED).
Remarks:
Atleast in 1.2.x and earlier this does not return complete list of attributes (for example, no floating point precision) and some attributes have generic names (such as "Special1" instead of "UseCheckbox" etc)

wxPGId wxPropertyContainerMethods::GetPropertyByName const wxString &  name,
const wxString &  subname
const
 

Returns id of a sub-property 'subname' of property 'name'.

Same as calling GetPropertyByNameI(wxT("name.subname")), albeit slightly faster.

wxPGId wxPropertyContainerMethods::GetPropertyByName const wxString &  name  )  const
 

Returns id of property with given name (case-sensitive).

If there is no property with such name, returned property id is invalid ( i.e. it will return false with IsOk method).

Remarks:
  • Sub-properties (i.e. properties which have parent that is not category or root) can not be accessed globally by their name. Instead, use "<property>.<subproperty>" in place of "<subproperty>".

wxPGChoices& wxPropertyContainerMethods::GetPropertyChoices wxPGId  id  ) 
 

Returns writable reference to property's list of choices (and relevant values).

If property does not have any choices, will return reference to an invalid set of choices that will return false on IsOk call.

const wxChar* wxPropertyContainerMethods::GetPropertyClassName const wxString &  name  )  const [inline]
 

Gets name of property's constructor function.

const wxChar* wxPropertyContainerMethods::GetPropertyClassName wxPGId  id  )  const [inline]
 

Gets name of property's constructor function.

wxPGProperty::ClientDataType wxPropertyContainerMethods::GetPropertyClientData const wxString &  name  )  const [inline]
 

Returns client data (void*) of a property.

wxPGProperty::ClientDataType wxPropertyContainerMethods::GetPropertyClientData wxPGId  id  )  const [inline]
 

Returns client data (void*) of a property.

const wxPGEditor* wxPropertyContainerMethods::GetPropertyEditor wxPGId  id  )  const [inline]
 

Returns property's editor.

wxString wxPropertyContainerMethods::GetPropertyHelpString const wxString &  name  )  const [inline]
 

Returns help string associated with a property.

wxString wxPropertyContainerMethods::GetPropertyHelpString wxPGId  id  )  const [inline]
 

Returns help string associated with a property.

wxBitmap* wxPropertyContainerMethods::GetPropertyImage wxPGId  id  )  const [inline]
 

Returns property's custom value image (NULL of none).

unsigned int wxPropertyContainerMethods::GetPropertyIndex const wxString &  name  )  [inline]
 

Returns property's position under its parent.

unsigned int wxPropertyContainerMethods::GetPropertyIndex wxPGId  id  )  [inline]
 

Returns property's position under its parent.

const wxString& wxPropertyContainerMethods::GetPropertyLabel wxPGId  id  )  [inline]
 

Returns label of a property.

const wxString& wxPropertyContainerMethods::GetPropertyName wxPGId  id  )  [inline]
 

Returns name of a property.

Note that obviously there is no name-version of this member function.

wxPGId wxPropertyContainerMethods::GetPropertyParent const wxString &  name  )  [inline]
 

Returns parent item of a property.

wxPGId wxPropertyContainerMethods::GetPropertyParent wxPGId  id  )  [inline]
 

Returns parent item of a property.

int wxPropertyContainerMethods::GetPropertyPriority const wxString &  name  )  [inline]
 

Returns priority of a property (wxPG_HIGH or wxPG_LOW).

int wxPropertyContainerMethods::GetPropertyPriority wxPGId  id  )  [inline]
 

Returns priority of a property (wxPG_HIGH or wxPG_LOW).

wxPGProperty* wxPropertyContainerMethods::GetPropertyPtr const wxString &  name  )  const [inline]
 

Returns pointer to a property.

wxPGProperty* wxPropertyContainerMethods::GetPropertyPtr wxPGId  id  )  const [inline]
 

Returns pointer to a property.

wxString wxPropertyContainerMethods::GetPropertyShortClassName wxPGId  id  )  [static]
 

Returns short name for property's class.

For example, "wxPropertyCategory" translates to "Category" and "wxIntProperty" to "Int".

wxValidator* wxPropertyContainerMethods::GetPropertyValidator wxPGId  id  )  [inline]
 

Returns validator of a property as a reference, which you can pass to any number of SetPropertyValidator.

wxVariant wxPropertyContainerMethods::GetPropertyValue const wxString &  name  )  [inline]
 

Returns value as wxVariant.

To get wxObject pointer from it, you will have to use WX_PG_VARIANT_TO_WXOBJECT(VARIANT,CLASSNAME) macro.

If property value is unspecified, Null variant is returned.

wxVariant wxPropertyContainerMethods::GetPropertyValue wxPGId  id  )  [inline]
 

Returns value as wxVariant.

To get wxObject pointer from it, you will have to use WX_PG_VARIANT_TO_WXOBJECT(VARIANT,CLASSNAME) macro.

If property value is unspecified, Null variant is returned.

const wxPGValueType* wxPropertyContainerMethods::GetPropertyValueType wxPGId  id  )  [inline]
 

Returns a wxPGValueType class instance that describes the property's data type.

size_t wxPropertyContainerMethods::GetPVTI wxPGId  id  )  [inline]
 

Returns property value type identifier.

wxString wxPropertyContainerMethods::GetPVTN wxPGId  id  )  [inline]
 

Returns property value type name.

wxPGValueType* wxPropertyContainerMethods::GetValueType const wxString &  type  )  [static]
 

Returns value type class instance for given type name.

bool wxPropertyContainerMethods::HideProperty wxPGId  id,
bool  hide = true
 

Hides or reveals a property.

Parameters:
hide If true, hides property, otherwise reveals it.
Remarks:
Hiding properties is not compatible with priority system. Using both at the same time will yield unpredictable results.

void wxPropertyContainerMethods::InitAllTypeHandlers  )  [static]
 

Initializes *all* property types.

Causes references to most object files in the library, so calling this may cause significant increase in executable size when linking with static library.

Reimplemented in wxPropertyGridManager.

void wxPropertyContainerMethods::InsertPropertyChoice wxPGId  id,
const wxString &  label,
int  index,
int  value = INT_MAX
 

Inserts choice to a property that can accept one.

See AddPropertyChoice for more details.

bool wxPropertyContainerMethods::IsModified wxPGId  id  )  const [inline]
 

Returns true if property has been modified after value set or modify flag clear by software.

NOTE: Try to use IsPropertyModified instead.

bool wxPropertyContainerMethods::IsPropertyCategory wxPGId  id  )  const [inline]
 

Returns true if property is a category.

bool wxPropertyContainerMethods::IsPropertyEnabled const wxString &  name  )  [inline]
 

Returns true if property is enabled.

bool wxPropertyContainerMethods::IsPropertyEnabled wxPGId  id  )  const [inline]
 

Returns true if property is enabled.

bool wxPropertyContainerMethods::IsPropertyExpanded wxPGId  id  )  [static]
 

Returns true if given property is expanded.

Naturally, always returns false for properties that cannot be expanded.

bool wxPropertyContainerMethods::IsPropertyKindOf wxPGId  id,
wxPGPropertyClassInfo info
[inline, static]
 

Returns true if property is of certain type.

Parameters:
info Preferably use WX_PG_CLASSINFO(PROPERTYNAME). Alternative is PROPERTYNAMEClassInfo.

bool wxPropertyContainerMethods::IsPropertyModified wxPGId  id  )  const [inline]
 

Returns true if property has been modified after value set or modify flag clear by software.

bool wxPropertyContainerMethods::IsPropertyShown const wxString &  name  )  [inline]
 

Returns true if property is shown (ie.

hideproperty with true not called for it).

bool wxPropertyContainerMethods::IsPropertyShown wxPGId  id  )  const [inline]
 

Returns true if property is shown (ie.

hideproperty with true not called for it).

bool wxPropertyContainerMethods::IsPropertyUnspecified wxPGId  id  )  const [inline]
 

Returns true if property value is set to unspecified.

bool wxPropertyContainerMethods::IsPropertyValueType const wxString &  name,
const wxClassInfo *  classinfo
[inline]
 

Returns true if property's value type has same name as a class.

bool wxPropertyContainerMethods::IsPropertyValueType const wxString &  name,
const wxPGValueType valuetype
[inline]
 

Returns true if property's value type is valuetype.

bool wxPropertyContainerMethods::IsPropertyValueType const wxString &  name,
const wxChar *  typestr
[inline]
 

Returns true if property's value type has name typestr.

bool wxPropertyContainerMethods::IsPropertyValueType wxPGId  id,
const wxClassInfo *  classinfo
[inline]
 

Returns true if property's value type has same name as a class.

bool wxPropertyContainerMethods::IsPropertyValueType wxPGId  id,
const wxPGValueType valuetype
[inline]
 

Returns true if property's value type is valuetype.

bool wxPropertyContainerMethods::IsPropertyValueType wxPGId  id,
const wxChar *  typestr
[inline]
 

Returns true if property's value type has name typestr.

void wxPropertyContainerMethods::RegisterAdditionalEditors  )  [static]
 

Initializes additional property editors (SpinCtrl etc.).

Causes references to most object files in the library, so calling this may cause significant increase in executable size when linking with static library.

void wxPropertyContainerMethods::RegisterAdvancedPropertyClasses  )  [static]
 

Basic property classes are registered by the default, but this registers advanced ones as well.

bool wxPropertyContainerMethods::RegisterPropertyClass const wxChar *  name,
wxPGPropertyClassInfo classinfo
[static]
 

Registers property class info with specific name.

Preferably use wxPGRegisterPropertyClass(PROPERTYNAME) macro.

wxPGId wxPropertyContainerMethods::ReplaceProperty wxPGId  id,
wxPGProperty property
 

Replaces property with id with newly created property.

For example, this code replaces existing property named "Flags" with one that will have different set of items:

pg->ReplaceProperty(wxT("Flags"), wxFlagsProperty(wxT("Flags"),wxPG_LABEL,newItems))
For more info, see wxPropertyGrid::Insert.

void wxPropertyContainerMethods::SetBoolChoices const wxChar *  true_choice,
const wxChar *  false_choice
[static]
 

Lets user to set the strings listed in the choice dropdown of a wxBoolProperty.

Defaults are "True" and "False", so changing them to, say, "Yes" and "No" may be useful in some less technical applications.

void wxPropertyContainerMethods::SetPropertyAttribute wxPGId  id,
int  attrid,
wxVariant  value,
long  argFlags = 0
[inline]
 

Sets an attribute of a property.

Ids and relevants values are totally specific to property classes and may affect either the given instance or all instances of that class. See wxPropertyGrid Property Attribute Identifiers for list of built-in attributes.

Parameters:
argFlags Optional. Use wxPG_RECURSE to set the attribute to child properties as well.
Remarks:
wxVariant doesn't have int constructor (as of 2.5.4), so you will need to cast int values (including most numeral constants) to long.

void wxPropertyContainerMethods::SetPropertyAttributes wxPGId  id,
const wxString &  attributes
[inline, static]
 

Sets attributes from a string generated by GetPropertyAttributes.

Remarks:
Performance may not be top-notch.

void wxPropertyContainerMethods::SetPropertyChoices const wxString &  name,
wxPGChoices choices
[inline]
 

Set choices of a property to specified set of labels and values.

void wxPropertyContainerMethods::SetPropertyChoices wxPGId  id,
wxPGChoices choices
[inline, static]
 

Set choices of a property to specified set of labels and values.

void wxPropertyContainerMethods::SetPropertyChoicesExclusive wxPGId  id  )  [inline]
 

If property's set of choices is shared, then calling this method converts it to private.

void wxPropertyContainerMethods::SetPropertyClientData const wxString &  name,
wxPGProperty::ClientDataType  clientData
[inline]
 

Sets client data (void*) of a property.

Remarks:
This untyped client data has to be deleted manually.

void wxPropertyContainerMethods::SetPropertyClientData wxPGId  id,
wxPGProperty::ClientDataType  clientData
[inline]
 

Sets client data (void*) of a property.

Remarks:
This untyped client data has to be deleted manually.

void wxPropertyContainerMethods::SetPropertyEditor wxPGId  id,
const wxString &  editorName
[inline]
 

Sets editor control of a property.

As editor argument, use editor name string, such as wxT("TextCtrl") or wxT("Choice").

void wxPropertyContainerMethods::SetPropertyEditor wxPGId  id,
const wxPGEditor editor
[inline]
 

Sets editor control of a property.

As editor argument, use wxPG_EDITOR(EditorName), where basic built-in editor names are TextCtrl, Choice, ComboBox, CheckBox, TextCtrlAndButton, and ChoiceAndButton. Additional editors include SpinCtrl and DatePickerCtrl, which also require wxPropertyGrid::RegisterAdditionalEditors() call prior using.

void wxPropertyContainerMethods::SetPropertyHelpString wxPGId  id,
const wxString &  helpString
[inline]
 

Associates the help string with property.

Remarks:
By default, text is shown either in the manager's "description" text box or in the status bar. If extra window style wxPG_EX_HELP_AS_TOOLTIPS is used, then the text will appear as a tooltip.

void wxPropertyContainerMethods::SetPropertyImage wxPGId  id,
wxBitmap &  bmp
[inline]
 

Set wxBitmap in front of the value.

Remarks:

bool wxPropertyContainerMethods::SetPropertyMaxLength const wxString &  name,
int  maxLen
[inline]
 

Sets max length of property's text.

bool wxPropertyContainerMethods::SetPropertyMaxLength wxPGId  id,
int  maxLen
 

Sets max length of property's text.

bool wxPropertyContainerMethods::SetPropertyPriority const wxString &  name,
int  priority
[inline]
 

Property is to be hidden/shown when hider button is toggled or when wxPropertyGrid::Compact is called.

bool wxPropertyContainerMethods::SetPropertyPriority wxPGId  id,
int  priority
 

Property is to be hidden/shown when hider button is toggled or when wxPropertyGrid::Compact is called.

void wxPropertyContainerMethods::SetPropertyReadOnly const wxString &  name,
bool  readOnly = true
[inline]
 

Sets property as read-only.

It's value cannot be changed by the user, but the editor may still be created for copying purposes.

void wxPropertyContainerMethods::SetPropertyReadOnly wxPGId  id,
bool  readOnly = true
[inline]
 

Sets property as read-only.

It's value cannot be changed by the user, but the editor may still be created for copying purposes.

void wxPropertyContainerMethods::SetPropertyValidator wxPGId  id,
const wxValidator &  validator
[inline]
 

Sets validator of a property.

For example

// Allow property's value range from -100 to 100 wxIntPropertyValidator validator(-100,100); wxPGId id = pg->Append( wxIntProperty(wxT("Value 1",wxPG_LABEL,0)) ); pg->SetPropertyValidator( id, validator );

void wxPropertyContainerMethods::TogglePropertyPriority const wxString &  name  )  [inline]
 

Toggles priority of a property between wxPG_HIGH and wxPG_LOW.

void wxPropertyContainerMethods::TogglePropertyPriority wxPGId  id  )  [inline]
 

Toggles priority of a property between wxPG_HIGH and wxPG_LOW.


The documentation for this class was generated from the following file:
Generated on Mon Oct 29 16:56:24 2007 for wxPropertyGrid by doxygen 1.3.6