Bind 'buffer', 'editor', and 'moo' in tools scripts

master
Yevgen Muntyan 2007-04-03 12:31:36 -05:00
parent 13142f4a4c
commit 03e6352fb5
1 changed files with 3 additions and 0 deletions

View File

@ -16,6 +16,9 @@ class PyCmd(moo.edit.Command):
dic = {}
dic['doc'] = ctx.get_doc()
dic['window'] = ctx.get_window()
dic['buffer'] = ctx.get_doc() and ctx.get_doc().get_buffer()
dic['editor'] = moo.edit.editor_instance()
dic['moo'] = moo
ctx.foreach(self.__set_variable, dic)