Updated documentation to acknowledge the fact that properties can have identical labels, and that they must have non-empty name that is unique under parent
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55604 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
55f0bf1ff1
commit
258ccb95f5
@ -1028,12 +1028,16 @@ Few things to note:
|
||||
|
||||
@subsection namescope Property Name Scope
|
||||
|
||||
- All properties which parent is category or root have their names
|
||||
globally accessible.
|
||||
All properties which parent is category or root can be accessed
|
||||
directly by their base name (ie. name given for property in its constructor).
|
||||
Other properties can be accessed via "ParentsName.BaseName" notation,
|
||||
Naturally, all property names should be unique.
|
||||
|
||||
- Sub-properties (i.e. private child properties which have parent that is not category or
|
||||
root or non-aggregate property) can not be accessed globally by their name. Instead, use
|
||||
"<property>.<subproperty>".
|
||||
@subsection nonuniquelabels Non-unique Labels
|
||||
|
||||
It is possible to have properties with identical label under same parent.
|
||||
However, care must be taken to ensure that each property still has
|
||||
unique (base) name.
|
||||
|
||||
@subsection boolproperty wxBoolProperty
|
||||
|
||||
|
@ -1004,9 +1004,6 @@ public:
|
||||
}
|
||||
|
||||
/** Sets label of a property.
|
||||
@remarks
|
||||
This is the only way to set property's name. There is not
|
||||
wxPGProperty::SetLabel() method.
|
||||
*/
|
||||
void SetPropertyLabel( wxPGPropArg id, const wxString& newproplabel );
|
||||
|
||||
|
@ -1165,6 +1165,12 @@ public:
|
||||
m_helpString = helpString;
|
||||
}
|
||||
|
||||
/** Sets property's label.
|
||||
|
||||
@remarks
|
||||
- Properties under same parent may have same labels. However,
|
||||
property names must still remain unique.
|
||||
*/
|
||||
void SetLabel( const wxString& label ) { m_label = label; }
|
||||
|
||||
inline void SetName( const wxString& newName );
|
||||
|
@ -765,9 +765,10 @@ public:
|
||||
}
|
||||
|
||||
/** Sets label of a property.
|
||||
|
||||
@remarks
|
||||
This is the only way to set property's name. There is not
|
||||
wxPGProperty::SetLabel() method.
|
||||
- Properties under same parent may have same labels. However,
|
||||
property names must still remain unique.
|
||||
*/
|
||||
void SetPropertyLabel( wxPGPropArg id, const wxString& newproplabel );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user