Update wxPG documentation to get rid of doxygen warnings

This commit is contained in:
Artur Wieczorek
2019-05-26 17:21:51 +02:00
parent 58fdf77c9b
commit 1943a9f38d
5 changed files with 175 additions and 73 deletions

View File

@@ -136,12 +136,21 @@ public:
Default implementation sets foreground colour, background colour, Default implementation sets foreground colour, background colour,
font, plus text for wxTextCtrl and wxComboCtrl. font, plus text for wxTextCtrl and wxComboCtrl.
@param pg
Property grid to which the edited property belongs.
@param property
Edited property to which the editor control belongs.
@param ctrl
Editor control.
@param appearance @param appearance
New appearance to be applied. New appearance to be applied.
@param oldAppearance @param oldAppearance
Previously applied appearance. Used to detect which control Previously applied appearance. Used to detect which control
attributes need to be changed (e.g. so we onlychange background attributes need to be changed (e.g. so we only change background
colour if really needed). colour if really needed).
@param unspecified @param unspecified

View File

@@ -27,7 +27,7 @@
wxPropertyGridPage receives events emitted by its wxPropertyGridManager, but wxPropertyGridPage receives events emitted by its wxPropertyGridManager, but
only those events that are specific to that page. If wxPropertyGridPage:: only those events that are specific to that page. If wxPropertyGridPage::
IsHandlingAllEvents returns false, then unhandled events are sent to the IsHandlingAllEvents returns @false, then unhandled events are sent to the
manager's parent, as usual. manager's parent, as usual.
See @ref propgrid_event_handling "wxPropertyGrid Event Handling" See @ref propgrid_event_handling "wxPropertyGrid Event Handling"
@@ -223,7 +223,7 @@ public:
/** /**
The default constructor. The styles to be used are styles valid for The default constructor. The styles to be used are styles valid for
the wxWindow. the wxWindow.
@see @link wndflags Additional Window Styles @endlink @see @ref propgrid_window_styles
*/ */
wxPropertyGridManager( wxWindow *parent, wxWindowID id = wxID_ANY, wxPropertyGridManager( wxWindow *parent, wxWindowID id = wxID_ANY,
const wxPoint& pos = wxDefaultPosition, const wxPoint& pos = wxDefaultPosition,
@@ -249,7 +249,7 @@ public:
@param pageObj @param pageObj
wxPropertyGridPage instance. Manager will take ownership of this wxPropertyGridPage instance. Manager will take ownership of this
object. NULL indicates that a default page instance should be created. object. @NULL indicates that a default page instance should be created.
@return Returns pointer to created property grid page. @return Returns pointer to created property grid page.
@@ -431,7 +431,7 @@ public:
bool IsPageModified( size_t index ) const; bool IsPageModified( size_t index ) const;
/** /**
Returns true if property is selected. Since selection is page Returns @true if property is selected. Since selection is page
based, this function checks every page in the manager. based, this function checks every page in the manager.
*/ */
virtual bool IsPropertySelected( wxPGPropArg id ) const; virtual bool IsPropertySelected( wxPGPropArg id ) const;
@@ -538,7 +538,7 @@ public:
Show or hide the property grid header control. It is hidden Show or hide the property grid header control. It is hidden
by the default. by the default.
@remarks Grid may look better if you use wxPG_NO_INTERNAL_BORDER @remarks Grid may look better if you use ::wxPG_NO_INTERNAL_BORDER
window style when showing a header. window style when showing a header.
*/ */
void ShowHeader(bool show = true); void ShowHeader(bool show = true);

View File

@@ -923,9 +923,9 @@ public:
Text to be translated into variant. Text to be translated into variant.
@param argFlags @param argFlags
If wxPG_FULL_VALUE is set, returns complete, storable value instead If ::wxPG_FULL_VALUE is set, returns complete, storable value instead
of displayable one (they may be different). of displayable one (they may be different).
If wxPG_COMPOSITE_FRAGMENT is set, text is interpreted as a part of If ::wxPG_COMPOSITE_FRAGMENT is set, text is interpreted as a part of
composite property string value (as generated by ValueToString() composite property string value (as generated by ValueToString()
called with this same flag). called with this same flag).
@@ -950,7 +950,7 @@ public:
@param number @param number
Integer to be translated into variant. Integer to be translated into variant.
@param argFlags @param argFlags
If wxPG_FULL_VALUE is set, returns complete, storable value instead If ::wxPG_FULL_VALUE is set, returns complete, storable value instead
of displayable one. of displayable one.
@return Returns @true if resulting wxVariant value was different. @return Returns @true if resulting wxVariant value was different.
@@ -975,10 +975,10 @@ public:
Value to be converted. Value to be converted.
@param argFlags @param argFlags
If 0 (default value), then displayed string is returned. If 0 (default value), then displayed string is returned.
If wxPG_FULL_VALUE is set, returns complete, storable string value If ::wxPG_FULL_VALUE is set, returns complete, storable string value
instead of displayable. If wxPG_EDITABLE_VALUE is set, returns instead of displayable. If ::wxPG_EDITABLE_VALUE is set, returns
string value that must be editable in textctrl. string value that must be editable in textctrl.
If wxPG_COMPOSITE_FRAGMENT is set, returns text that is appropriate to If ::wxPG_COMPOSITE_FRAGMENT is set, returns text that is appropriate to
display as a part of string property's composite text representation. display as a part of string property's composite text representation.
@remarks Default implementation calls GenerateComposedValue(). @remarks Default implementation calls GenerateComposedValue().
@@ -992,12 +992,12 @@ public:
@param text @param text
String to get the value from. String to get the value from.
@param flags @param flags
If @c wxPG_FULL_VALUE is set, the function sets complete, storable If ::wxPG_FULL_VALUE is set, the function sets complete, storable
value instead of displayable one (they may be different). value instead of displayable one (they may be different).
@c wxPG_PROGRAMMATIC_VALUE flag is used to indicate that value is ::wxPG_PROGRAMMATIC_VALUE flag is used to indicate that value is
being set programmatically (i.e. operation is not caused by user being set programmatically (i.e. operation is not caused by user
input). input).
If @c wxPG_REPORT_ERROR is set, a special action should be If ::wxPG_REPORT_ERROR is set, a special action should be
performed if string couldn't have been successfully converted performed if string couldn't have been successfully converted
to the valid value (e.g. a special value can be set in this case). to the valid value (e.g. a special value can be set in this case).
@@ -1012,7 +1012,7 @@ public:
@param value @param value
Int to get the value from. Int to get the value from.
@param flags @param flags
If has wxPG_FULL_VALUE, then the value given is a actual value and not an index. If has ::wxPG_FULL_VALUE, then the value given is a actual value and not an index.
@return @true if value was changed. @return @true if value was changed.
*/ */
@@ -1029,7 +1029,7 @@ public:
@remarks @remarks
- Default behaviour is to return wxSize(0,0), which means no image. - Default behaviour is to return wxSize(0,0), which means no image.
- Default image width or height is indicated with dimension -1. - Default image width or height is indicated with dimension -1.
- You can also return wxPG_DEFAULT_IMAGE_SIZE which equals wxDefaultSize. - You can also return ::wxPG_DEFAULT_IMAGE_SIZE which equals wxDefaultSize.
*/ */
virtual wxSize OnMeasureImage( int item = -1 ) const; virtual wxSize OnMeasureImage( int item = -1 ) const;
@@ -1161,7 +1161,7 @@ public:
than row height). than row height).
NOTE: Following applies when OnMeasureImage() returns a "flexible" height ( NOTE: Following applies when OnMeasureImage() returns a "flexible" height (
using wxPG_FLEXIBLE_SIZE(W,H) macro), which implies variable height items: using @c wxPG_FLEXIBLE_SIZE(W,H) macro), which implies variable height items:
If (rect.x+rect.width) is < 0, then this is a measure item call, which If (rect.x+rect.width) is < 0, then this is a measure item call, which
means that dc is invalid and only thing that should be done is to set means that dc is invalid and only thing that should be done is to set
paintdata.m_drawnHeight to the height of the image of item at index paintdata.m_drawnHeight to the height of the image of item at index
@@ -1295,7 +1295,7 @@ public:
Adds a private child property. If you use this instead of Adds a private child property. If you use this instead of
wxPropertyGridInterface::Insert() or wxPropertyGridInterface::Insert() or
wxPropertyGridInterface::AppendIn(), then property's parental wxPropertyGridInterface::AppendIn(), then property's parental
type will automatically be set up to wxPG_PROP_AGGREGATE. In other type will automatically be set up to ::wxPG_PROP_AGGREGATE. In other
words, all properties of this property will become private. words, all properties of this property will become private.
*/ */
void AddPrivateChild( wxPGProperty* prop ); void AddPrivateChild( wxPGProperty* prop );
@@ -1340,7 +1340,8 @@ public:
@remarks Setting a property flag never has any side-effect, and is @remarks Setting a property flag never has any side-effect, and is
intended almost exclusively for internal use. So, for intended almost exclusively for internal use. So, for
example, if you want to disable a property, call example, if you want to disable a property, call
Enable(false) instead of setting wxPG_PROP_DISABLED flag. @code Enable(false) @endcode instead of setting
::wxPG_PROP_DISABLED flag.
@see HasFlag(), GetFlags() @see HasFlag(), GetFlags()
*/ */
@@ -1596,6 +1597,9 @@ public:
/** /**
Returns (direct) child property with given name (or @NULL if not found). Returns (direct) child property with given name (or @NULL if not found).
@param name
Name of the child property to look for.
*/ */
wxPGProperty* GetPropertyByName( const wxString& name ) const; wxPGProperty* GetPropertyByName( const wxString& name ) const;
@@ -1617,10 +1621,10 @@ public:
@param argFlags @param argFlags
If 0 (default value), then displayed string is returned. If 0 (default value), then displayed string is returned.
If wxPG_FULL_VALUE is set, returns complete, storable string value If ::wxPG_FULL_VALUE is set, returns complete, storable string value
instead of displayable. If wxPG_EDITABLE_VALUE is set, returns instead of displayable. If ::wxPG_EDITABLE_VALUE is set, returns
string value that must be editable in textctrl. If string value that must be editable in textctrl. If
wxPG_COMPOSITE_FRAGMENT is set, returns text that is appropriate to ::wxPG_COMPOSITE_FRAGMENT is set, returns text that is appropriate to
display as a part of string property's composite text display as a part of string property's composite text
representation. representation.
@@ -1688,7 +1692,8 @@ public:
@true for hide, @false for reveal. @true for hide, @false for reveal.
@param flags @param flags
By default changes are applied recursively. Set this parameter wxPG_DONT_RECURSE to prevent this. By default changes are applied recursively. Set this parameter to
::wxPG_DONT_RECURSE to prevent this.
*/ */
bool Hide( bool hide, int flags = wxPG_RECURSE ); bool Hide( bool hide, int flags = wxPG_RECURSE );
@@ -1759,7 +1764,7 @@ public:
bool IsSomeParent( wxPGProperty* candidateParent ) const; bool IsSomeParent( wxPGProperty* candidateParent ) const;
/** /**
Returns true if property has editable wxTextCtrl when selected. Returns @true if property has editable wxTextCtrl when selected.
@remarks Although disabled properties do not displayed editor, they still @remarks Although disabled properties do not displayed editor, they still
return @true here as being disabled is considered a temporary return @true here as being disabled is considered a temporary
@@ -1774,12 +1779,12 @@ public:
bool IsValueUnspecified() const; bool IsValueUnspecified() const;
/** /**
Returns true if all parents expanded. Returns @true if all parents expanded.
*/ */
bool IsVisible() const; bool IsVisible() const;
/** /**
Returns child property at index i. Returns child property at index @a i.
*/ */
wxPGProperty* Item( unsigned int i ) const; wxPGProperty* Item( unsigned int i ) const;
@@ -1790,7 +1795,7 @@ public:
/** /**
If property's editor is created this forces its recreation. If property's editor is created this forces its recreation.
Useful in SetAttribute etc. Returns true if actually did anything. Useful in SetAttribute etc. Returns @true if actually did anything.
*/ */
bool RecreateEditor(); bool RecreateEditor();
@@ -1834,7 +1839,7 @@ public:
Background colour to use. Background colour to use.
@param flags @param flags
Default is wxPG_RECURSE which causes colour to be set recursively. Default is ::wxPG_RECURSE which causes colour to be set recursively.
Omit this flag to only set colour for the property in question Omit this flag to only set colour for the property in question
and not any of its children. and not any of its children.
@@ -1962,9 +1967,9 @@ public:
Changes what sort of parent this property is for its children. Changes what sort of parent this property is for its children.
@param flag @param flag
Use one of the following values: wxPG_PROP_MISC_PARENT (for generic Use one of the following values: ::wxPG_PROP_MISC_PARENT (for generic
parents), wxPG_PROP_CATEGORY (for categories), or parents), ::wxPG_PROP_CATEGORY (for categories), or
wxPG_PROP_AGGREGATE (for derived property classes with private ::wxPG_PROP_AGGREGATE (for derived property classes with private
children). children).
@remarks You generally do not need to call this function. @remarks You generally do not need to call this function.
@@ -1978,7 +1983,7 @@ public:
Text colour to use. Text colour to use.
@param flags @param flags
Default is wxPG_RECURSE which causes colour to be set recursively. Default is ::wxPG_RECURSE which causes colour to be set recursively.
Omit this flag to only set colour for the property in question Omit this flag to only set colour for the property in question
and not any of its children. and not any of its children.
@@ -1993,7 +1998,7 @@ public:
Sets property's default text and background colours. Sets property's default text and background colours.
@param flags @param flags
Default is wxPG_RECURSE which causes colours to be set recursively. Default is ::wxPG_RECURSE which causes colours to be set recursively.
Omit this flag to only set colours for the property in question Omit this flag to only set colours for the property in question
and not any of its children. and not any of its children.
@@ -2023,7 +2028,7 @@ public:
Pointer to list variant that contains child values. Used to indicate Pointer to list variant that contains child values. Used to indicate
which children should be marked as modified. Usually you just use @NULL. which children should be marked as modified. Usually you just use @NULL.
@param flags @param flags
wxPG_SETVAL_REFRESH_EDITOR is set by default, to refresh editor ::wxPG_SETVAL_REFRESH_EDITOR is set by default, to refresh editor
and redraw properties. and redraw properties.
*/ */
void SetValue( wxVariant value, wxVariant* pList = NULL, void SetValue( wxVariant value, wxVariant* pList = NULL,
@@ -2065,7 +2070,7 @@ public:
wxPGProperty* UpdateParentValues(); wxPGProperty* UpdateParentValues();
/** /**
Returns @true if containing grid uses wxPG_EX_AUTO_UNSPECIFIED_VALUES. Returns @true if containing grid uses ::wxPG_EX_AUTO_UNSPECIFIED_VALUES.
*/ */
bool UsesAutoUnspecified() const; bool UsesAutoUnspecified() const;
@@ -2116,6 +2121,9 @@ protected:
/** /**
Clear cells associated with property. Clear cells associated with property.
@param ignoreWithFlags
Cells will not be cleared for properties having these flags set.
@param recursively @param recursively
If @true, apply this operation recursively in child properties. If @true, apply this operation recursively in child properties.
*/ */
@@ -2129,11 +2137,14 @@ protected:
/** Returns (direct) child property with given name (or @NULL if not found), /** Returns (direct) child property with given name (or @NULL if not found),
with hint index. with hint index.
@param name
Name of the child property to look for.
@param hintIndex @param hintIndex
Start looking for the child at this index. Start looking for the child at this index.
@remarks @remarks
Does not support scope (i.e. Parent.Child notation). Does not support scope (i.e. Parent.Child notation).
*/ */
wxPGProperty* GetPropertyByNameWH( const wxString& name, wxPGProperty* GetPropertyByNameWH( const wxString& name,
unsigned int hintIndex ) const; unsigned int hintIndex ) const;
@@ -2147,7 +2158,7 @@ protected:
void Empty(); void Empty();
/** /**
Returns true if child property is selected. Returns @true if child property is selected.
*/ */
bool IsChildSelected( bool recursive = false ) const; bool IsChildSelected( bool recursive = false ) const;
}; };
@@ -2219,6 +2230,24 @@ public:
Returns @true if rendered something in the foreground (text or Returns @true if rendered something in the foreground (text or
bitmap). bitmap).
@param dc
wxDC to paint on.
@param rect
Box reserved for drawing.
@param propertyGrid
Property grid in which property is displayed.
@param property
Property to be rendered.
@param column
Property cell column.
@param item
Index of chosen item if combo popup is drawn, -1 otherwise.
@param flags @param flags
See @ref pgcellrenderer_render_flags "list of render flags". See @ref pgcellrenderer_render_flags "list of render flags".
*/ */
@@ -2261,14 +2290,25 @@ public:
wxPGProperty* property, wxPGProperty* property,
const wxPGEditor* editor ) const; const wxPGEditor* editor ) const;
/** Utility to render cell bitmap and set text colour plus bg brush /**
Utility to render cell bitmap and set text colour plus bg brush
colour. colour.
@param dc
wxDC to paint on.
@param rect
Box reserved for drawing.
@param cell
Cell information.
@param flags @param flags
See @ref pgcellrenderer_render_flags "list of render flags". See @ref pgcellrenderer_render_flags "list of render flags".
@return Returns image width, which, for instance, can be passed to @return
DrawText. Returns image width, which, for instance, can be passed to
DrawText().
*/ */
int PreDrawCell( wxDC& dc, int PreDrawCell( wxDC& dc,
const wxRect& rect, const wxRect& rect,
@@ -2279,6 +2319,15 @@ public:
Utility to be called after drawing is done, to revert whatever Utility to be called after drawing is done, to revert whatever
changes PreDrawCell() did. changes PreDrawCell() did.
@param dc
wxDC which was used to paint on.
@param propGrid
Property grid to which the cell belongs.
@param cell
Cell information.
@param flags @param flags
Same as those passed to PreDrawCell(). Same as those passed to PreDrawCell().
See @ref pgcellrenderer_render_flags "list of render flags". See @ref pgcellrenderer_render_flags "list of render flags".
@@ -2307,6 +2356,24 @@ public:
Returns @true if rendered something in the foreground (text or Returns @true if rendered something in the foreground (text or
bitmap. bitmap.
@param dc
wxDC to paint on.
@param rect
Box reserved for drawing.
@param propertyGrid
Property grid in which property is displayed.
@param property
Property to be rendered.
@param column
Property cell column.
@param item
Index of chosen item if combo popup is drawn, -1 otherwise.
@param flags @param flags
See @ref pgcellrenderer_render_flags "list of render flags". See @ref pgcellrenderer_render_flags "list of render flags".
*/ */
@@ -2352,7 +2419,7 @@ protected:
wxColour m_bgCol; wxColour m_bgCol;
wxFont m_font; wxFont m_font;
/** True if m_text is valid and specified. /** @true if m_text is valid and specified.
*/ */
bool m_hasValidText; bool m_hasValidText;
}; };
@@ -2696,7 +2763,7 @@ public:
/** /**
Returns array of values matching the given strings. Unmatching strings Returns array of values matching the given strings. Unmatching strings
result in wxPG_INVALID_VALUE entry in array. result in ::wxPG_INVALID_VALUE entry in array.
*/ */
wxArrayInt GetValuesForStrings( const wxArrayString& strings ) const; wxArrayInt GetValuesForStrings( const wxArrayString& strings ) const;

View File

@@ -582,7 +582,7 @@ public:
void AddActionTrigger( int action, int keycode, int modifiers = 0 ); void AddActionTrigger( int action, int keycode, int modifiers = 0 );
/** /**
Adds given property into selection. If wxPG_EX_MULTIPLE_SELECTION Adds given property into selection. If ::wxPG_EX_MULTIPLE_SELECTION
extra style is not used, then this has same effect as extra style is not used, then this has same effect as
calling SelectProperty(). calling SelectProperty().
@@ -591,7 +591,7 @@ public:
add category to selection, and also if you have category add category to selection, and also if you have category
selected, you cannot add other properties to selection. selected, you cannot add other properties to selection.
This member function will fail silently in these cases, This member function will fail silently in these cases,
even returning true. even returning @true.
*/ */
bool AddToSelection( wxPGPropArg id ); bool AddToSelection( wxPGPropArg id );
@@ -600,7 +600,7 @@ public:
wxGetTranslation() for following strings: wxEnumProperty list labels, wxGetTranslation() for following strings: wxEnumProperty list labels,
wxFlagsProperty child property labels. wxFlagsProperty child property labels.
Default is false. Default is @false.
*/ */
static void AutoGetTranslation( bool enable ); static void AutoGetTranslation( bool enable );
@@ -624,7 +624,7 @@ public:
SetPropertyValue() if you need the value to run through validation SetPropertyValue() if you need the value to run through validation
process, and also send the property change event. process, and also send the property change event.
@return Returns true if value was successfully changed. @return Returns @true if value was successfully changed.
*/ */
bool ChangePropertyValue( wxPGPropArg id, wxVariant newValue ); bool ChangePropertyValue( wxPGPropArg id, wxVariant newValue );
@@ -633,7 +633,7 @@ public:
@param enableAutoResizing @param enableAutoResizing
If @true, automatic column resizing is enabled (only applicable If @true, automatic column resizing is enabled (only applicable
if window style wxPG_SPLITTER_AUTO_CENTER is used). if window style ::wxPG_SPLITTER_AUTO_CENTER is used).
*/ */
void CenterSplitter( bool enableAutoResizing = false ); void CenterSplitter( bool enableAutoResizing = false );
@@ -687,7 +687,7 @@ public:
enable. enable.
@remarks This functions deselects selected property, if any. Validation @remarks This functions deselects selected property, if any. Validation
failure option wxPG_VFB_STAY_IN_PROPERTY is not respected, i.e. failure option ::wxPG_VFB_STAY_IN_PROPERTY is not respected, i.e.
selection is cleared even if editor had invalid value. selection is cleared even if editor had invalid value.
*/ */
bool EnableCategories( bool enable ); bool EnableCategories( bool enable );
@@ -716,7 +716,7 @@ public:
@return Minimum size for the grid to still display everything. @return Minimum size for the grid to still display everything.
@remarks Does not work well with wxPG_SPLITTER_AUTO_CENTER window style. @remarks Does not work well with ::wxPG_SPLITTER_AUTO_CENTER window style.
This function only works properly if grid size prior to call was This function only works properly if grid size prior to call was
already fairly large. already fairly large.
@@ -918,7 +918,7 @@ public:
wxPropertyGridHitTestResult HitTest( const wxPoint& pt ) const; wxPropertyGridHitTestResult HitTest( const wxPoint& pt ) const;
/** /**
Returns true if any property has been modified by the user. Returns @true if any property has been modified by the user.
*/ */
bool IsAnyModified() const; bool IsAnyModified() const;
@@ -928,7 +928,7 @@ public:
bool IsEditorFocused() const; bool IsEditorFocused() const;
/** /**
Returns true if updating is frozen (i.e. Freeze() called but not Returns @true if updating is frozen (i.e. Freeze() called but not
yet Thaw() ). yet Thaw() ).
*/ */
bool IsFrozen() const; bool IsFrozen() const;
@@ -997,7 +997,7 @@ public:
@param enableAutoResizing @param enableAutoResizing
If @true, automatic column resizing is enabled (only applicable If @true, automatic column resizing is enabled (only applicable
if window style wxPG_SPLITTER_AUTO_CENTER is used). if window style ::wxPG_SPLITTER_AUTO_CENTER is used).
@see wxPropertyGridInterface::SetColumnProportion() @see wxPropertyGridInterface::SetColumnProportion()
*/ */
@@ -1011,7 +1011,7 @@ public:
/** /**
Selects a property. Editor widget is automatically created, but Selects a property. Editor widget is automatically created, but
not focused unless focus is true. not focused unless focus is @true.
@param id @param id
Property to select (name or pointer). Property to select (name or pointer).
@@ -1231,10 +1231,15 @@ public:
virtual wxStatusBar* GetStatusBar(); virtual wxStatusBar* GetStatusBar();
/** Override to customize property validation failure behaviour. /** Override to customize property validation failure behaviour.
@param
property Property with entered an invalid value
@param invalidValue @param invalidValue
Value which failed in validation. Value which failed in validation.
@return @return
Return true if user is allowed to change to another property even Return @true if user is allowed to change to another property even
if current has invalid value. if current has invalid value.
*/ */
virtual bool DoOnValidationFailure( wxPGProperty* property, virtual bool DoOnValidationFailure( wxPGProperty* property,
@@ -1242,7 +1247,7 @@ public:
/** Override to customize resetting of property validation failure status. /** Override to customize resetting of property validation failure status.
@remarks @remarks
Property is guaranteed to have flag wxPG_PROP_INVALID_VALUE set. Property is guaranteed to have flag ::wxPG_PROP_INVALID_VALUE set.
*/ */
virtual void DoOnValidationFailureReset( wxPGProperty* property ); virtual void DoOnValidationFailureReset( wxPGProperty* property );
@@ -1283,7 +1288,7 @@ public:
wxVariant GetUncommittedPropertyValue(); wxVariant GetUncommittedPropertyValue();
/** /**
Returns true if editor's value was marked modified. Returns @true if editor's value was marked modified.
*/ */
bool IsEditorsValueModified() const; bool IsEditorsValueModified() const;
@@ -1294,7 +1299,7 @@ public:
/** /**
Call this from wxPGProperty::OnEvent() to cause property value to be Call this from wxPGProperty::OnEvent() to cause property value to be
changed after the function returns (with true as return value). changed after the function returns (with @true as return value).
ValueChangeInEvent() must be used if you wish the application to be ValueChangeInEvent() must be used if you wish the application to be
able to use wxEVT_PG_CHANGING to potentially veto the given value. able to use wxEVT_PG_CHANGING to potentially veto the given value.
*/ */
@@ -1307,7 +1312,7 @@ public:
if was value was changed using wxPGProperty::SetValueInEvent(), which if was value was changed using wxPGProperty::SetValueInEvent(), which
is usually used when a 'picker' dialog is displayed. If value was is usually used when a 'picker' dialog is displayed. If value was
written by "normal means" in wxPGProperty::StringToValue() or written by "normal means" in wxPGProperty::StringToValue() or
IntToValue(), then this function will return false (on the other hand, IntToValue(), then this function will return @false (on the other hand,
wxPGProperty::OnEvent() is not even called in those cases). wxPGProperty::OnEvent() is not even called in those cases).
*/ */
bool WasValueChangedInEvent() const; bool WasValueChangedInEvent() const;
@@ -1339,7 +1344,7 @@ public:
~wxPropertyGridEvent(); ~wxPropertyGridEvent();
/** /**
Returns true if you can veto the action that the event is signaling. Returns @true if you can veto the action that the event is signaling.
*/ */
bool CanVeto() const; bool CanVeto() const;
@@ -1419,14 +1424,14 @@ public:
/** /**
Sets custom failure message for this time only. Only applies if Sets custom failure message for this time only. Only applies if
wxPG_VFB_SHOW_MESSAGE is set in validation failure flags. ::wxPG_VFB_SHOW_MESSAGE is set in validation failure flags.
*/ */
void SetValidationFailureMessage( const wxString& message ); void SetValidationFailureMessage( const wxString& message );
/** /**
Call this from your event handler to veto action that the event is Call this from your event handler to veto action that the event is
signaling. You can only veto a shutdown if wxPropertyGridEvent::CanVeto() signaling. You can only veto a shutdown if wxPropertyGridEvent::CanVeto()
returns true. returns @true.
@remarks Currently only @c wxEVT_PG_CHANGING supports vetoing. @remarks Currently only @c wxEVT_PG_CHANGING supports vetoing.
*/ */
@@ -1479,8 +1484,21 @@ public:
/** /**
Appends a new property under bottommost parent. Appends a new property under bottommost parent.
@param propClass @param propClass
Property class as string. Property class as string.
@param propLabel
Property label.
@param propName
Property name.
@param propValue
Property value.
@param pChoices
Set of choices for the property (optional).
*/ */
wxPGProperty* Add( const wxString& propClass, wxPGProperty* Add( const wxString& propClass,
const wxString& propLabel, const wxString& propLabel,
@@ -1498,9 +1516,16 @@ public:
/** /**
Adds attribute to the bottommost property. Adds attribute to the bottommost property.
@param name
Attribute name.
@param type @param type
Allowed values: "string", (same as string), "int", "bool". Empty string Allowed values: @c "string", (same as string), @c "int", @c "bool".
mean autodetect. Empty string means autodetect.
@param value
Attribute value.
*/ */
bool AddAttribute( const wxString& name, bool AddAttribute( const wxString& name,
const wxString& type, const wxString& type,

View File

@@ -24,17 +24,17 @@
/** If property is supposed to have custom-painted image, then returning /** If property is supposed to have custom-painted image, then returning
this in OnMeasureImage() will usually be enough. this in wxPGProperty::OnMeasureImage() will usually be enough.
*/ */
#define wxPG_DEFAULT_IMAGE_SIZE wxSize(-1, -1) #define wxPG_DEFAULT_IMAGE_SIZE wxDefaultSize
/** This callback function is used for sorting properties. /** This callback function is used for sorting properties.
Call wxPropertyGrid::SetSortFunction() to set it. Call wxPropertyGrid::SetSortFunction() to set it.
Sort function should return a value greater than 0 if position of p1 is Sort function should return a value greater than 0 if position of @a p1 is
after p2. So, for instance, when comparing property names, you can use after @a p2. So, for instance, when comparing property names, you can use
following implementation: following implementation:
@code @code
@@ -52,8 +52,9 @@ typedef int (*wxPGSortCallback)(wxPropertyGrid* propGrid,
// ----------------------------------------------------------------------- // -----------------------------------------------------------------------
// Used to indicate wxPGChoices::Add etc that the value is actually not given /** Used to indicate wxPGChoices::Add() etc that the value is actually not given
// by the caller. by the caller.
*/
#define wxPG_INVALID_VALUE INT_MAX #define wxPG_INVALID_VALUE INT_MAX
// ----------------------------------------------------------------------- // -----------------------------------------------------------------------