Merge branch from Stephen J Boddy to add keyboard shortcuts for inserting terminal numbers

This commit is contained in:
Chris Jones 2012-07-10 19:33:30 +01:00
commit 2900e2eee5
3 changed files with 12 additions and 2 deletions

View File

@ -161,7 +161,9 @@ DEFAULTS = {
'new_terminator' : '<Super>i',
'broadcast_off' : '',
'broadcast_group' : '',
'broadcast_all' : ''
'broadcast_all' : '',
'insert_number' : '',
'insert_padded' : ''
},
'profiles': {
'default': {

View File

@ -126,7 +126,9 @@ class PrefsEditor:
'new_terminator' : 'Spawn a new Terminator process',
'broadcast_off' : 'Don\'t broadcast key presses',
'broadcast_group' : 'Broadcast key presses to group',
'broadcast_all' : 'Broadcast key events to all'
'broadcast_all' : 'Broadcast key events to all',
'insert_number' : 'Insert terminal number',
'insert_padded' : 'Insert zero padded terminal number'
}
def __init__ (self, term):

View File

@ -1634,6 +1634,12 @@ class Terminal(gtk.VBox):
def key_broadcast_all(self):
self.set_groupsend(None, self.terminator.groupsend_type['all'])
def key_insert_number(self):
self.emit('enumerate', False)
def key_insert_padded(self):
self.emit('enumerate', True)
# End key events
gobject.type_register(Terminal)