Nashev added the comment:

1) in file EditorWindow.py 2 editings:

a) remove selection-killer command on popup

    def right_menu_event(self, event):
--      self.text.tag_remove("sel", "1.0", "end")

b) add ability to make separators in popup menu

    def make_rmenu(self):
        rmenu = Menu(self.text, tearoff=0)
        for label, eventname in self.rmenu_specs:
++          if label != "-":
                def command(text=self.text, eventname=eventname):
                    text.event_generate(eventname)
                rmenu.add_command(label=label, command=command)
++          else:
++              rmenu.add_separator()
        self.rmenu = rmenu

2) in PyShell.py extend rmenu_specs

    rmenu_specs = [
++      ("Cut", "<<Cut>>"), 
++      ("Copy", "<<Copy>>"),
++      ("Paste", "<<Paste>>"),
++      ("-", ""),
        ("Set Breakpoint", "<<set-breakpoint-here>>"),
        ("Clear Breakpoint", "<<clear-breakpoint-here>>")
    ]

done...

And now I can't find easy way to next two desired features:
  1) disable cut/copy commands in case no selection (but it is not
exists in main menu too)
  2) display assigned hot keys in popup menu

----------
nosy: +Nashev

_____________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1207589>
_____________________________________
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to