On Tue, 29 Jul 2014 04:52:57 -0500 "Edward K. Ream" <[email protected]> wrote:
> On Mon, Jul 28, 2014 at 10:26 PM, 'Terry Brown' via leo-editor > <[email protected]> wrote: > > > I'm not looking for excitement ;-) I'm looking for Leo to say > > "here's the filename, here's the node to stick the subtree in, now > > make the subtree". Well, ok, I guess that would be exciting for > > the flexibility it offers :-) > > Try this: > > ic = c.importCommands > ic.createOutline(fileName,parent, > atAuto=True,atShadow=False,s=None,ext=None) Ok, so that forced it to use my importer, but it failed like this: File "/mnt/usr1/usr1/home/tbrown/Package/leo/git/leo-editor/leo/core/leoCommands.py", line 2473, in executeScript c.executeScriptHelper(args,define_g,define_name,namespace,script) File "/mnt/usr1/usr1/home/tbrown/Package/leo/git/leo-editor/leo/core/leoCommands.py", line 2511, in executeScriptHelper execfile(scriptFile,d) File "/home/tbrown/.leo/scriptFile.py", line 7, in <module> atAuto=True,atShadow=False,s='testtest',ext=None) File "/mnt/usr1/usr1/home/tbrown/Package/leo/git/leo-editor/leo/core/leoImport.py", line 560, in createOutline func(atAuto=atAuto,parent=p,s=s) File "/mnt/usr1/usr1/home/tbrown/Package/leo/git/leo-editor/leo/core/leoImport.py", line 611, in scanner_for_at_auto_cb scanner = aClass(importCommands=self,atAuto=atAuto) File "/mnt/usr1/usr1/home/tbrown/Package/leo/git/leo-editor/leo/plugins/importers/test.py", line 6, in __init__ return BaseScanner.__init__(self, *args, **kwargs) TypeError: __init__() takes at least 4 arguments (3 given) Cheers -Terry > Note 100% sure about the atAuto arg. If s is given, it will be taken > as the contents of the file. The ext arg can be used to force a given > importer. > > When in doubt, look at the sources for createOutline. I've recently > refactored them, so they should be more understandable. > > 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. For more options, visit https://groups.google.com/d/optout.
