- Alt-N switches to the tab at index N for values of 0 >= N <= 9.
This makes switching to arbitrary tabs very quick.
This commit is contained in:
parent
969d2b771c
commit
d9205d83d9
|
@ -136,6 +136,16 @@ Defaults = {
|
|||
'scaled_zoom' : '<Ctrl><Shift>Z',
|
||||
'next_tab' : '<Ctrl>Page_Down',
|
||||
'prev_tab' : '<Ctrl>Page_Up',
|
||||
'first_tab' : '<Alt>1',
|
||||
'second_tab' : '<Alt>2',
|
||||
'third_tab' : '<Alt>3',
|
||||
'fourth_tab' : '<Alt>4',
|
||||
'fifth_tab' : '<Alt>5',
|
||||
'sixth_tab' : '<Alt>6',
|
||||
'seventh_tab' : '<Alt>7',
|
||||
'eighth_tab' : '<Alt>8',
|
||||
'ninth_tab' : '<Alt>9',
|
||||
'tenth_tab' : '<Alt>0',
|
||||
'full_screen' : 'F11',
|
||||
'reset' : '<Ctrl><Shift>R',
|
||||
'reset_clear' : '<Ctrl><Shift>G',
|
||||
|
|
|
@ -1127,6 +1127,12 @@ class Terminator:
|
|||
notebook.next_page()
|
||||
notebook.set_current_page(notebook.get_current_page())
|
||||
|
||||
def switch_to_tab(self, term, index):
|
||||
notebook = self.get_first_parent_notebook(term)
|
||||
if notebook:
|
||||
notebook.set_current_page(index)
|
||||
notebook.set_current_page(notebook.get_current_page())
|
||||
|
||||
def move_tab(self, term, direction):
|
||||
dbg("moving to direction %s" % direction)
|
||||
(notebook, page) = self.get_first_notebook_page(term)
|
||||
|
|
|
@ -829,6 +829,36 @@ text/plain
|
|||
def key_prev_tab(self):
|
||||
self.terminator.previous_tab (self)
|
||||
|
||||
def key_first_tab(self):
|
||||
self.terminator.switch_to_tab (self, 0)
|
||||
|
||||
def key_second_tab(self):
|
||||
self.terminator.switch_to_tab (self, 1)
|
||||
|
||||
def key_third_tab(self):
|
||||
self.terminator.switch_to_tab (self, 2)
|
||||
|
||||
def key_fourth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 3)
|
||||
|
||||
def key_fifth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 4)
|
||||
|
||||
def key_sixth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 5)
|
||||
|
||||
def key_seventh_tab(self):
|
||||
self.terminator.switch_to_tab (self, 6)
|
||||
|
||||
def key_eighth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 7)
|
||||
|
||||
def key_ninth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 8)
|
||||
|
||||
def key_tenth_tab(self):
|
||||
self.terminator.switch_to_tab (self, 9)
|
||||
|
||||
def key_reset(self):
|
||||
self._vte.reset (True, False)
|
||||
|
||||
|
|
Loading…
Reference in New Issue