On Thu, Feb 12, 2009 at 6:35 PM, Terry Brown <[email protected]> wrote:
> Kent and others who might be looking for a file system integration > approach, here's the about plugin text for the active_path.py plugin. > Tk only at the moment, until leo-qt handles clicks on the tree. Here's a related idea familiar from ILeo: How about a "act-on-node" command? This would be similar to alt-I (push-to-ipython), in that it would invoke whatever operation is associated with the node. Currently, many plugins hook to low-level stuff like "double click on tree icon" or whatever, which is sort of annoying if you mostly use keyboard. I'm emphatically not referring to the fact that plugins can create commands that can be hooked on any key you want - I'm thinking of one key to remember that did the "logical" thing depending on the node that is activated. Possibly a plugin could also open its own special menu from that. @url nodes would be opened, active_paths would be expanded, @graphs would be launched, insert-plugin-specific-stuff here. One way to implement this is to use the same approach as ipython does with TryNext exception - all the registered hooks are run, the hook function takes a look at the node, and either handles it or raises TryNext exception (which propagates the call to next hook). Basic framework for this could be snatched directly from IPython/hooks.py (CommandChainDispatcher, which is a command chain dispatcher (duh) that runs the hooks in priority order). -- 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 -~----------~----~----~----~------~----~------~--~---
