On Thu, May 23, 2013 at 9:53 AM, Terry Brown <[email protected]>wrote:

Since you brought vnodes into the topic :-)

>
> Building large data visualization (i.e. throw away) trees is slow with
> positions, but fast with vnodes.  I use this monkey patch [to define
> v.insertAsLastChild]:


Just a few methods need to be added to the vnode class to fill the holes in
the vnode API. That is, most of the position methods in tree::

    p.Moving, Inserting, Deleting, Cloning, Sorting

make no sense in the vnode class.  For example, p.moveAfter,
p.moveToNthChildOf, etc leave data unchanged.  Furthermore, v.insertAfter
would not be well defined: because of clones, vnode v may have many
parents. Ditto for v.clone, but see below.

It seems worthwhile to add v.insertAsNthChild, with v.insertAsFirstChild
and v.insertAsLastChild defined in using v.insertAsNthChild.  As I write
this, I see that it would be possible to define::

    v.cloneAsNthChild(parent_vnode,n)

These four methods seem to me to be the only holes in the vnode API.  I'll
add these *experimental* definitions today.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/leo-editor?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to