'imp' module is no longer used for importing plugins; __import__ is
used instead.

In enabled-plugins, following heuristics apply (entry in node =>
imported module):

foo.py => leo.plugins.foo
foo => foo
leo.plugins.foo => leo.plugins.foo
myleoplugins.bar => myleoplugins.bar

Yes, the first one 'special case" to retain compatibility.

Note that this scheme allows installing your plugins outside leo
source tree (just put them somewhere on pythonpath). Basically, this
means you can create your own "plugin bundle" and have normal setup.py
to go with it.

The new code is faster than the old one (a plugin is only ever
imported once), but you might not notice it on new computers.

plugins_menu.py is a bit messy in the sense that it likes to deal with
files. It still works, but only plugins loaded under leo.plugins are
shown.

Testing for regressions (and fixing eventual bugs ;-) is appreciated.

To review the changes:

http://bazaar.launchpad.net/~leo-editor-team/leo-editor/trunk/revision/3020
http://bazaar.launchpad.net/~leo-editor-team/leo-editor/trunk/revision/3021

Some silliness that's no longer relevant is probably remaining in the code.

-- 
Ville M. Vainio
http://tinyurl.com/vainio

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

Reply via email to