I finally made it worked this way. It just works on my extensive wiki tree, 
so I think it's conclusive... 
Of course I could modify it if doDelete is a problem, but for now, I don't 
really understand the issue of it...
Now I'm happy : I've a very nice Leo/rst outline with all my last years 
data. Ready to Sphinx it :)
I'm gonna test your implementation tomorrow morning, now is time to bed.

Here is the post import cleaning function, to make everything pretty :

 def clean():
 """ 
 Clean useless nodes 
 """ 
 for pos in c.all_positions(): 
   if '@rst-no-head' in pos.h: 
     parent = pos.getParent() 
     parent.b = '\n'.join(pos.b.split('\n')[3:]) 
     pos.doDelete() 
   elif pos.hasFirstChild() and 'Warning: this node is ignored when writing 
this file' in pos.b: 
     child=pos.getFirstChild() 
     if pos.h==child.h: 
       if not child.hasFirstChild(): 
         pos.b=child.b 
         child.doDelete() 
       elif not child.hasNext(): 
         pos.b=child.b 
         child.copyTreeFromSelfTo(pos) 
         child.doDelete() 
       else : 
         child.h='Introduction'


-- 
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.
For more options, visit https://groups.google.com/d/optout.

Reply via email to