]> git.saurik.com Git - wxWidgets.git/blob - interface/wx/propgrid/propgridiface.h
17fa4f2a3b925eddeadc276eb1628e002efc6c37
[wxWidgets.git] / interface / wx / propgrid / propgridiface.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: property.h
3 // Purpose: interface of wxPGProperty
4 // Author: wxWidgets team
5 // RCS-ID: $Id$
6 // Licence: wxWindows license
7 /////////////////////////////////////////////////////////////////////////////
8
9 // -----------------------------------------------------------------------
10
11 /**
12 @class wxPropertyGridInterface
13
14 Most of the shared property manipulation interface shared by wxPropertyGrid,
15 wxPropertyGridPage, and wxPropertyGridManager is defined in this class.
16
17 @remarks
18 - In separate wxPropertyGrid component this class was known as
19 wxPropertyContainerMethods.
20
21 - wxPropertyGridInterface's property operation member functions all accept
22 a special wxPGPropArg id argument, using which you can refer to properties
23 either by their pointer (for performance) or by their name (for conveniency).
24
25 @library{wxpropgrid}
26 @category{propgrid}
27 */
28 class WXDLLIMPEXP_PROPGRID wxPropertyGridInterface
29 {
30 public:
31
32 /** Destructor */
33 virtual ~wxPropertyGridInterface() { }
34
35 /**
36 Appends property to the list. wxPropertyGrid assumes ownership of the
37 object. Becomes child of most recently added category.
38
39 @remarks
40 - wxPropertyGrid takes the ownership of the property pointer.
41 - If appending a category with name identical to a category already in
42 the wxPropertyGrid, then newly created category is deleted, and most
43 recently added category (under which properties are appended) is set
44 to the one with same name. This allows easier adding of items to same
45 categories in multiple passes.
46 - Does not automatically redraw the control, so you may need to call
47 Refresh() when calling this function after control has been shown for
48 the first time.
49 */
50 wxPGProperty* Append( wxPGProperty* property );
51
52 /**
53 Same as Append(), but appends under given parent property.
54
55 @param id
56 Name or pointer to parent property.
57
58 @param newProperty
59 Property to be added.
60 */
61 wxPGProperty* AppendIn( wxPGPropArg id, wxPGProperty* newProperty );
62
63 /**
64 In order to add new items into a property with private children (for
65 instance, wxFlagsProperty), you need to call this method. After
66 populating has been finished, you need to call EndAddChildren().
67
68 @see EndAddChildren()
69 */
70 void BeginAddChildren( wxPGPropArg id );
71
72 /**
73 Deletes all properties.
74 */
75 virtual void Clear() = 0;
76
77 /**
78 Deselect current selection, if any.
79
80 @return Returns @true if success (ie. validator did not intercept).
81 */
82 bool ClearSelection();
83
84 /**
85 Resets modified status of all properties.
86 */
87 void ClearModifiedStatus();
88
89 /**
90 Collapses given category or property with children.
91
92 @return Returns @true if actually collapsed.
93 */
94 bool Collapse( wxPGPropArg id );
95
96 /**
97 Collapses all items that can be collapsed.
98
99 @return Returns @false if failed (may fail if value in active
100 editor cannot be validated).
101 */
102 bool CollapseAll();
103
104 /**
105 Changes value of a property, as if by user. Use this instead of
106 SetPropertyValue() if you need the value to run through validation
107 process, and also send the property change event.
108
109 @return Returns @true if value was successfully changed.
110 */
111 bool ChangePropertyValue( wxPGPropArg id, wxVariant newValue );
112
113 /**
114 Deletes a property.
115 */
116 void DeleteProperty( wxPGPropArg id );
117
118 /**
119 Disables a property.
120 */
121 bool DisableProperty( wxPGPropArg id );
122
123 /**
124 Returns true if all property grid data changes have been committed. Usually
125 only returns false if value in active editor has been invalidated by a
126 wxValidator.
127 */
128 bool EditorValidate();
129
130 /**
131 Enables or disables property.
132
133 @param id
134 Name or pointer to a property.
135
136 @param enable
137 If @false, property is disabled instead.
138 */
139 bool EnableProperty( wxPGPropArg id, bool enable = true );
140
141 /**
142 Called after population of property with fixed children has finished.
143
144 @see BeginAddChildren()
145 */
146 void EndAddChildren( wxPGPropArg id );
147
148 /**
149 Expands given category or property with children.
150
151 @return Returns @true if actually expanded.
152 */
153 bool Expand( wxPGPropArg id );
154
155 /**
156 Expands all items that can be expanded.
157 */
158 bool ExpandAll( bool expand = true );
159
160 /**
161 Returns list of expanded properties.
162 */
163 wxArrayPGProperty GetExpandedProperties() const;
164
165 /**
166 Returns id of first child of given property.
167
168 @remarks Does not return private children!
169 */
170 wxPGProperty* GetFirstChild( wxPGPropArg id );
171
172 //@{
173 /** Returns iterator class instance.
174
175 @param flags
176 See @ref propgrid_iterator_flags. Value wxPG_ITERATE_DEFAULT causes
177 iteration over everything except private child properties.
178
179 @param firstProp
180 Property to start iteration from. If NULL, then first child of root
181 is used.
182
183 @param startPos
184 Either wxTOP or wxBOTTOM. wxTOP will indicate that iterations start
185 from the first property from the top, and wxBOTTOM means that the
186 iteration will instead begin from bottommost valid item.
187
188 <b>wxPython Note:</b> Instead of ++ operator, use Next() method, and
189 instead of * operator, use GetProperty() method.
190 */
191 wxPropertyGridIterator GetIterator( int flags = wxPG_ITERATE_DEFAULT,
192 wxPGProperty* firstProp = NULL );
193 wxPropertyGridConstIterator GetIterator( int flags = wxPG_ITERATE_DEFAULT,
194 wxPGProperty* firstProp = NULL ) const;
195 wxPropertyGridIterator GetIterator( int flags, int startPos );
196 wxPropertyGridConstIterator GetIterator( int flags, int startPos ) const;
197 //@}
198
199 /**
200 Returns id of first item that matches given criteria.
201
202 @param flags
203 See @ref propgrid_iterator_flags.
204 */
205 wxPGProperty* GetFirst( int flags = wxPG_ITERATE_ALL );
206
207 /**
208 Returns id of property with given name (case-sensitive).
209 */
210 wxPGProperty* GetProperty( const wxString& name ) const
211 {
212 return GetPropertyByName(name);
213 }
214
215 /**
216 Adds to 'targetArr' pointers to properties that have given
217 flags 'flags' set. However, if 'inverse' is set to true, then
218 only properties without given flags are stored.
219
220 @param flags
221 Property flags to use.
222
223 @param iterFlags
224 Iterator flags to use. Default is everything expect private children.
225 See @ref propgrid_iterator_flags.
226 */
227 void GetPropertiesWithFlag( wxArrayPGProperty* targetArr,
228 wxPGProperty::FlagType flags,
229 bool inverse = false,
230 int iterFlags = (wxPG_ITERATE_PROPERTIES|wxPG_ITERATE_HIDDEN|wxPG_ITERATE_CATEGORIES) ) const;
231
232 /**
233 Returns value of given attribute. If none found, returns wxNullVariant.
234 */
235 wxVariant GetPropertyAttribute( wxPGPropArg id, const wxString& attrName ) const;
236
237 /**
238 Returns pointer of property's nearest parent category. If no category
239 found, returns NULL.
240 */
241 wxPropertyCategory* GetPropertyCategory( wxPGPropArg id ) const;
242
243 /** Returns client data (void*) of a property. */
244 void* GetPropertyClientData( wxPGPropArg id ) const;
245
246 /**
247 Returns first property which label matches given string. NULL if none
248 found. Note that this operation is very slow when compared to
249 GetPropertyByName().
250 */
251 wxPGProperty* GetPropertyByLabel( const wxString& label ) const;
252
253 /**
254 Returns property with given name. NULL if none found.
255 */
256 wxPGProperty* GetPropertyByName( const wxString& name ) const;
257
258 /**
259 Returns child property 'subname' of property 'name'. Same as
260 calling GetPropertyByName("name.subname"), albeit slightly faster.
261 */
262 wxPGProperty* GetPropertyByName( const wxString& name,
263 const wxString& subname ) const;
264
265 /**
266 Returns property's editor.
267 */
268 const wxPGEditor* GetPropertyEditor( wxPGPropArg id ) const;
269
270 /**
271 Returns help string associated with a property.
272 */
273 wxString GetPropertyHelpString( wxPGPropArg id ) const;
274
275 /**
276 Returns property's custom value image (NULL of none).
277 */
278 wxBitmap* GetPropertyImage( wxPGPropArg id ) const;
279
280 /** Returns label of a property. */
281 const wxString& GetPropertyLabel( wxPGPropArg id );
282
283 /** Returns property's name, by which it is globally accessible. */
284 wxString GetPropertyName( wxPGProperty* property );
285
286 /**
287 Returns validator of a property as a reference, which you
288 can pass to any number of SetPropertyValidator.
289 */
290 wxValidator* GetPropertyValidator( wxPGPropArg id );
291
292 /**
293 Returns property's value as wxVariant.
294
295 If property value is unspecified, Null variant is returned.
296 */
297 wxVariant GetPropertyValue( wxPGPropArg id );
298
299 /** Return's property's value as wxArrayInt. */
300 wxArrayInt GetPropertyValueAsArrayInt( wxPGPropArg id ) const;
301
302 /** Returns property's value as wxArrayString. */
303 wxArrayString GetPropertyValueAsArrayString( wxPGPropArg id ) const;
304
305 /** Returns property's value as bool */
306 bool GetPropertyValueAsBool( wxPGPropArg id ) const;
307
308 /** Return's property's value as wxDateTime. */
309 wxDateTime GetPropertyValueAsDateTime( wxPGPropArg id ) const;
310
311 /** Returns property's value as double-precision floating point number. */
312 double GetPropertyValueAsDouble( wxPGPropArg id ) const;
313
314 /** Returns property's value as integer */
315 int GetPropertyValueAsInt( wxPGPropArg id ) const;
316
317 /** Returns property's value as integer */
318 long GetPropertyValueAsLong( wxPGPropArg id ) const;
319
320 /** Returns property's value as native signed 64-bit integer. */
321 wxLongLong_t GetPropertyValueAsLongLong( wxPGPropArg id ) const;
322
323 /**
324 Returns property's value as wxString. If property does not
325 use string value type, then its value is converted using
326 wxPGProperty::GetValueAsString().
327 */
328 wxString GetPropertyValueAsString( wxPGPropArg id ) const;
329
330 /** Returns property's value as unsigned integer */
331 unsigned long GetPropertyValueAsULong( wxPGPropArg id ) const;
332
333 /** Returns property's value as native unsigned 64-bit integer. */
334 wxULongLong_t GetPropertyValueAsULongLong( wxPGPropArg id ) const;
335
336 /**
337 Returns a wxVariant list containing wxVariant versions of all
338 property values. Order is not guaranteed.
339
340 @param flags
341 Use wxPG_KEEP_STRUCTURE to retain category structure; each sub
342 category will be its own wxVariantList of wxVariant.
343
344 Use wxPG_INC_ATTRIBUTES to include property attributes as well.
345 Each attribute will be stored as list variant named
346 "@@<propname>@@attr."
347 */
348 wxVariant GetPropertyValues( const wxString& listname = wxEmptyString,
349 wxPGProperty* baseparent = NULL, long flags = 0 ) const;
350
351 /** Returns currently selected property. */
352 wxPGProperty* GetSelection() const;
353
354 /**
355 Similar to GetIterator(), but instead returns wxPGVIterator instance,
356 which can be useful for forward-iterating through arbitrary property
357 containers.
358
359 @param flags
360 See @ref propgrid_iterator_flags.
361
362 <b>wxPython Note:</b> Instead of ++ operator, use Next() method, and
363 instead of * operator, use GetProperty() method.
364 */
365 virtual wxPGVIterator GetVIterator( int flags ) const;
366
367 /**
368 Hides or reveals a property.
369
370 @param hide
371 If @true, hides property, otherwise reveals it.
372
373 @param flags
374 By default changes are applied recursively. Set this parameter
375 wxPG_DONT_RECURSE to prevent this.
376 */
377 bool HideProperty( wxPGPropArg id, bool hide = true, int flags = wxPG_RECURSE );
378
379 /**
380 Initializes *all* property types. Causes references to most object
381 files in the library, so calling this may cause significant increase
382 in executable size when linking with static library.
383 */
384 static void InitAllTypeHandlers();
385
386 //@{
387 /** Inserts property to the property container.
388
389 @param priorThis
390 New property is inserted just prior to this. Available only
391 in the first variant. There are two versions of this function
392 to allow this parameter to be either an id or name to
393 a property.
394
395 @param newProperty
396 Pointer to the inserted property. wxPropertyGrid will take
397 ownership of this object.
398
399 @param parent
400 New property is inserted under this category. Available only
401 in the second variant. There are two versions of this function
402 to allow this parameter to be either an id or name to
403 a property.
404
405 @param index
406 Index under category. Available only in the second variant.
407 If index is < 0, property is appended in category.
408
409 @return Returns newProperty.
410
411 @remarks
412
413 - wxPropertyGrid takes the ownership of the property pointer.
414
415 - While Append may be faster way to add items, make note that when
416 both types of data storage (categoric and
417 non-categoric) are active, Insert becomes even more slow. This is
418 especially true if current mode is non-categoric.
419
420 Example of use:
421
422 @code
423
424 // append category
425 wxPGProperty* my_cat_id = propertygrid->Append( new wxPropertyCategory("My Category") );
426
427 ...
428
429 // insert into category - using second variant
430 wxPGProperty* my_item_id_1 = propertygrid->Insert( my_cat_id, 0, new wxStringProperty("My String 1") );
431
432 // insert before to first item - using first variant
433 wxPGProperty* my_item_id_2 = propertygrid->Insert( my_item_id, new wxStringProperty("My String 2") );
434
435 @endcode
436
437 */
438 wxPGProperty* Insert( wxPGPropArg priorThis, wxPGProperty* newProperty );
439 wxPGProperty* Insert( wxPGPropArg parent, int index, wxPGProperty* newProperty );
440 //@}
441
442 /** Returns @true if property is a category. */
443 bool IsPropertyCategory( wxPGPropArg id ) const;
444
445 /** Returns @true if property is enabled. */
446 bool IsPropertyEnabled( wxPGPropArg id ) const;
447
448 /**
449 Returns true if given property is expanded. Naturally, always returns
450 @false for properties that cannot be expanded.
451 */
452 bool IsPropertyExpanded( wxPGPropArg id ) const;
453
454 /**
455 Returns @true if property has been modified after value set or modify
456 flag clear by software.
457 */
458 bool IsPropertyModified( wxPGPropArg id ) const;
459
460 /**
461 Returns true if property is shown (ie. HideProperty() with @true not
462 called for it).
463 */
464 bool IsPropertyShown( wxPGPropArg id ) const;
465
466 /**
467 Returns true if property value is set to unspecified.
468 */
469 bool IsPropertyValueUnspecified( wxPGPropArg id ) const;
470
471 /**
472 Disables (limit = @true) or enables (limit = @false) wxTextCtrl editor
473 of a property, if it is not the sole mean to edit the value.
474 */
475 void LimitPropertyEditing( wxPGPropArg id, bool limit = true );
476
477 /**
478 Initializes additional property editors (SpinCtrl etc.). Causes
479 references to most object files in the library, so calling this may
480 cause significant increase in executable size when linking with static
481 library.
482 */
483 static void RegisterAdditionalEditors();
484
485 /**
486 Replaces property with id with newly created one. For example,
487 this code replaces existing property named "Flags" with one that
488 will have different set of items:
489
490 @code
491 pg->ReplaceProperty("Flags",
492 wxFlagsProperty("Flags", wxPG_LABEL, newItems))
493 @endcode
494
495 @see Insert()
496 */
497 wxPGProperty* ReplaceProperty( wxPGPropArg id, wxPGProperty* property );
498
499 /**
500 @anchor propgridinterface_editablestate_flags
501
502 Flags for wxPropertyGridInterface::SaveEditableState() and
503 wxPropertyGridInterface::RestoreEditableState().
504 */
505 enum EditableStateFlags
506 {
507 /** Include selected property. */
508 SelectionState = 0x01,
509 /** Include expanded/collapsed property information. */
510 ExpandedState = 0x02,
511 /** Include scrolled position. */
512 ScrollPosState = 0x04,
513 /** Include selected page information. Only applies to
514 wxPropertyGridManager. */
515 PageState = 0x08,
516 /** Include splitter position. Stored for each page. */
517 SplitterPosState = 0x10,
518 /** Include description box size.
519 Only applies to wxPropertyGridManager. */
520 DescBoxState = 0x20,
521
522 /**
523 Include all supported user editable state information.
524 This is usually the default value. */
525 AllStates = SelectionState |
526 ExpandedState |
527 ScrollPosState |
528 PageState |
529 SplitterPosState |
530 DescBoxState
531 };
532
533 /**
534 Restores user-editable state. See also wxPropertyGridInterface::SaveEditableState().
535
536 @param src
537 String generated by SaveEditableState.
538
539 @param restoreStates
540 Which parts to restore from source string. See @ref propgridinterface_editablestate_flags
541 "list of editable state flags".
542
543 @return Returns @false if there was problem reading the string.
544
545 @remarks If some parts of state (such as scrolled or splitter position)
546 fail to restore correctly, please make sure that you call this
547 function after wxPropertyGrid size has been set (this may
548 sometimes be tricky when sizers are used).
549 */
550 bool RestoreEditableState( const wxString& src,
551 int restoreStates = AllStates );
552
553 /**
554 Used to acquire user-editable state (selected property, expanded
555 properties, scrolled position, splitter positions).
556
557 @param includedStates
558 Which parts of state to include. See @ref propgridinterface_editablestate_flags
559 "list of editable state flags".
560 */
561 wxString SaveEditableState( int includedStates = AllStates ) const;
562
563 /**
564 Sets strings listed in the choice dropdown of a wxBoolProperty.
565
566 Defaults are "True" and "False", so changing them to, say, "Yes" and
567 "No" may be useful in some less technical applications.
568 */
569 static void SetBoolChoices( const wxString& trueChoice,
570 const wxString& falseChoice );
571
572 /**
573 Sets or clears flag(s) of all properties in given array.
574
575 @param flags
576 Property flags to set or clear.
577
578 @param inverse
579 Set to true if you want to clear flag instead of setting them.
580 */
581 void SetPropertiesFlag( const wxArrayPGProperty& srcArr, wxPGProperty::FlagType flags,
582 bool inverse = false );
583
584 /**
585 Sets an attribute for this property.
586
587 @param name
588 Text identifier of attribute. See @ref propgrid_property_attributes.
589
590 @param value
591 Value of attribute.
592
593 @param argFlags
594 Optional. Use wxPG_RECURSE to set the attribute to child properties
595 recursively.
596
597 @remarks Setting attribute's value to Null variant will simply remove it
598 from property's set of attributes.
599 */
600 void SetPropertyAttribute( wxPGPropArg id, const wxString& attrName,
601 wxVariant value, long argFlags = 0 );
602
603 /**
604 Sets property attribute for all applicapple properties.
605 Be sure to use this method only after all properties have been
606 added to the grid.
607 */
608 void SetPropertyAttributeAll( const wxString& attrName, wxVariant value );
609
610 /**
611 Sets text, bitmap, and colours for given column's cell.
612
613 @remarks
614 - You can set label cell by using column 0.
615 - You can use wxPG_LABEL as text to use default text for column.
616 */
617 void SetPropertyCell( wxPGPropArg id,
618 int column,
619 const wxString& text = wxEmptyString,
620 const wxBitmap& bitmap = wxNullBitmap,
621 const wxColour& fgCol = wxNullColour,
622 const wxColour& bgCol = wxNullColour );
623
624 /**
625 Sets client data (void*) of a property.
626
627 @remarks
628 This untyped client data has to be deleted manually.
629 */
630 void SetPropertyClientData( wxPGPropArg id, void* clientData );
631
632 /**
633 Sets editor for a property.
634
635 @param editor
636 For builtin editors, use wxPGEditor_X, where X is builtin editor's
637 name (TextCtrl, Choice, etc. see wxPGEditor documentation for full
638 list).
639
640 For custom editors, use pointer you received from wxPropertyGrid::RegisterEditorClass().
641 */
642 void SetPropertyEditor( wxPGPropArg id, const wxPGEditor* editor );
643
644 /**
645 Sets editor control of a property. As editor argument, use
646 editor name string, such as "TextCtrl" or "Choice".
647 */
648 void SetPropertyEditor( wxPGPropArg id, const wxString& editorName );
649
650 /**
651 Sets label of a property.
652
653 @remarks
654 - Properties under same parent may have same labels. However,
655 property names must still remain unique.
656 */
657 void SetPropertyLabel( wxPGPropArg id, const wxString& newproplabel );
658
659 /**
660 Sets name of a property.
661
662 @param id
663 Name or pointer of property which name to change.
664
665 @param newName
666 New name for property.
667 */
668 void SetPropertyName( wxPGPropArg id, const wxString& newName );
669
670 /**
671 Sets property (and, recursively, its children) to have read-only value.
672 In other words, user cannot change the value in the editor, but they can
673 still copy it.
674
675 @remarks This is mainly for use with textctrl editor. Only some other
676 editors fully support it.
677
678 @param id
679 Property name or pointer.
680
681 @param set
682 Use @true to enable read-only, @false to disable it.
683
684 @param flags
685 By default changes are applied recursively. Set this parameter
686 wxPG_DONT_RECURSE to prevent this.
687 */
688 void SetPropertyReadOnly( wxPGPropArg id, bool set = true,
689 int flags = wxPG_RECURSE );
690
691 /**
692 Sets property's value to unspecified. If it has children (it may be
693 category), then the same thing is done to them.
694 */
695 void SetPropertyValueUnspecified( wxPGPropArg id );
696
697 /**
698 Sets various property values from a list of wxVariants. If property with
699 name is missing from the grid, new property is created under given
700 default category (or root if omitted).
701 */
702 void SetPropertyValues( const wxVariantList& list,
703 wxPGPropArg defaultCategory = wxNullProperty );
704
705 void SetPropertyValues( const wxVariant& list,
706 wxPGPropArg defaultCategory = wxNullProperty );
707
708 /**
709 Associates the help string with property.
710
711 @remarks By default, text is shown either in the manager's "description"
712 text box or in the status bar. If extra window style
713 wxPG_EX_HELP_AS_TOOLTIPS is used, then the text will appear as
714 a tooltip.
715 */
716 void SetPropertyHelpString( wxPGPropArg id, const wxString& helpString );
717
718 /**
719 Set wxBitmap in front of the value.
720
721 @remarks Bitmap will be scaled to a size returned by
722 wxPropertyGrid::GetImageSize();
723 */
724 void SetPropertyImage( wxPGPropArg id, wxBitmap& bmp );
725
726 /**
727 Sets max length of property's text.
728 */
729 bool SetPropertyMaxLength( wxPGPropArg id, int maxLen );
730
731 /**
732 Sets validator of a property.
733 */
734 void SetPropertyValidator( wxPGPropArg id, const wxValidator& validator );
735
736 /** Sets value (integer) of a property. */
737 void SetPropertyValue( wxPGPropArg id, long value );
738
739 /** Sets value (integer) of a property. */
740 void SetPropertyValue( wxPGPropArg id, int value );
741
742 /** Sets value (floating point) of a property. */
743 void SetPropertyValue( wxPGPropArg id, double value );
744
745 /** Sets value (bool) of a property. */
746 void SetPropertyValue( wxPGPropArg id, bool value );
747
748 /** Sets value (string) of a property. */
749 void SetPropertyValue( wxPGPropArg id, const wxString& value );
750
751 /** Sets value (wxArrayString) of a property. */
752 void SetPropertyValue( wxPGPropArg id, const wxArrayString& value );
753
754 /** Sets value (wxDateTime) of a property. */
755 void SetPropertyValue( wxPGPropArg id, const wxDateTime& value );
756
757 /** Sets value (wxObject*) of a property. */
758 void SetPropertyValue( wxPGPropArg id, wxObject* value );
759
760 /** Sets value (wxObject&) of a property. */
761 void SetPropertyValue( wxPGPropArg id, wxObject& value );
762
763 /** Sets value (native 64-bit int) of a property. */
764 void SetPropertyValue( wxPGPropArg id, wxLongLong_t value );
765
766 /** Sets value (native 64-bit unsigned int) of a property. */
767 void SetPropertyValue( wxPGPropArg id, wxULongLong_t value );
768
769 /** Sets value (wxArrayInt&) of a property. */
770 void SetPropertyValue( wxPGPropArg id, const wxArrayInt& value );
771
772 /**
773 Sets value (wxString) of a property.
774
775 @remarks This method uses wxPGProperty::SetValueFromString(), which all
776 properties should implement. This means that there should not be
777 a type error, and instead the string is converted to property's
778 actual value type.
779 */
780 void SetPropertyValueString( wxPGPropArg id, const wxString& value );
781
782 /**
783 Sets value (wxVariant&) of a property.
784
785 @remarks Use wxPropertyGrid::ChangePropertyValue() instead if you need to
786 run through validation process and send property change event.
787 */
788 void SetPropertyValue( wxPGPropArg id, wxVariant value );
789
790 /**
791 Adjusts how wxPropertyGrid behaves when invalid value is entered
792 in a property.
793
794 @param vfbFlags
795 See @ref propgrid_vfbflags for possible values.
796 */
797 void SetValidationFailureBehavior( int vfbFlags );
798
799 /**
800 Returns editor pointer of editor with given name;
801 */
802 static wxPGEditor* GetEditorByName( const wxString& editorName );
803 };
804