[Dev] Attribute Editor API proposal

John Anderson john at osafoundation.org
Tue Dec 7 10:27:26 PST 2004


wxGrid has the concept of an attributeRenderer and attributeEditor. 
Whenever you ask for a new render or editor you don't get a new object, 
but instead a reference count is increased. Likewise when you delete the 
object, it's reference count is decremented. This design has the 
consequence that many cells use the same editor/render, no cell specific 
state can be store on the object -- all cell specific information is 
stored elsewhere.

If I wanted to use Chandler's attribute editor to implement the 
functionality of the grid it would be convenient if I didn't have to 
have separate Chandler attribute editor, with cell specific state, for 
each cell.

The decision for whether or not to creat a control is determined by the 
Grid, not the Chandler attribute editor. For example when you click on a 
cell it asks the Grid for a new editor (which increments the refcount as 
above) then edits the cell in place.

John



Donn Denman wrote:

> We're developing Attribute Editors - a set of plug-in classes that 
> display and edit attributes based on their type.  We're currently 
> using Attribute Editors in Tables and starting to use them in other 
> contexts as well.  I wrote up a proposal for an update to the API that 
> we're using to allow the Attribute Editors to be easier to write and 
> more flexible.  The details are on this wiki page:
>
> http://wiki.osafoundation.org/twiki/bin/view/Chandler/AttributeEditorApi
>
> - Donn Denman
>
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> Open Source Applications Foundation "Dev" mailing list
> http://lists.osafoundation.org/mailman/listinfo/dev



More information about the Dev mailing list