RAD Studio
ContentsIndex
PreviousUpNext
Adding Property Editors

The Object Inspector provides default editing for all types of properties. You can, however, provide an alternate editor for specific properties by writing and registering property editors. You can register property editors that apply only to the properties in the components you write, but you can also create editors that apply to all properties of a certain type. 

At the simplest level, a property editor can operate in either or both of two ways: displaying and allowing the user to edit the current value as a text string, and displaying a dialog box that permits some other kind of editing. Depending on the property being edited, you might find it useful to provide either or both kinds. 

Writing a property editor requires these five steps:

  1. Deriving a property-editor class.
  2. Editing the property as text.
  3. Editing the property as a whole.
  4. Specifying editor attributes.
  5. Registering the property editor.

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!