From e8c366ae544337c28a3b3cc9731b1448a490a512 Mon Sep 17 00:00:00 2001 From: Phi Date: Sat, 22 Aug 2020 11:28:06 +0200 Subject: [PATCH 001/101] Use the term 'zero padded' instead of 'padded' in prefs key binding and terminal pop up menu, to be consistent with the doc. --- terminatorlib/prefseditor.py | 2 +- terminatorlib/terminal.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 89232b6d6..6f6936634 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -166,7 +166,7 @@ class PrefsEditor: 'broadcast_group' : _('Broadcast key presses to group'), 'broadcast_all' : _('Broadcast key events to all'), 'insert_number' : _('Insert terminal number'), - 'insert_padded' : _('Insert padded terminal number'), + 'insert_padded' : _('Insert zero padded terminal number'), 'edit_window_title': _('Edit window title'), 'edit_terminal_title': _('Edit terminal title'), 'edit_tab_title' : _('Edit tab title'), diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 82997aa40..dd2dd99fe 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -555,7 +555,7 @@ def populate_group_menu(self): item.connect('activate', lambda x: self.emit('enumerate', False)) menu.append(item) - item = Gtk.MenuItem.new_with_mnemonic(_('Insert _padded terminal number')) + item = Gtk.MenuItem.new_with_mnemonic(_('Insert zero _padded terminal number')) item.connect('activate', lambda x: self.emit('enumerate', True)) menu.append(item) From 04bd6935868dad81fb1771ae95bcd57c566bf842 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 9 Apr 2022 11:15:36 +0200 Subject: [PATCH 002/101] Zoom/maximize with one terminal in notebook tab --- terminatorlib/notebook.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index 7daccaa4e..4c0b92dc4 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -290,7 +290,9 @@ def newtab(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=N 'ungroup-tab': top_window.ungroup_tab, 'move-tab': top_window.move_tab, 'tab-new': [top_window.tab_new, widget], - 'navigate': top_window.navigate_terminal} + 'navigate': top_window.navigate_terminal, + 'zoom': top_window.zoom, + 'maximise': [top_window.zoom, False]} if maker.isinstance(widget, 'Terminal'): for signal in signals: From c2f2addf056d97fa57c4b554da480adcb3b9498a Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 9 Apr 2022 11:19:36 +0200 Subject: [PATCH 003/101] Remove unused code (container.py, toggle_zoom) --- terminatorlib/container.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/terminatorlib/container.py b/terminatorlib/container.py index 53d4914cc..97bea7fc0 100644 --- a/terminatorlib/container.py +++ b/terminatorlib/container.py @@ -134,17 +134,6 @@ def resizeterm(self, widget, keyname): """Handle a keyboard event requesting a terminal resize""" raise NotImplementedError('resizeterm') - def toggle_zoom(self, widget, fontscale = False): - """Toggle the existing zoom state""" - try: - if self.get_property('term_zoomed'): - self.unzoom(widget) - else: - self.zoom(widget, fontscale) - except TypeError: - err('Container::toggle_zoom: %s is unable to handle zooming, for \ - %s' % (self, widget)) - def zoom(self, widget, fontscale = False): """Zoom a terminal""" raise NotImplementedError('zoom') From ed93ccb7e569b18eeca3faa157ada9338c1f84eb Mon Sep 17 00:00:00 2001 From: amaan khan Date: Sat, 16 Apr 2022 12:05:29 +0530 Subject: [PATCH 004/101] no need to go to custom to set custom palette --- terminatorlib/prefseditor.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index c5fae5e7e..7013f75f9 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -966,10 +966,6 @@ def on_palette_combobox_changed(self, widget): if self.palettevalues[key] == active: value = key - sensitive = value == 'custom' - for palette_id in range(0, NUM_PALETTE_COLORS): - self.get_palette_widget(palette_id).set_sensitive(sensitive) - if value in self.palettes: palette = self.palettes[value] palettebits = palette.split(':') @@ -1726,8 +1722,8 @@ def on_use_theme_colors_checkbutton_toggled(self, widget): for widget in [scheme, fore, back]: widget.set_sensitive(False) else: - scheme.set_sensitive(True) - self.on_color_scheme_combobox_changed(scheme) + scheme.set_sensitive(True) + self.on_color_scheme_combobox_changed(scheme) self.config['use_theme_colors'] = active self.config.save() From 33f7927bfae8ff454c062a1808ce32b758a0576a Mon Sep 17 00:00:00 2001 From: amaan khan Date: Sat, 16 Apr 2022 12:09:38 +0530 Subject: [PATCH 005/101] fixed indent --- terminatorlib/prefseditor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 7013f75f9..a949d5f62 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -1722,8 +1722,8 @@ def on_use_theme_colors_checkbutton_toggled(self, widget): for widget in [scheme, fore, back]: widget.set_sensitive(False) else: - scheme.set_sensitive(True) - self.on_color_scheme_combobox_changed(scheme) + scheme.set_sensitive(True) + self.on_color_scheme_combobox_changed(scheme) self.config['use_theme_colors'] = active self.config.save() From 06ada7c655739dbc14d5341cc645da63ca4654ad Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 20 May 2022 13:12:16 +0200 Subject: [PATCH 006/101] Notebook tab zoom: keep label and position --- terminatorlib/window.py | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/terminatorlib/window.py b/terminatorlib/window.py index 04c60a4cb..f4830aaf7 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -529,6 +529,7 @@ def is_zoomed(self): def zoom(self, widget, font_scale=True): """Zoom a terminal widget""" + maker = Factory() children = self.get_children() if widget in children: @@ -541,8 +542,13 @@ def zoom(self, widget, font_scale=True): self.zoom_data['old_child'] = children[0] self.zoom_data['font_scale'] = font_scale + old_parent = self.zoom_data['old_parent'] + if maker.isinstance(old_parent, 'Notebook'): + self.zoom_data['notebook_tabnum'] = old_parent.page_num(widget) + self.zoom_data['notebook_label'] = old_parent.get_tab_label(widget).get_label() + self.remove(self.zoom_data['old_child']) - self.zoom_data['old_parent'].remove(widget) + old_parent.remove(widget) self.add(widget) self.set_property('term_zoomed', True) @@ -554,6 +560,8 @@ def zoom(self, widget, font_scale=True): def unzoom(self, widget=None): """Restore normal terminal layout""" + maker = Factory() + if not self.is_zoomed(): # We're not zoomed anyway dbg('not zoomed, no-op') @@ -565,7 +573,13 @@ def unzoom(self, widget=None): self.remove(widget) self.add(self.zoom_data['old_child']) - self.zoom_data['old_parent'].add(widget) + if maker.isinstance(self.zoom_data['old_parent'], 'Notebook'): + self.zoom_data['old_parent'].newtab(widget=widget, metadata={ + 'tabnum': self.zoom_data['notebook_tabnum'], + 'label': self.zoom_data['notebook_label'] + }) + else: + self.zoom_data['old_parent'].add(widget) widget.grab_focus() self.zoom_data = None self.set_property('term_zoomed', False) From 784dc4946e84bf1c74f33775e06121633498e88b Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Mon, 13 Jun 2022 15:16:24 +0200 Subject: [PATCH 007/101] Terminal mousewheel event: check for all modifiers --- terminatorlib/terminal.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 7bb78a156..101f609cc 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1006,7 +1006,9 @@ def on_mousewheel(self, widget, event): """Handler for modifier + mouse wheel scroll events""" SMOOTH_SCROLL_UP = event.direction == Gdk.ScrollDirection.SMOOTH and event.delta_y <= 0. SMOOTH_SCROLL_DOWN = event.direction == Gdk.ScrollDirection.SMOOTH and event.delta_y > 0. - if event.state & Gdk.ModifierType.CONTROL_MASK == Gdk.ModifierType.CONTROL_MASK: + + modifiers = event.state & (Gdk.ModifierType.CONTROL_MASK | Gdk.ModifierType.SHIFT_MASK) + if modifiers == Gdk.ModifierType.CONTROL_MASK: # Zoom the terminal(s) in or out if not disabled in config if self.config["disable_mousewheel_zoom"] is True: return False @@ -1025,7 +1027,7 @@ def on_mousewheel(self, widget, event): for target in targets: target.zoom_out() return True - if event.state & Gdk.ModifierType.SHIFT_MASK == Gdk.ModifierType.SHIFT_MASK: + elif modifiers == Gdk.ModifierType.SHIFT_MASK: # Shift + mouse wheel up/down if event.direction == Gdk.ScrollDirection.UP or SMOOTH_SCROLL_UP: self.scroll_by_page(-1) From 3245d671bb5b2c2d0156d6d9026742e26c2b49f6 Mon Sep 17 00:00:00 2001 From: Mihai Babiac Date: Fri, 29 Jul 2022 18:49:16 +0200 Subject: [PATCH 008/101] Add program_name to fix missing icons By default, GTK sets the prgname to argv[0], which is then used to choose the correct .desktop file. If the program is run through a symlink, such as through `/etc/alternatives/x-terminal-emulator`, argv[0] is not `terminator` so under Wayland the desktop file is not detected, leading to a missing icon. --- terminator | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/terminator b/terminator index 150fca0ed..14fd9cf3a 100755 --- a/terminator +++ b/terminator @@ -33,7 +33,7 @@ try: import gi gi.require_version('Gtk','3.0') # pylint: disable-msg=W0611 - from gi.repository import Gtk, Gdk + from gi.repository import Gtk, Gdk, GLib if Gdk.Display.get_default() == None: print('You need to run terminator in an X environment. ' \ @@ -80,6 +80,8 @@ if __name__ == '__main__': dbg ("%s starting up, version %s" % (APP_NAME, APP_VERSION)) + GLib.set_prgname(APP_NAME) + OPTIONS,dbus_options = terminatorlib.optionparse.parse_options() if OPTIONS.configjson: configjson = ConfigJson() From 6c2e3b8bf7a5d75ab707ac8cd32e887c0c040e44 Mon Sep 17 00:00:00 2001 From: xuezhixin Date: Mon, 15 Aug 2022 14:33:01 +0800 Subject: [PATCH 009/101] this line has an extra ';' symbol --- terminatorlib/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/util.py b/terminatorlib/util.py index eda14ced9..4cdf09439 100644 --- a/terminatorlib/util.py +++ b/terminatorlib/util.py @@ -196,7 +196,7 @@ def widget_pixbuf(widget, maxsize=None): Gdk.cairo_set_source_window(cairo_context, window, 0, 0) cairo_context.paint() - scaledpixbuf = Gdk.pixbuf_get_from_surface(preview_surface, 0, 0, preview_width, preview_height); + scaledpixbuf = Gdk.pixbuf_get_from_surface(preview_surface, 0, 0, preview_width, preview_height) return(scaledpixbuf) From df0643b1a447446eec8a592f3534da3f57402114 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 27 Aug 2022 22:06:00 +0200 Subject: [PATCH 010/101] Notebook rotate: keep tab position and label --- terminatorlib/paned.py | 4 ++-- terminatorlib/window.py | 15 ++++++++++++--- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/terminatorlib/paned.py b/terminatorlib/paned.py index bf9441606..86ca3cd28 100644 --- a/terminatorlib/paned.py +++ b/terminatorlib/paned.py @@ -424,7 +424,7 @@ def grab_focus(self): """We don't want focus, we want a Terminal to have it""" self.get_child1().grab_focus() - def rotate_recursive(self, parent, w, h, clockwise): + def rotate_recursive(self, parent, w, h, clockwise, metadata=None): """ Recursively rotate "self" into a new paned that'll have "w" x "h" size. Attach it to "parent". @@ -458,7 +458,7 @@ def rotate_recursive(self, parent, w, h, clockwise): w2 = max(w - w1 - handle_size, 0) container.set_pos(pos) - parent.add(container) + parent.add(container, metadata=metadata) if maker.isinstance(children[0], 'Terminal'): children[0].get_parent().remove(children[0]) diff --git a/terminatorlib/window.py b/terminatorlib/window.py index f4830aaf7..eadb0abab 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -597,8 +597,17 @@ def rotate(self, widget, clockwise): # If our child is a Notebook, reset to work from its visible child if maker.isinstance(child, 'Notebook'): - pagenum = child.get_current_page() - child = child.get_nth_page(pagenum) + notebook = child + + pagenum = notebook.get_current_page() + child = notebook.get_nth_page(pagenum) + + metadata = { + 'tabnum': pagenum, + 'label': notebook.get_tab_label(child).get_label() + } + else: + metadata = None if maker.isinstance(child, 'Paned'): parent = child.get_parent() @@ -606,7 +615,7 @@ def rotate(self, widget, clockwise): # otherwise _sometimes_ we get incorrect values. alloc = child.get_allocation() parent.remove(child) - child.rotate_recursive(parent, alloc.width, alloc.height, clockwise) + child.rotate_recursive(parent, alloc.width, alloc.height, clockwise, metadata) self.show_all() while Gtk.events_pending(): From d8141a86c3f625c333f278dd594a296bc91a01c1 Mon Sep 17 00:00:00 2001 From: sabriunal Date: Wed, 5 Oct 2022 14:14:07 +0300 Subject: [PATCH 011/101] data: Remove GNOME branding This MR is part of an [initiative](GNOME/Initiatives#35) to fade out legacy app branding. Following the [Software Policy](https://wiki.gnome.org/Foundation/SoftwarePolicy), GNOME branding is reserved for official GNOME software (Core apps and Development tools.) You can find a summary in [this blog post](https://blogs.gnome.org/sophieh/2022/06/08/apps-attempt-of-a-status-report/). If you think that your app is a special case that needs an exception from the software policy, we would ask you to leave a comment about your app's case in GNOME/Initiatives#35. /label ~"9. Initiative: Legacy app branding" --- data/terminator.appdata.xml.in | 1 + 1 file changed, 1 insertion(+) diff --git a/data/terminator.appdata.xml.in b/data/terminator.appdata.xml.in index 011273b1b..0d75c34ff 100644 --- a/data/terminator.appdata.xml.in +++ b/data/terminator.appdata.xml.in @@ -47,4 +47,5 @@ https://github.com/gnome-terminator/terminator terminator@lazyfrosch.de + The Terminator Team From 5bd81ce4780544c4fa833b5961d76251896bbc36 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sun, 16 Oct 2022 01:32:30 +0530 Subject: [PATCH 012/101] - added plugin save_last_session_layout.py - saves the working directory and layout of last session (last window) closed - layout is saved under name of SaveLastSessionLayout - can be loaded from context menu (right click) -> layouts -> "SaveLastSessionLayout" - last working directory is also saved --- terminatorlib/container.py | 4 +- .../plugins/save_last_session_layout.py | 69 +++++++++++++++++++ terminatorlib/terminal.py | 4 +- terminatorlib/terminator.py | 4 +- 4 files changed, 76 insertions(+), 5 deletions(-) create mode 100644 terminatorlib/plugins/save_last_session_layout.py diff --git a/terminatorlib/container.py b/terminatorlib/container.py index 53d4914cc..7dfdbb124 100644 --- a/terminatorlib/container.py +++ b/terminatorlib/container.py @@ -245,7 +245,7 @@ def get_visible_terminals(self): return(terminals) - def describe_layout(self, count, parent, global_layout, child_order): + def describe_layout(self, count, parent, global_layout, child_order, save_cwd = False): """Describe our current layout""" layout = {} maker = Factory() @@ -308,7 +308,7 @@ def describe_layout(self, count, parent, global_layout, child_order): child_order = 0 for child in self.get_children(): if hasattr(child, 'describe_layout'): - count = child.describe_layout(count, name, global_layout, child_order) + count = child.describe_layout(count, name, global_layout, child_order, save_cwd) child_order = child_order + 1 return(count) diff --git a/terminatorlib/plugins/save_last_session_layout.py b/terminatorlib/plugins/save_last_session_layout.py new file mode 100644 index 000000000..66558f1fe --- /dev/null +++ b/terminatorlib/plugins/save_last_session_layout.py @@ -0,0 +1,69 @@ +import os +import sys + +# Fix imports when testing this file directly +if __name__ == '__main__': + sys.path.append( os.path.join(os.path.dirname(__file__), "../..")) + +from terminatorlib.config import Config +import terminatorlib.plugin as plugin +from terminatorlib.util import get_config_dir, err, dbg, gerr +from terminatorlib.terminator import Terminator +from terminatorlib import util + + +# AVAILABLE must contain a list of all the classes that you want exposed +AVAILABLE = ['SaveLastSessionLayout'] + +class SaveLastSessionLayout(plugin.Plugin): + capabilities = ['session'] + + config = None + conf_file = os.path.join(get_config_dir(),"save_last_session_cwd") + conf_sessions = [] + emit_close_count = 0 + + def __init__(self): + dbg("SaveLastSessionLayout Init") + self.connect_signals() + + #not used, but capability + def load_session_layout(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=None): + dbg("SaveLastSessionLayout load layout") + terminator = Terminator() + util.spawn_new_terminator(terminator.origcwd, ['-u', '-l', 'SaveLastSessionLayout']) + + def save_session_layout(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=None): + + config = Config() + terminator = Terminator() + current_layout = terminator.describe_layout(save_cwd = True) + dbg("SaveLastSessionLayout: save layout(%s)" % str(current_layout)) + res = config.replace_layout("SaveLastSessionLayout", current_layout) + if (not res): + r = config.add_layout("SaveLastSessionLayout", current_layout) + config.save() + return True + + def connect_signals(self): + dbg("SaveLastSessionLayout connect_signals") + n = 0 + for term in Terminator().terminals: + dbg("SaveLastSessionLayout connect_signals to term num:(%d)" % n) + n = n + 1 + term.connect('close-term', self.close, None) + #Can connect signal from terminal + #term.connect('load-layout', self.load_session_layout, None) + + def close(self, term, event, arg1 = None): + if (self.emit_close_count == 0): + self.emit_close_count = self.emit_close_count + 1 + self.save_session_layout("", "") + + def connect_signals_delayed(self, term, event, arg1 = None): + def add_watch(self): + self.connect_signals() + return False + GObject.idle_add(add_watch, self) + return True + diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 101f609cc..c3502495a 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1717,7 +1717,7 @@ def on_bell_cleanup(self, widget, alloc): widget.get_window().process_updates(True) return False - def describe_layout(self, count, parent, global_layout, child_order): + def describe_layout(self, count, parent, global_layout, child_order, save_cwd = False): """Describe our layout""" layout = {'type': 'Terminal', 'parent': parent, 'order': child_order} if self.group: @@ -1730,6 +1730,8 @@ def describe_layout(self, count, parent, global_layout, child_order): if title: layout['title'] = title layout['uuid'] = self.uuid + if save_cwd: + layout['directory'] = self.get_cwd() name = 'terminal%d' % count count = count + 1 global_layout[name] = layout diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index fbea2adbf..67e9da44c 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -617,13 +617,13 @@ def focus_changed(self, widget): def focus_left(self, widget): self.last_focused_term=widget - def describe_layout(self): + def describe_layout(self, save_cwd = False): """Describe our current layout""" layout = {} count = 0 for window in self.windows: parent = '' - count = window.describe_layout(count, parent, layout, 0) + count = window.describe_layout(count, parent, layout, 0, save_cwd) return(layout) From e7f9c731e89245406f683302ac450e5cc86eb2d2 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sun, 16 Oct 2022 01:47:36 +0530 Subject: [PATCH 013/101] - bug context menu (right click)->layouts->"Layout Name" always selects the last Layout - fixed so the right layout is picked and loaded --- terminatorlib/terminal_popup_menu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 7c483fda0..1d576463f 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -252,5 +252,5 @@ def add_layout_launcher(self, menu): layouts = self.config.list_layouts() for layout in layouts: item = Gtk.MenuItem(layout) - item.connect('activate', lambda x: spawn_new_terminator(self.terminator.origcwd, ['-u', '-l', layout])) + item.connect('activate', lambda x: spawn_new_terminator(self.terminator.origcwd, ['-u', '-l', x.get_label()])) submenu.append(item) From 6557ad54509c2f4e0f3a6e5494072121cec64748 Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Wed, 19 Oct 2022 09:32:14 -0400 Subject: [PATCH 014/101] update translations --- po/fr.po | 274 +++++++++++++--------------------------------- po/terminator.pot | 14 +-- 2 files changed, 81 insertions(+), 207 deletions(-) diff --git a/po/fr.po b/po/fr.po index c072240d8..7c46fc355 100644 --- a/po/fr.po +++ b/po/fr.po @@ -2,26 +2,26 @@ # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. -# +# # Translators: # Gnome Terminator , 2020 # Samuël Weber/GwendalD , 2020 -# +# fred lulu, 2022 +# #, fuzzy msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-22 00:51+0100\n" +"POT-Creation-Date: 2022-10-19 09:28-0400\n" "PO-Revision-Date: 2020-04-22 08:11+0000\n" -"Last-Translator: Samuël Weber/GwendalD , 2020\n" -"Language-Team: French (https://www.transifex.com/terminator/teams/109338/" -"fr/)\n" -"Language: fr\n" +"Last-Translator: fred lulu, 2022\n" +"Language-Team: French (https://www.transifex.com/terminator/teams/109338/fr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: nplurals=2; plural=(n > 1);\n" +"Language: fr\n" +"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n" #. Command uuid req. Description #: ../remotinator.py:39 @@ -46,7 +46,7 @@ msgstr "Avoir la liste de tous les terminaux." #: ../remotinator.py:44 msgid "Get the uuid of the current focused terminal" -msgstr "" +msgstr "Obtenir L'uuid du terminal actuellement actif" #: ../remotinator.py:45 msgid "Get the UUID of a parent window" @@ -58,31 +58,31 @@ msgstr "Obtenir le titre de la fenêtre parente" #: ../remotinator.py:47 msgid "Get the UUID of a parent tab" -msgstr "Obtenir l'UUID d'une table parente" +msgstr "Obtenir l'UUID d'un onglet parent" #: ../remotinator.py:48 msgid "Get the title of a parent tab" -msgstr "Obtenir le titre d'une table parente" +msgstr "Obtenir le titre d'une onglet parent" #: ../remotinator.py:49 msgid "Set the title of a parent tab" -msgstr "" +msgstr "Définir le titre d'un onglet parent" #: ../remotinator.py:50 msgid "Set the background image" -msgstr "" +msgstr "Définir l'image de fond" #: ../remotinator.py:51 msgid "Set the background image for all terminals" -msgstr "" +msgstr "Définir l'image de fond pour tous les terminaux" #: ../remotinator.py:52 msgid "Switch current terminal profile" -msgstr "" +msgstr "Changer le profil du terminal actuel" #: ../remotinator.py:53 msgid "Switch profile of all currently running terminals" -msgstr "" +msgstr "Changer le profil de tous les terminaux actuellement exécutés" #: ../remotinator.py:70 #, python-format @@ -111,23 +111,25 @@ msgstr "" #: ../remotinator.py:80 msgid "Profile name to switch to" -msgstr "" +msgstr "Nom du profil sur lequel basculer" #: ../remotinator.py:83 msgid "File to pass to command" -msgstr "" +msgstr "Fichier à passer à la commande" #: ../remotinator.py:86 msgid "Command to run in new terminal" -msgstr "" +msgstr "Commande à exécuter dans un nouveau terminal" #: ../remotinator.py:89 msgid "Tab name to set. Only used with \"set_tab_title\" command." msgstr "" +"Nom de l'onglet à définir. Utilisable seulement avec la commande " +"\"set_tab_title\"." #: ../remotinator.py:92 msgid "Tab name to set." -msgstr "" +msgstr "Nom de l'onglet à définir." #: ../data/terminator.desktop.in.h:1 ../data/terminator.appdata.xml.in.h:1 #: ../terminatorlib/plugins/activitywatch.py:83 @@ -149,8 +151,8 @@ msgstr "Le futur robot des terminaux." msgid "" "A power-user tool for arranging terminals. It is inspired by programs such " "as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging " -"terminals in grids (tabs is the most common default method, which Terminator " -"also supports)." +"terminals in grids (tabs is the most common default method, which Terminator" +" also supports)." msgstr "" "Un outil pour utilisateur et utilisatrice expérimenté⋅e d'organisation des " "terminaux. Il s'inspire des programmes tels que gnome-multi-term, " @@ -369,14 +371,16 @@ msgstr "Si Terminator est déjà lancé, ouvrir seulement un nouvel onglet" #: ../terminatorlib/optionparse.py:98 msgid "If Terminator is already running, just unhide all hidden windows" msgstr "" +"SI Terminator est déjà en exécution, faire juste réapparaître toute les " +"fenêtres cachées" #: ../terminatorlib/optionparse.py:100 msgid "List all profiles" -msgstr "" +msgstr "Lister tous les profils" #: ../terminatorlib/optionparse.py:102 msgid "List all layouts" -msgstr "" +msgstr "Lister toutes les mises en pages" #: ../terminatorlib/plugins/activitywatch.py:54 msgid "Watch for _activity" @@ -494,7 +498,7 @@ msgstr "Le nom *%s* existe déjà" #: ../terminatorlib/plugins/dir_open.py:26 msgid "Open current directory" -msgstr "" +msgstr "Ouvrir le répertoire actuel" #: ../terminatorlib/plugins/logger.py:21 #: ../terminatorlib/plugins/terminalshot.py:21 @@ -764,15 +768,15 @@ msgstr "Presse-papier" #: ../terminatorlib/preferences.glade.h:62 msgid "Clear selection on copy" -msgstr "" +msgstr "Effacer la sélection à la copie" #: ../terminatorlib/preferences.glade.h:63 msgid "Open links with a single click (instead of Ctrl-left click)" -msgstr "" +msgstr "Ouvrir les liens avec un simple clic (au lieu de Crtl + clic gauche)" #: ../terminatorlib/preferences.glade.h:64 msgid "Disable mouse paste" -msgstr "" +msgstr "Désactiver le coller de la souris" #: ../terminatorlib/preferences.glade.h:65 msgid "Custom URL handler:" @@ -800,11 +804,11 @@ msgstr "Personnalisation extra (Suivant le thème)" #: ../terminatorlib/preferences.glade.h:71 msgid "Cell Height:" -msgstr "" +msgstr "Hauteur de la cellule:" #: ../terminatorlib/preferences.glade.h:72 msgid "Cell Width:" -msgstr "" +msgstr "Largeur de la cellule:" #: ../terminatorlib/preferences.glade.h:73 msgid "Tab position:" @@ -876,11 +880,11 @@ msgstr "Clignotement" #: ../terminatorlib/preferences.glade.h:90 msgid "Use default colors" -msgstr "" +msgstr "Utiliser les couleurs par défaut" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "" +msgstr "Premier plan:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" @@ -940,11 +944,11 @@ msgstr "_Palettes prédéfinies :" #: ../terminatorlib/preferences.glade.h:107 msgid "_Foreground:" -msgstr "" +msgstr "_Premier plan:" #: ../terminatorlib/preferences.glade.h:108 msgid "_Background:" -msgstr "" +msgstr "_Arrière plan:" #: ../terminatorlib/preferences.glade.h:109 msgid "Palette" @@ -976,11 +980,11 @@ msgstr "Arrière-plan _transparent" #: ../terminatorlib/preferences.glade.h:116 msgid "Background Image" -msgstr "" +msgstr "Image d'arrière plan" #: ../terminatorlib/preferences.glade.h:117 msgid "Background Image File:" -msgstr "" +msgstr "Fichier de l'image d'arrière plan:" #: ../terminatorlib/preferences.glade.h:118 msgid "Choose file" @@ -988,7 +992,7 @@ msgstr "Choisir un fichier" #: ../terminatorlib/preferences.glade.h:119 msgid "S_hade background:" -msgstr "" +msgstr "Arrière plan nuancé:" #: ../terminatorlib/preferences.glade.h:120 msgid "None" @@ -1034,13 +1038,13 @@ msgstr "Défilement" msgid "" "Note: These options may cause some applications to behave " "incorrectly. They are only here to allow you to work around certain " -"applications and operating systems that expect different terminal behavior." +"applications and operating systems that expect different terminal " +"behavior." msgstr "" "Note : ces options peuvent gêner le fonctionnement de " -"certaines applications. Elles sont seulement là pour vous permettre de faire " -"fonctionner certaines applications et systèmes d'exploitation qui attendent " -"un comportement du terminal différent." +"certaines applications. Elles sont seulement là pour vous permettre de faire" +" fonctionner certaines applications et systèmes d'exploitation qui attendent" +" un comportement du terminal différent." #: ../terminatorlib/preferences.glade.h:131 msgid "_Backspace key generates:" @@ -1084,7 +1088,7 @@ msgstr "Choisissez une police de caractères pour la barre de titre" #: ../terminatorlib/preferences.glade.h:141 msgid "Titlebar" -msgstr "" +msgstr "Barre de titre:" #: ../terminatorlib/preferences.glade.h:142 #: ../terminatorlib/terminal_popup_menu.py:204 @@ -1137,33 +1141,17 @@ msgstr "Greffons" #: ../terminatorlib/preferences.glade.h:158 msgid "Version: 2.1.1" -msgstr "" +msgstr "Version: 2.1.1" #: ../terminatorlib/preferences.glade.h:159 msgid "" -"The goal of this project is to produce a useful tool for arranging " -"terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, " -"etc. in that the main focus is arranging terminals in grids (tabs is the " -"most common default method, which Terminator also supports).\n" +"The goal of this project is to produce a useful tool for arranging terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging terminals in grids (tabs is the most common default method, which Terminator also supports).\n" "\n" -"Much of the behavior of Terminator is based on GNOME Terminal, and we are " -"adding more features from that as time goes by, but we also want to extend " -"out in different directions with useful features for sysadmins and other " -"users. If you have any suggestions, please file wishlist bugs! (see left for " -"the Development link)" +"Much of the behavior of Terminator is based on GNOME Terminal, and we are adding more features from that as time goes by, but we also want to extend out in different directions with useful features for sysadmins and other users. If you have any suggestions, please file wishlist bugs! (see left for the Development link)" msgstr "" -"Le but de ce projet est de créer un outil puissant pour gèrer les terminaux. " -"Il est inspiré de programmes tels que gnome-multi-term, quadkonsole, etc. " -"car il se concentre aussi sur le fait de présenter les terminaux en grille " -"(les onglets sont la méthode par défaut la plus répandue, ce qui est " -"également supporté par terminator).\n" +"Le but de ce projet est de créer un outil puissant pour gèrer les terminaux. Il est inspiré de programmes tels que gnome-multi-term, quadkonsole, etc. car il se concentre aussi sur le fait de présenter les terminaux en grille (les onglets sont la méthode par défaut la plus répandue, ce qui est également supporté par terminator).\n" "\n" -"Une grande partie du comportement de Terminator est basée sur le terminal " -"GNOME, nous ajoutons de nouvelles fonctionnalités au fil du temps, mais nous " -"désirons également nous étendre dans différentes directions avec des " -"capacités utiles aux administrateurs système et aux autres utilisateurs. Si " -"vous avez des suggestions, merci de remplir un bug de souhait! (regardez a " -"gauche pour le lien de développement)" +"Une grande partie du comportement de Terminator est basée sur le terminal GNOME, nous ajoutons de nouvelles fonctionnalités au fil du temps, mais nous désirons également nous étendre dans différentes directions avec des capacités utiles aux administrateurs système et aux autres utilisateurs. Si vous avez des suggestions, merci de remplir un bug de souhait! (regardez a gauche pour le lien de développement)" #: ../terminatorlib/preferences.glade.h:162 msgid "The Manual" @@ -1172,13 +1160,10 @@ msgstr "Le manuel" #: ../terminatorlib/preferences.glade.h:163 msgid "" "Development\n" -"Bugs / " -"Enhancements" +"Bugs / Enhancements" msgstr "" -"Développement\n" -"Bugs / " -"Améliorations" +"Développement\n" +"Bugs / Améliorations" #: ../terminatorlib/preferences.glade.h:165 msgid "About" @@ -1198,15 +1183,15 @@ msgstr "Restaurer la taille d'origine de la police de caractères" #: ../terminatorlib/prefseditor.py:107 msgid "Increase font size on all terminals" -msgstr "" +msgstr "Augmenter la taille de la police sur tous les terminaux" #: ../terminatorlib/prefseditor.py:108 msgid "Decrease font size on all terminals" -msgstr "" +msgstr "Diminuer la taille de la police sur tous les terminaux" #: ../terminatorlib/prefseditor.py:109 msgid "Restore original font size on all terminals" -msgstr "" +msgstr "Restaurer la police originale sur tous les terminaux" #: ../terminatorlib/prefseditor.py:110 msgid "Create a new tab" @@ -1266,7 +1251,7 @@ msgstr "Coller le contenu du presse-papier" #: ../terminatorlib/prefseditor.py:126 msgid "Paste primary selection" -msgstr "" +msgstr "Coller la sélection primaire" #: ../terminatorlib/prefseditor.py:127 msgid "Show/Hide the scrollbar" @@ -1418,15 +1403,15 @@ msgstr "Dégrouper tous les terminaux" #: ../terminatorlib/prefseditor.py:164 msgid "Group terminals in window" -msgstr "" +msgstr "Grouper les terminaux dans une fenêtre" #: ../terminatorlib/prefseditor.py:165 msgid "Group/Ungroup terminals in window" -msgstr "" +msgstr "Grouper/Dégrouper les terminaux dans une fenêtre" #: ../terminatorlib/prefseditor.py:166 msgid "Ungroup terminals in window" -msgstr "" +msgstr "Dégrouper les terminaux dans une fenêtre" #: ../terminatorlib/prefseditor.py:167 msgid "Group terminals in tab" @@ -1500,11 +1485,11 @@ msgstr "Ouvrir les préférences" msgid "Open the manual" msgstr "Ouvrir le manuel" -#: ../terminatorlib/prefseditor.py:1370 +#: ../terminatorlib/prefseditor.py:1366 msgid "New Profile" msgstr "Nouveau profil" -#: ../terminatorlib/prefseditor.py:1413 ../terminatorlib/prefseditor.py:1418 +#: ../terminatorlib/prefseditor.py:1409 ../terminatorlib/prefseditor.py:1414 msgid "New Layout" msgstr "Nouvel agencement" @@ -1551,7 +1536,7 @@ msgstr "C_oller" #: ../terminatorlib/terminal_popup_menu.py:112 msgid "Set W_indow Title" -msgstr "" +msgstr "Définir Titre de la F_enêtre" #: ../terminatorlib/terminal_popup_menu.py:117 msgid "Split H_orizontally" @@ -1591,7 +1576,7 @@ msgstr "Regroupement" #: ../terminatorlib/terminal_popup_menu.py:186 msgid "Relaunch Command" -msgstr "" +msgstr "Relancer la commande" #: ../terminatorlib/terminal_popup_menu.py:191 msgid "Show _scrollbar" @@ -1616,11 +1601,11 @@ msgstr "Supprimer le groupe %s" #: ../terminatorlib/terminal.py:512 msgid "G_roup all in window" -msgstr "" +msgstr "Tout g_rouper sans une fenêtre" #: ../terminatorlib/terminal.py:517 msgid "Ungro_up all in window" -msgstr "" +msgstr "Tout dégro_uper dans une fenêtre" #: ../terminatorlib/terminal.py:522 msgid "G_roup all in tab" @@ -1667,25 +1652,25 @@ msgstr "_Insérer le numéro du terminal" msgid "Insert _padded terminal number" msgstr "Insérer le _numéro du terminal" -#: ../terminatorlib/terminal.py:1490 +#: ../terminatorlib/terminal.py:1492 msgid "Unable to find a shell" msgstr "Impossible de trouver un shell" -#: ../terminatorlib/terminal.py:1521 +#: ../terminatorlib/terminal.py:1546 msgid "Unable to start shell:" msgstr "Impossible de démarrer le shell :" -#: ../terminatorlib/terminal.py:1975 +#: ../terminatorlib/terminal.py:2000 msgid "Rename Window" msgstr "Renommer la fenêtre" -#: ../terminatorlib/terminal.py:1983 +#: ../terminatorlib/terminal.py:2008 msgid "Enter a new title for the Terminator window..." msgstr "Saisir un nouveau titre pour la fenêtre Terminator..." #: ../terminatorlib/titlebar.py:112 msgid "[INACTIVE: Right-Click for Relaunch option] " -msgstr "" +msgstr "[INACTIF: Clic Droit pour Relancer l'option]" #: ../terminatorlib/titlebar.py:258 msgid "Alpha" @@ -1790,120 +1775,9 @@ msgstr "fenêtre" #: ../terminatorlib/window.py:773 #, python-format msgid "Window group %s" -msgstr "" +msgstr "Groupe de fenêtres %s" #: ../terminatorlib/window.py:799 #, python-format msgid "Tab %d" msgstr "Onglet %d" - -#~ msgid "Current Locale" -#~ msgstr "Locale actuelle" - -#~ msgid "Western" -#~ msgstr "Occidentale" - -#~ msgid "Central European" -#~ msgstr "Europe centrale" - -#~ msgid "South European" -#~ msgstr "Europe du Sud" - -#~ msgid "Baltic" -#~ msgstr "Balte" - -#~ msgid "Cyrillic" -#~ msgstr "Cyrillique" - -#~ msgid "Arabic" -#~ msgstr "Arabe" - -#~ msgid "Greek" -#~ msgstr "Grec" - -#~ msgid "Hebrew Visual" -#~ msgstr "Hébreu visuel" - -#~ msgid "Hebrew" -#~ msgstr "Hébreu" - -#~ msgid "Turkish" -#~ msgstr "Turc" - -#~ msgid "Nordic" -#~ msgstr "Nordique" - -#~ msgid "Celtic" -#~ msgstr "Celte" - -#~ msgid "Romanian" -#~ msgstr "Roumain" - -#~ msgid "Unicode" -#~ msgstr "Unicode" - -#~ msgid "Armenian" -#~ msgstr "Arménien" - -#~ msgid "Chinese Traditional" -#~ msgstr "Chinois traditionnel" - -#~ msgid "Cyrillic/Russian" -#~ msgstr "Cyrillique/russe" - -#~ msgid "Japanese" -#~ msgstr "Japonais" - -#~ msgid "Korean" -#~ msgstr "Coréen" - -#~ msgid "Chinese Simplified" -#~ msgstr "Chinois simplifié" - -#~ msgid "Georgian" -#~ msgstr "Géorgien" - -#~ msgid "Cyrillic/Ukrainian" -#~ msgstr "Cyrillique/ukrainien" - -#~ msgid "Croatian" -#~ msgstr "Croate" - -#~ msgid "Hindi" -#~ msgstr "Hindi" - -#~ msgid "Persian" -#~ msgstr "Persan" - -#~ msgid "Gujarati" -#~ msgstr "Gujarati" - -#~ msgid "Gurmukhi" -#~ msgstr "Gurmukhi" - -#~ msgid "Icelandic" -#~ msgstr "Islandais" - -#~ msgid "Vietnamese" -#~ msgstr "Vietnamien" - -#~ msgid "Thai" -#~ msgstr "Thaï" - -#~ msgid "Line Height:" -#~ msgstr "Hauteur de ligne :" - -#~ msgid "Encoding:" -#~ msgstr "Codage des caractères :" - -#~ msgid "Encodings" -#~ msgstr "Codages" - -#~ msgid "Default" -#~ msgstr "Valeur par défaut" - -#~ msgid "User defined" -#~ msgstr "Défini par l'utilisateur" - -#~ msgid "Other Encodings" -#~ msgstr "Autres codages" diff --git a/po/terminator.pot b/po/terminator.pot index 9c7a019d2..7e9a84633 100644 --- a/po/terminator.pot +++ b/po/terminator.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-22 00:55+0100\n" +"POT-Creation-Date: 2022-10-19 09:29-0400\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -1445,11 +1445,11 @@ msgstr "" msgid "Open the manual" msgstr "" -#: ../terminatorlib/prefseditor.py:1370 +#: ../terminatorlib/prefseditor.py:1366 msgid "New Profile" msgstr "" -#: ../terminatorlib/prefseditor.py:1413 ../terminatorlib/prefseditor.py:1418 +#: ../terminatorlib/prefseditor.py:1409 ../terminatorlib/prefseditor.py:1414 msgid "New Layout" msgstr "" @@ -1612,19 +1612,19 @@ msgstr "" msgid "Insert _padded terminal number" msgstr "" -#: ../terminatorlib/terminal.py:1490 +#: ../terminatorlib/terminal.py:1492 msgid "Unable to find a shell" msgstr "" -#: ../terminatorlib/terminal.py:1521 +#: ../terminatorlib/terminal.py:1546 msgid "Unable to start shell:" msgstr "" -#: ../terminatorlib/terminal.py:1975 +#: ../terminatorlib/terminal.py:2000 msgid "Rename Window" msgstr "" -#: ../terminatorlib/terminal.py:1983 +#: ../terminatorlib/terminal.py:2008 msgid "Enter a new title for the Terminator window..." msgstr "" From c447ae02016405ff69b20c198556c820baee14f2 Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Wed, 19 Oct 2022 09:48:45 -0400 Subject: [PATCH 015/101] Release version 2.1.2 --- AUTHORS | 20 ++++ CHANGELOG.md | 168 +++++++++++++++++++++++++++++++- terminatorlib/preferences.glade | 2 +- terminatorlib/version.py | 2 +- 4 files changed, 189 insertions(+), 3 deletions(-) diff --git a/AUTHORS b/AUTHORS index 781d47f81..5049df0b1 100644 --- a/AUTHORS +++ b/AUTHORS @@ -5,6 +5,7 @@ This list is generated from the GIT log. * Aaron Faanes * Adrian A * Alexey Sokolov +* amaan khan * Andrea Corbellini * Andre Hilsendeger * Andrew Felske @@ -16,15 +17,18 @@ This list is generated from the GIT log. * Brian Murray * Bruno Braga * Bryce Harrington +* caprinux <123jinkai@gmail.com> * Chacal * Chris James * Chris Jones +* coder * Cory Kontros * Daniel Napora * Daniel T Chen * David Caro Estévez * David Levanon * David Sowder +* Dennis Benzinger | SAP Hybris * dkmvs <67212386+dkmvs@users.noreply.github.com> * Dmitry Soldatov * Douglas Bacon @@ -46,6 +50,7 @@ This list is generated from the GIT log. * Ivar Smolin * Jakub Vaněk * Jamu Kakar +* Jay W * Jean-Sebastien Trottier * Joe Peled * Jonas L @@ -57,25 +62,33 @@ This list is generated from the GIT log. * Julien Nicoulaud * Julien Thewys * Kees Cook +* kocho1984 * Leandro Thimóteo * Lucian Adrian Grijincu * Mackenzie Morgan +* Mark Timarev * Markus Frosch * Markus Korn +* Matthew Rose * Matt Rose * milotype <43657314+milotype@users.noreply.github.com> +* MuhammadJivani * Nathan Handler * Nathaniel M. Beaver * Nathaniel Morck Beaver * Neal Fultz * Nicolas Valcárcel +* nojhan +* ozzdemir * Pavel Khlebovich +* Paweł Kotiuk * Peter B. Jørgensen * Peter Bjørn Jørgensen * Peter Lind * Phi * planet36 * Przemek Wesolek +* Rafael Kitover * Roberto Aguilar * robertoetcheverryr * R the Troublemaker <5971066+br0kenbuild@users.noreply.github.com> @@ -84,13 +97,20 @@ This list is generated from the GIT log. * Siegfried-Angel Gevatter Pujals * Simeon Simeonov * Stephen Boddy +* StephenPeringer * thebigs * Thomas Hurst * Thomas Meire * Tomek Sabała +* Tom Yan * Tony Baker +* Vojtech Duchon (Ext) +* Vulcalien +* Vulcalien * waldner +* xuezhixin * Yousof +* Yusuf Güngör ## Other contributors diff --git a/CHANGELOG.md b/CHANGELOG.md index abe4a3e8a..5ae87f9fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,171 @@ # Changelog -## [v2.1.1](https://github.com/gnome-terminator/terminator/tree/v2.1.1) (2021-04-01) +## [v2.1.2](https://github.com/gnome-terminator/terminator/tree/v2.1.2) (2022-10-19) + +[Full Changelog](https://github.com/gnome-terminator/terminator/compare/v2.1.1...v2.1.2) + +**Implemented enhancements:** + +- \[Feature request\] move layout/session definitions into separate files with a dedicated extension in a dedicated directory [\#604](https://github.com/gnome-terminator/terminator/issues/604) +- Bash completion [\#495](https://github.com/gnome-terminator/terminator/issues/495) +- Changing cursor foreground color [\#467](https://github.com/gnome-terminator/terminator/issues/467) +- Wallpaper configuration option from terminal [\#466](https://github.com/gnome-terminator/terminator/issues/466) +- Launch a new command in a vertical or horizontal split. [\#446](https://github.com/gnome-terminator/terminator/issues/446) +- Separators is wider after upgrading to ubuntu 21.04 [\#445](https://github.com/gnome-terminator/terminator/issues/445) +- Broadcast profile changes to existing terminals [\#421](https://github.com/gnome-terminator/terminator/issues/421) +- How to deactivate the middle mouse button paste? [\#415](https://github.com/gnome-terminator/terminator/issues/415) +- Feature request: expose the window and terminal title setting features in context menu [\#405](https://github.com/gnome-terminator/terminator/issues/405) +- Integrate --layout-json command line parameter so that it can be passed to dbus [\#401](https://github.com/gnome-terminator/terminator/issues/401) +- Feature request: move titlebar colors config to profiles, rather than global settings [\#379](https://github.com/gnome-terminator/terminator/issues/379) +- Visual aids [\#367](https://github.com/gnome-terminator/terminator/issues/367) +- Feature Request: detach tab [\#302](https://github.com/gnome-terminator/terminator/issues/302) +- Pls add version on OS X [\#283](https://github.com/gnome-terminator/terminator/issues/283) + +**Fixed bugs:** + +- Ctrl+Shift+Mouse-Scroll triggers Ctrl+Mouse Scroll [\#606](https://github.com/gnome-terminator/terminator/issues/606) +- None isn't a valid value of keybindings config anymore [\#548](https://github.com/gnome-terminator/terminator/issues/548) +- psutil.AccessDenied: psutil.AccessDenied \(pid=1\) [\#539](https://github.com/gnome-terminator/terminator/issues/539) +- Find functionality does not show matches on same line [\#511](https://github.com/gnome-terminator/terminator/issues/511) +- Ratio and/or position on a config file's layout ignored [\#433](https://github.com/gnome-terminator/terminator/issues/433) +- Black background remains after hide\_window [\#425](https://github.com/gnome-terminator/terminator/issues/425) +- Cannot create working config file with 5 terminals [\#409](https://github.com/gnome-terminator/terminator/issues/409) +- Terminal loses focus versus tab title [\#400](https://github.com/gnome-terminator/terminator/issues/400) +- Terminal title-bars are transparent on first start [\#392](https://github.com/gnome-terminator/terminator/issues/392) + +**Closed issues:** + +- Hide window in waybar [\#633](https://github.com/gnome-terminator/terminator/issues/633) +- Split window profile incorrect inheritance [\#631](https://github.com/gnome-terminator/terminator/issues/631) +- \[Question\] is there a way to prevent Terminator from dereferencing symbolic links? [\#617](https://github.com/gnome-terminator/terminator/issues/617) +- Terminator not working on RHEL 9 [\#616](https://github.com/gnome-terminator/terminator/issues/616) +- Is there a right-click menu in sway? [\#614](https://github.com/gnome-terminator/terminator/issues/614) +- Set Terminator tab title via command line [\#603](https://github.com/gnome-terminator/terminator/issues/603) +- Unable to launch KeyError: b'Rss:' [\#601](https://github.com/gnome-terminator/terminator/issues/601) +- Cannot view emoji [\#599](https://github.com/gnome-terminator/terminator/issues/599) +- Clickable filepath:rownumber [\#598](https://github.com/gnome-terminator/terminator/issues/598) +- Feature Request: set initial window size in preferences [\#593](https://github.com/gnome-terminator/terminator/issues/593) +- Update the authorship in README [\#586](https://github.com/gnome-terminator/terminator/issues/586) +- xbindkeys doesn't work in Terminator, but works in other apps [\#582](https://github.com/gnome-terminator/terminator/issues/582) +- Unable to load Keybinder module [\#580](https://github.com/gnome-terminator/terminator/issues/580) +- terminator for MacOS user [\#578](https://github.com/gnome-terminator/terminator/issues/578) +- UTF-8 character breaks terminator config file [\#577](https://github.com/gnome-terminator/terminator/issues/577) +- Terminator need to highlight search string [\#575](https://github.com/gnome-terminator/terminator/issues/575) +- Custom Commands NOT Working in Linux Mint 20.3 [\#573](https://github.com/gnome-terminator/terminator/issues/573) +- Can't add/remove terminal panes from layout editor [\#572](https://github.com/gnome-terminator/terminator/issues/572) +- Language not applied after build [\#569](https://github.com/gnome-terminator/terminator/issues/569) +- Moving Cursor Word By Word using ALT + Arrows [\#566](https://github.com/gnome-terminator/terminator/issues/566) +- Enabling "putty style paste" causes context menu to be unreachable with 2-button mouse [\#565](https://github.com/gnome-terminator/terminator/issues/565) +- Setting stty options [\#564](https://github.com/gnome-terminator/terminator/issues/564) +- Switch focus and splits don't work when terminal is zoomed [\#550](https://github.com/gnome-terminator/terminator/issues/550) +- Will terminator ever consider picking up ligature support? [\#543](https://github.com/gnome-terminator/terminator/issues/543) +- feature request: Implement line spacing as a configuration option [\#542](https://github.com/gnome-terminator/terminator/issues/542) +- Change separator color [\#538](https://github.com/gnome-terminator/terminator/issues/538) +- remotinator split and execute command — cannot determine uuid [\#537](https://github.com/gnome-terminator/terminator/issues/537) +- Split vertical keyboard don't work on debian 11 [\#535](https://github.com/gnome-terminator/terminator/issues/535) +- Vte.Terminal\(\).set\_encoding deprecated [\#534](https://github.com/gnome-terminator/terminator/issues/534) +- Fix Keyboard Input [\#533](https://github.com/gnome-terminator/terminator/issues/533) +- group broadcasting switched on/off for all groups [\#532](https://github.com/gnome-terminator/terminator/issues/532) +- Drop a file from nautilus onto terminator window no longer works \(it used to paste the path a la gnome terminal\) [\#530](https://github.com/gnome-terminator/terminator/issues/530) +- Crash everytime after encoding is changed to TCVN [\#529](https://github.com/gnome-terminator/terminator/issues/529) +- Change the color of the current tab to highlight it better [\#522](https://github.com/gnome-terminator/terminator/issues/522) +- Feature: Configuration to colorize split screens from default grey colour, Issue: Remove ability to select 0 and 1 handle\_size from configuration gui [\#518](https://github.com/gnome-terminator/terminator/issues/518) +- Error when using "Insert Terminal Number" \(Solved?\) [\#517](https://github.com/gnome-terminator/terminator/issues/517) +- Auto-scroll to the cursor position when typing [\#513](https://github.com/gnome-terminator/terminator/issues/513) +- hide\_window mapped with Shift+Control+Alt+$an\_alphabet catches Control+Alt+$an\_alphabet instead [\#509](https://github.com/gnome-terminator/terminator/issues/509) +- Cursor is blinking on inactive windows [\#508](https://github.com/gnome-terminator/terminator/issues/508) +- custom commands are not persisted [\#505](https://github.com/gnome-terminator/terminator/issues/505) +- Terminator slow to close if xclip was invoked [\#503](https://github.com/gnome-terminator/terminator/issues/503) +- terminator failing to open on ubuntu 21.04 [\#502](https://github.com/gnome-terminator/terminator/issues/502) +- Monospace Bold isn't working [\#497](https://github.com/gnome-terminator/terminator/issues/497) +- No prompt when closing terminator now, despite say vim running in terminal [\#496](https://github.com/gnome-terminator/terminator/issues/496) +- suppor for sixel graphics [\#492](https://github.com/gnome-terminator/terminator/issues/492) +- which is deprecated and should not be used [\#488](https://github.com/gnome-terminator/terminator/issues/488) +- could tmux Key bindings using in terminator? [\#474](https://github.com/gnome-terminator/terminator/issues/474) +- Support OpenType font features [\#473](https://github.com/gnome-terminator/terminator/issues/473) +- Crash on Terminal resize when using fish [\#458](https://github.com/gnome-terminator/terminator/issues/458) +- Incorrect layout sorting in notebook [\#453](https://github.com/gnome-terminator/terminator/issues/453) +- Coloring Tabs / Tabs Appearance [\#449](https://github.com/gnome-terminator/terminator/issues/449) +- Option to disable system notifications [\#448](https://github.com/gnome-terminator/terminator/issues/448) +- Window vanishes [\#447](https://github.com/gnome-terminator/terminator/issues/447) +- Multiple Terminator instances randomly crash on Ubuntu 20.04 [\#444](https://github.com/gnome-terminator/terminator/issues/444) +- Option to open URLs with just a click [\#434](https://github.com/gnome-terminator/terminator/issues/434) +- Doubled input from keyboard when broadcasting in tabs [\#432](https://github.com/gnome-terminator/terminator/issues/432) +- Does this tool support macOS Big Sur? [\#430](https://github.com/gnome-terminator/terminator/issues/430) +- terminator is slow [\#426](https://github.com/gnome-terminator/terminator/issues/426) +- Add more fundamental "editor-ish" feature [\#424](https://github.com/gnome-terminator/terminator/issues/424) +- Allow disabling and resetting keybindings in Preferences [\#423](https://github.com/gnome-terminator/terminator/issues/423) +- Project based layout [\#418](https://github.com/gnome-terminator/terminator/issues/418) +- Unable to Install from Source [\#412](https://github.com/gnome-terminator/terminator/issues/412) +- CTRL+A behaviour abnormal [\#384](https://github.com/gnome-terminator/terminator/issues/384) +- regexp/command hyperlink handler [\#381](https://github.com/gnome-terminator/terminator/issues/381) +- Update PPA to 2.1.0 [\#374](https://github.com/gnome-terminator/terminator/issues/374) +- Create Snap and Flatpak for Terminator [\#206](https://github.com/gnome-terminator/terminator/issues/206) +- Remove gtk-update-icon-cache handling in setup [\#102](https://github.com/gnome-terminator/terminator/issues/102) + +**Merged pull requests:** + +- update translations [\#656](https://github.com/gnome-terminator/terminator/pull/656) ([mattrose](https://github.com/mattrose)) +- Terminal ctrl+mousewheel: do not try to zoom if shift is pressed [\#609](https://github.com/gnome-terminator/terminator/pull/609) ([Vulcalien](https://github.com/Vulcalien)) +- More fixes to the Color pickers in the Preferences Editor [\#592](https://github.com/gnome-terminator/terminator/pull/592) ([mattrose](https://github.com/mattrose)) +- Modification in the /terminatorlib/prefseditor.py file [\#590](https://github.com/gnome-terminator/terminator/pull/590) ([amaan211](https://github.com/amaan211)) +- Various README fixes [\#588](https://github.com/gnome-terminator/terminator/pull/588) ([mattrose](https://github.com/mattrose)) +- Remove duplicated info in some debug messages [\#576](https://github.com/gnome-terminator/terminator/pull/576) ([Vulcalien](https://github.com/Vulcalien)) +- Added hotfix for \#78 that deletes GTK\_IM\_MODULE environment variable [\#574](https://github.com/gnome-terminator/terminator/pull/574) ([ozzdemir](https://github.com/ozzdemir)) +- Fix POTFILES.in + update translation files [\#571](https://github.com/gnome-terminator/terminator/pull/571) ([Vulcalien](https://github.com/Vulcalien)) +- Add initial flatpak-spawn support [\#570](https://github.com/gnome-terminator/terminator/pull/570) ([JayDoubleu](https://github.com/JayDoubleu)) +- Fix: handle\_size treated as cell\_width [\#561](https://github.com/gnome-terminator/terminator/pull/561) ([Vulcalien](https://github.com/Vulcalien)) +- Transifex translations from Dec 20 2021 [\#558](https://github.com/gnome-terminator/terminator/pull/558) ([mattrose](https://github.com/mattrose)) +- Unzoom terminal on interaction [\#553](https://github.com/gnome-terminator/terminator/pull/553) ([Vulcalien](https://github.com/Vulcalien)) +- Add ability to configure cell width \(font character spacing\) [\#552](https://github.com/gnome-terminator/terminator/pull/552) ([FernandoBasso](https://github.com/FernandoBasso)) +- Improve and optimize the code for background images [\#551](https://github.com/gnome-terminator/terminator/pull/551) ([Vulcalien](https://github.com/Vulcalien)) +- Fix: 'None' value for keybindings breaks editor [\#549](https://github.com/gnome-terminator/terminator/pull/549) ([Vulcalien](https://github.com/Vulcalien)) +- don't traceback while searching through /proc [\#546](https://github.com/gnome-terminator/terminator/pull/546) ([mattrose](https://github.com/mattrose)) +- os.environ does not have LANGUAGE in Centos8. [\#544](https://github.com/gnome-terminator/terminator/pull/544) ([xuezhixin](https://github.com/xuezhixin)) +- Remove Encoding settings \(deprecated\) [\#536](https://github.com/gnome-terminator/terminator/pull/536) ([Vulcalien](https://github.com/Vulcalien)) +- Allow multiline commands in Custom Commands plugin [\#525](https://github.com/gnome-terminator/terminator/pull/525) ([VDuchon](https://github.com/VDuchon)) +- Add paste\_selection keybinding. [\#520](https://github.com/gnome-terminator/terminator/pull/520) ([rkitover](https://github.com/rkitover)) +- Fix terminal separator size setting [\#519](https://github.com/gnome-terminator/terminator/pull/519) ([caprinux](https://github.com/caprinux)) +- Automatically focus the Keybindings menu [\#516](https://github.com/gnome-terminator/terminator/pull/516) ([Vulcalien](https://github.com/Vulcalien)) +- Fix hide\_window keybinding unset check [\#515](https://github.com/gnome-terminator/terminator/pull/515) ([tomty89](https://github.com/tomty89)) +- Add 'Disable mouse paste' [\#512](https://github.com/gnome-terminator/terminator/pull/512) ([Vulcalien](https://github.com/Vulcalien)) +- Bug Fix: hide\_window keybinding ignores Shift key [\#510](https://github.com/gnome-terminator/terminator/pull/510) ([Vulcalien](https://github.com/Vulcalien)) +- Improve argument parser + implement bash completion [\#506](https://github.com/gnome-terminator/terminator/pull/506) ([Vulcalien](https://github.com/Vulcalien)) +- add Set Window Title item to context menu [\#501](https://github.com/gnome-terminator/terminator/pull/501) ([mattrose](https://github.com/mattrose)) +- BugFix: terminal won't restart if there is no custom command [\#500](https://github.com/gnome-terminator/terminator/pull/500) ([Vulcalien](https://github.com/Vulcalien)) +- Add a "Copy" button to clone profiles [\#499](https://github.com/gnome-terminator/terminator/pull/499) ([Vulcalien](https://github.com/Vulcalien)) +- Make tabs detachable + minor bugfix [\#494](https://github.com/gnome-terminator/terminator/pull/494) ([Vulcalien](https://github.com/Vulcalien)) +- remove gtk-update-icon-cache from setup.py [\#493](https://github.com/gnome-terminator/terminator/pull/493) ([mattrose](https://github.com/mattrose)) +- remove vsplit\_cmd and hsplit\_cmd from ipc.py, superseded by newer hsp… [\#491](https://github.com/gnome-terminator/terminator/pull/491) ([mattrose](https://github.com/mattrose)) +- Update tr.po [\#490](https://github.com/gnome-terminator/terminator/pull/490) ([StephenPeringer](https://github.com/StephenPeringer)) +- add bg\_img and bg\_img\_all commands to remotinator [\#487](https://github.com/gnome-terminator/terminator/pull/487) ([mattrose](https://github.com/mattrose)) +- Cursor: make it possible to change foreground color \(\#467\) [\#486](https://github.com/gnome-terminator/terminator/pull/486) ([Vulcalien](https://github.com/Vulcalien)) +- fixes for --config-json [\#484](https://github.com/gnome-terminator/terminator/pull/484) ([mattrose](https://github.com/mattrose)) +- GUI: set all CheckButtons off to avoid blinking + remove grid empty rows/columns [\#482](https://github.com/gnome-terminator/terminator/pull/482) ([Vulcalien](https://github.com/Vulcalien)) +- Move titlebar settings to profiles \(\#379\) [\#481](https://github.com/gnome-terminator/terminator/pull/481) ([Vulcalien](https://github.com/Vulcalien)) +- Issue 365 [\#480](https://github.com/gnome-terminator/terminator/pull/480) ([mattrose](https://github.com/mattrose)) +- Fix typo in `po/de.po` [\#476](https://github.com/gnome-terminator/terminator/pull/476) ([dennis-benzinger-hybris](https://github.com/dennis-benzinger-hybris)) +- add parameters to remotinator split commands [\#472](https://github.com/gnome-terminator/terminator/pull/472) ([mattrose](https://github.com/mattrose)) +- add switch\_profile\_all command to remotinator [\#471](https://github.com/gnome-terminator/terminator/pull/471) ([mattrose](https://github.com/mattrose)) +- Set CAN\_FOCUS to False for notebook widgets [\#470](https://github.com/gnome-terminator/terminator/pull/470) ([marktimarev](https://github.com/marktimarev)) +- tell titlebar to start focussed out if it does not have focus [\#462](https://github.com/gnome-terminator/terminator/pull/462) ([mattrose](https://github.com/mattrose)) +- Update translation [\#460](https://github.com/gnome-terminator/terminator/pull/460) ([pktiuk](https://github.com/pktiuk)) +- Add new plugin for opening current directory using right mouse button [\#459](https://github.com/gnome-terminator/terminator/pull/459) ([pktiuk](https://github.com/pktiuk)) +- Fixed Issue \#425 \(hide\_window will try to show a destroyed window\) [\#456](https://github.com/gnome-terminator/terminator/pull/456) ([Vulcalien](https://github.com/Vulcalien)) +- Incorrect layout sorting in notebook [\#454](https://github.com/gnome-terminator/terminator/pull/454) ([AsadJivani](https://github.com/AsadJivani)) +- Closing tab on middle mouse button press [\#451](https://github.com/gnome-terminator/terminator/pull/451) ([kocho1984](https://github.com/kocho1984)) +- Bug Fix: 'Clear selection on copy' is always unchecked [\#443](https://github.com/gnome-terminator/terminator/pull/443) ([Vulcalien](https://github.com/Vulcalien)) +- Fixed issue \#433 \(layout sometimes ignores ratio\) [\#442](https://github.com/gnome-terminator/terminator/pull/442) ([Vulcalien](https://github.com/Vulcalien)) +- Fix the background image loading exception handling [\#436](https://github.com/gnome-terminator/terminator/pull/436) ([GerbenWelter](https://github.com/GerbenWelter)) +- Added set\_tab\_title command to remotinator. [\#435](https://github.com/gnome-terminator/terminator/pull/435) ([yusufgungor](https://github.com/yusufgungor)) +- Ukrainianized by 93% [\#428](https://github.com/gnome-terminator/terminator/pull/428) ([balac-ode](https://github.com/balac-ode)) +- Fixed geometry hints [\#416](https://github.com/gnome-terminator/terminator/pull/416) ([Vulcalien](https://github.com/Vulcalien)) +- Feat+run cmd on match [\#399](https://github.com/gnome-terminator/terminator/pull/399) ([nojhan](https://github.com/nojhan)) +- add feat: config to open links with single click [\#398](https://github.com/gnome-terminator/terminator/pull/398) ([nojhan](https://github.com/nojhan)) +- Add new vsplit hsplit cmd dbus [\#390](https://github.com/gnome-terminator/terminator/pull/390) ([TheBigS](https://github.com/TheBigS)) +- Added new get\_focused\_terminal dbus command which returns uuid of current focused terminal [\#389](https://github.com/gnome-terminator/terminator/pull/389) ([TheBigS](https://github.com/TheBigS)) + +## [v2.1.1](https://github.com/gnome-terminator/terminator/tree/v2.1.1) (2021-04-02) [Full Changelog](https://github.com/gnome-terminator/terminator/compare/v2.1.0...v2.1.1) @@ -43,6 +208,7 @@ **Merged pull requests:** +- Release version 2.1.1 [\#413](https://github.com/gnome-terminator/terminator/pull/413) ([mattrose](https://github.com/mattrose)) - i18n: pt\_BR: add missing space in translations with shortcuts [\#406](https://github.com/gnome-terminator/terminator/pull/406) ([terceiro](https://github.com/terceiro)) - Fixed race condition when calling grab\_focus after underlying vte could be closed [\#388](https://github.com/gnome-terminator/terminator/pull/388) ([TheBigS](https://github.com/TheBigS)) - disable 2.7 tests until we can figure out how to run them in GH [\#386](https://github.com/gnome-terminator/terminator/pull/386) ([mattrose](https://github.com/mattrose)) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 26d46b814..fbab963e8 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -3955,7 +3955,7 @@ True False - Version: 2.1.1 + Version: 2.1.2 False diff --git a/terminatorlib/version.py b/terminatorlib/version.py index 33f374312..c26d916a5 100644 --- a/terminatorlib/version.py +++ b/terminatorlib/version.py @@ -20,4 +20,4 @@ """ APP_NAME = 'terminator' -APP_VERSION = '2.1.1' +APP_VERSION = '2.1.2' From 270d4afb040375adda810216cf7a56786c527b47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Kotiuk?= <45544416+pktiuk@users.noreply.github.com> Date: Fri, 21 Oct 2022 16:41:21 +0200 Subject: [PATCH 016/101] docs: Change number of columns in repology badge It greatly improves visibility --- INSTALL.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/INSTALL.md b/INSTALL.md index b9ee5451e..ed0538a96 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -117,5 +117,5 @@ Ubuntu | copied from Debian | [launchpad.net/ubuntu] | | [bugs.launchpad.n A more extensive list can be found on Repology: -[![Packaging status](https://repology.org/badge/vertical-allrepos/terminator.svg)](https://repology.org/project/terminator/versions) +[![Packaging status](https://repology.org/badge/vertical-allrepos/terminator.svg?columns=3)](https://repology.org/project/terminator/versions) From 25111f24024e768e32466af396425c80d69f874f Mon Sep 17 00:00:00 2001 From: Kian-Meng Ang Date: Fri, 14 Oct 2022 21:35:55 +0800 Subject: [PATCH 017/101] Fix typos Found via `codespell -S .eggs,po,*.css -L boddy,maco,trough,wont,poing,gir,visibles` --- CHANGELOG.legacy.txt | 10 +++++----- CHANGELOG.md | 14 +++++++------- data/layout-files-examples/README.md | 2 +- terminatorlib/container.py | 2 +- terminatorlib/editablelabel.py | 2 +- terminatorlib/notebook.py | 2 +- terminatorlib/plugins/logger.py | 2 +- terminatorlib/plugins/run_cmd_on_match.py | 6 +++--- terminatorlib/preferences.glade | 2 +- terminatorlib/prefseditor.py | 4 ++-- terminatorlib/searchbar.py | 2 +- terminatorlib/terminal.py | 12 ++++++------ terminatorlib/terminator.py | 2 +- terminatorlib/util.py | 4 ++-- terminatorlib/window.py | 4 ++-- 15 files changed, 35 insertions(+), 35 deletions(-) diff --git a/CHANGELOG.legacy.txt b/CHANGELOG.legacy.txt index 4e18ee297..67db130b7 100644 --- a/CHANGELOG.legacy.txt +++ b/CHANGELOG.legacy.txt @@ -151,14 +151,14 @@ terminator 1.90: * Preselect the current layout when opening Prefs window, and also save config after using the layout 'Save' button (Steve Boddy) * Set some default shortcuts based on my preference (Steve Boddy) - * Add high contast icons, make the main window icon loading work + * Add high contrast icons, make the main window icon loading work better, and respect the theme changes (Steve Boddy, LP#305579) * Additional windows icon loading works better, and respect the theme changes (LP#305579) * Adjust the config section name to InactivityWatch for InactivityWatch class * Add a new setting for ActivityWatch to set the time between - activty notifications + activity notifications * BIG update to translations, due to additions and changes. * Make the random default group names translatable * Add and improve the mnemonics in the group menu @@ -170,7 +170,7 @@ terminator 1.90: * A few changes to doc strings to make the autodoc prettier * Added help shortcut, by default F1 to open the local manual * Added button to About tab (in Prefs window) to launch manual - * Small tweak to setup.py to seperate build and install, and + * Small tweak to setup.py to separate build and install, and always attempt to install manual by default. * Sort entries in config file, so they don't jump around every time config is saved for easier troubleshooting @@ -258,7 +258,7 @@ terminator 1.90: terminator class * Fix the scroll up/down key bindings to use gtk3 method * Fix getting the handle size (gtk2->gtk3 diff) - * Fix scrollbar doubleclick rebalancing (LP#1423686) + * Fix scrollbar double-click rebalancing (LP#1423686) * Fix allocations (no longer an attribute) when balancing (gtk2->gtk3 diff) * Fix allocations not having the x,y position just w,h (gtk3 bug? @@ -351,7 +351,7 @@ terminator 1.90: (Egmont Koblinger, LP#1518108) * Fix copy on selection to work on already open terminals (Egmont Koblinger, LP#1518109) - * Fix unwanted seperator size change, and increase granularity of + * Fix unwanted separator size change, and increase granularity of dim/transparent sliders (Egmont Koblinger, LP#1518114) * Fix cwd when new term spawned from a symlinked directory (Egmont Koblinger, LP#1518554) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5ae87f9fe..801befe23 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -67,7 +67,7 @@ - Fix Keyboard Input [\#533](https://github.com/gnome-terminator/terminator/issues/533) - group broadcasting switched on/off for all groups [\#532](https://github.com/gnome-terminator/terminator/issues/532) - Drop a file from nautilus onto terminator window no longer works \(it used to paste the path a la gnome terminal\) [\#530](https://github.com/gnome-terminator/terminator/issues/530) -- Crash everytime after encoding is changed to TCVN [\#529](https://github.com/gnome-terminator/terminator/issues/529) +- Crash every time after encoding is changed to TCVN [\#529](https://github.com/gnome-terminator/terminator/issues/529) - Change the color of the current tab to highlight it better [\#522](https://github.com/gnome-terminator/terminator/issues/522) - Feature: Configuration to colorize split screens from default grey colour, Issue: Remove ability to select 0 and 1 handle\_size from configuration gui [\#518](https://github.com/gnome-terminator/terminator/issues/518) - Error when using "Insert Terminal Number" \(Solved?\) [\#517](https://github.com/gnome-terminator/terminator/issues/517) @@ -79,7 +79,7 @@ - terminator failing to open on ubuntu 21.04 [\#502](https://github.com/gnome-terminator/terminator/issues/502) - Monospace Bold isn't working [\#497](https://github.com/gnome-terminator/terminator/issues/497) - No prompt when closing terminator now, despite say vim running in terminal [\#496](https://github.com/gnome-terminator/terminator/issues/496) -- suppor for sixel graphics [\#492](https://github.com/gnome-terminator/terminator/issues/492) +- support for sixel graphics [\#492](https://github.com/gnome-terminator/terminator/issues/492) - which is deprecated and should not be used [\#488](https://github.com/gnome-terminator/terminator/issues/488) - could tmux Key bindings using in terminator? [\#474](https://github.com/gnome-terminator/terminator/issues/474) - Support OpenType font features [\#473](https://github.com/gnome-terminator/terminator/issues/473) @@ -148,7 +148,7 @@ - add parameters to remotinator split commands [\#472](https://github.com/gnome-terminator/terminator/pull/472) ([mattrose](https://github.com/mattrose)) - add switch\_profile\_all command to remotinator [\#471](https://github.com/gnome-terminator/terminator/pull/471) ([mattrose](https://github.com/mattrose)) - Set CAN\_FOCUS to False for notebook widgets [\#470](https://github.com/gnome-terminator/terminator/pull/470) ([marktimarev](https://github.com/marktimarev)) -- tell titlebar to start focussed out if it does not have focus [\#462](https://github.com/gnome-terminator/terminator/pull/462) ([mattrose](https://github.com/mattrose)) +- tell titlebar to start focused out if it does not have focus [\#462](https://github.com/gnome-terminator/terminator/pull/462) ([mattrose](https://github.com/mattrose)) - Update translation [\#460](https://github.com/gnome-terminator/terminator/pull/460) ([pktiuk](https://github.com/pktiuk)) - Add new plugin for opening current directory using right mouse button [\#459](https://github.com/gnome-terminator/terminator/pull/459) ([pktiuk](https://github.com/pktiuk)) - Fixed Issue \#425 \(hide\_window will try to show a destroyed window\) [\#456](https://github.com/gnome-terminator/terminator/pull/456) ([Vulcalien](https://github.com/Vulcalien)) @@ -199,7 +199,7 @@ - Background image not showing up on Xubuntu 20.04 [\#364](https://github.com/gnome-terminator/terminator/issues/364) - Pasted text is highlighted [\#363](https://github.com/gnome-terminator/terminator/issues/363) - \[FR\] Option to elide terminal title from the left [\#362](https://github.com/gnome-terminator/terminator/issues/362) -- Windows title are not udpated after ssh session disconnected [\#359](https://github.com/gnome-terminator/terminator/issues/359) +- Windows title are not updated after ssh session disconnected [\#359](https://github.com/gnome-terminator/terminator/issues/359) - No broadcast menu in sway [\#357](https://github.com/gnome-terminator/terminator/issues/357) - Remove spaces between tabs [\#331](https://github.com/gnome-terminator/terminator/issues/331) - Enhancement: Stjerm Layout Like Functionality [\#298](https://github.com/gnome-terminator/terminator/issues/298) @@ -244,7 +244,7 @@ - The Alt+L layout chooser is too small [\#345](https://github.com/gnome-terminator/terminator/issues/345) - Open in Previous Location [\#337](https://github.com/gnome-terminator/terminator/issues/337) - How to install terminator without root privilege? [\#332](https://github.com/gnome-terminator/terminator/issues/332) -- Improve separator between splitted terminals [\#329](https://github.com/gnome-terminator/terminator/issues/329) +- Improve separator between split terminals [\#329](https://github.com/gnome-terminator/terminator/issues/329) - Using shift+Super+} for next\_tab key binding doesn't work [\#326](https://github.com/gnome-terminator/terminator/issues/326) - "Copy email address" actually doesn't quite do that [\#323](https://github.com/gnome-terminator/terminator/issues/323) - Can`t disable key binding [\#322](https://github.com/gnome-terminator/terminator/issues/322) @@ -354,7 +354,7 @@ With pull request #70, we removed the need for gettext binaries and switched to **Closed issues:** -- Feature Suggestion: Splitted screen shells based on parent [\#230](https://github.com/gnome-terminator/terminator/issues/230) +- Feature Suggestion: Split screen shells based on parent [\#230](https://github.com/gnome-terminator/terminator/issues/230) - Release 2.0 does not have signed assets [\#228](https://github.com/gnome-terminator/terminator/issues/228) - Some files install to the wrong location [\#227](https://github.com/gnome-terminator/terminator/issues/227) - Multi tab breaks transparent background [\#225](https://github.com/gnome-terminator/terminator/issues/225) @@ -423,7 +423,7 @@ With pull request #70, we removed the need for gettext binaries and switched to - Selecting first char of a line for copy-paste is impossible [\#191](https://github.com/gnome-terminator/terminator/issues/191) - Duplicate Key Bindings are Allowed in `Preferences > Keybindings` [\#190](https://github.com/gnome-terminator/terminator/issues/190) - Cannot open terminator windows with different configs [\#184](https://github.com/gnome-terminator/terminator/issues/184) -- Feature request: reenable broadcast keybindings and warn on their first use instead [\#183](https://github.com/gnome-terminator/terminator/issues/183) +- Feature request: re-enable broadcast keybindings and warn on their first use instead [\#183](https://github.com/gnome-terminator/terminator/issues/183) - Add Terminator version in About screen [\#169](https://github.com/gnome-terminator/terminator/issues/169) - Feature Request: Add hyperlink support [\#164](https://github.com/gnome-terminator/terminator/issues/164) - ctrl-alt-a activates even when terminal has no focus [\#163](https://github.com/gnome-terminator/terminator/issues/163) diff --git a/data/layout-files-examples/README.md b/data/layout-files-examples/README.md index 98ce65921..b8d0f4f94 100644 --- a/data/layout-files-examples/README.md +++ b/data/layout-files-examples/README.md @@ -1,6 +1,6 @@ The JSONs files in this directory are example config files used by `--config-json` option. -Once this feature would be documented officialy this directoy can be removed. +Once this feature would be documented officially this directory can be removed. Example: ``` diff --git a/terminatorlib/container.py b/terminatorlib/container.py index 53d4914cc..39df74af4 100644 --- a/terminatorlib/container.py +++ b/terminatorlib/container.py @@ -251,7 +251,7 @@ def describe_layout(self, count, parent, global_layout, child_order): maker = Factory() mytype = maker.type(self) if not mytype: - err('unable to detemine own type. %s' % self) + err('unable to determine own type. %s' % self) return({}) layout['type'] = mytype diff --git a/terminatorlib/editablelabel.py b/terminatorlib/editablelabel.py index edec7e210..ee6de0cd2 100644 --- a/terminatorlib/editablelabel.py +++ b/terminatorlib/editablelabel.py @@ -23,7 +23,7 @@ class EditableLabel(Gtk.EventBox): # pylint: disable-msg=W0212 # pylint: disable-msg=R0904 """ - An eventbox that partialy emulate a Gtk.Label + An eventbox that partially emulate a Gtk.Label On double-click or key binding the label is editable, entering an empty will revert back to automatic text """ diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index 7daccaa4e..e7a62eb88 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -239,7 +239,7 @@ def replace(self, oldwidget, newwidget): def get_child_metadata(self, widget): """Fetch the relevant metadata for a widget which we'd need - to recreate it when it's readded""" + to recreate it when it's re-added""" metadata = {} metadata['tabnum'] = self.page_num(widget) label = self.get_tab_label(widget) diff --git a/terminatorlib/plugins/logger.py b/terminatorlib/plugins/logger.py index a9850e8e2..8b3c721e4 100644 --- a/terminatorlib/plugins/logger.py +++ b/terminatorlib/plugins/logger.py @@ -101,7 +101,7 @@ def stop_logger(self, _widget, terminal): last_saved_row = self.loggers[vte_terminal]["row"] (col, row) = vte_terminal.get_cursor_position() if last_saved_col != col or last_saved_row != row: - # Save unwritten bufer to the file + # Save unwritten buffer to the file self.write_content(vte_terminal, last_saved_row, last_saved_col, row, col) fd = self.loggers[vte_terminal]["fd"] fd.close() diff --git a/terminatorlib/plugins/run_cmd_on_match.py b/terminatorlib/plugins/run_cmd_on_match.py index e90102034..d1aabcbab 100644 --- a/terminatorlib/plugins/run_cmd_on_match.py +++ b/terminatorlib/plugins/run_cmd_on_match.py @@ -16,7 +16,7 @@ AVAILABLE = ['RunCmdOnMatchMenu'] -# For example, open scripts names outputed by python in Vim at the given line number: +# For example, open scripts names outputted by python in Vim at the given line number: # match = r'\B(/\S+?\.py)\S{2}\sline\s(\d+)' # Python's log file matching # cmd = "gvim --servername IDE --remote +{1} {0}" @@ -61,7 +61,7 @@ def callback(self, url): try: runcmd = self.__class__.cmd.format(*groups) except Exception as e: - err("Exception occured while formating the command: {} {}".format(type(e).__name__, e)) + err("Exception occurred while formatting the command: {} {}".format(type(e).__name__, e)) dbg("run: {cmd}".format(cmd=runcmd)) subprocess.run(runcmd.split()) @@ -170,7 +170,7 @@ def _load_configured_handlers(self): rcom_name = "_RunCmdOnMatch_{}".format(key) # key is just the index # Make a handler class. RCOM = MetaRCOM(rcom_name, handler["regexp"], handler["command"]) - # Instanciate the class. + # Instantiate the class. setattr(me, rcom_name, RCOM) if rcom_name not in AVAILABLE: diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index fbab963e8..b6f442857 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -1006,7 +1006,7 @@ - Extra Styling (Theme dependant) + Extra Styling (Theme dependent) False True True diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 75f42559d..10339c304 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -666,7 +666,7 @@ def on_palette_click(event, data, widget=widget): # Scrollback infinite widget = guiget('scrollback_infinite') widget.set_active(self.config['scrollback_infinite']) - # Scroll on outut + # Scroll on output widget = guiget('scroll_on_output_checkbutton') widget.set_active(self.config['scroll_on_output']) # Scroll on keystroke @@ -1219,7 +1219,7 @@ def on_title_inactive_bg_color_color_set(self, widget): self.config.save() def on_title_transmit_bg_color_color_set(self, widget): - """Title transmit backgruond colour changed""" + """Title transmit background colour changed""" self.config['title_transmit_bg_color'] = color2hex(widget) self.config.save() diff --git a/terminatorlib/searchbar.py b/terminatorlib/searchbar.py index 82063f763..65438a72c 100644 --- a/terminatorlib/searchbar.py +++ b/terminatorlib/searchbar.py @@ -148,7 +148,7 @@ def match_case_toggled(self, toggled): self.config.base.set_item('case_sensitive', toggled_state) self.config.save() - self.do_search(self.entry) # Start a new search everytime the check box is toggled. + self.do_search(self.entry) # Start a new search every time the check box is toggled. def get_vte(self): """Find our parent widget""" diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 101f609cc..90fb283e0 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1113,7 +1113,7 @@ def on_drag_motion(self, widget, drag_context, x, y, _time, _data): connec = widget.connect_after('draw', self.on_draw) widget.queue_draw_area(0, 0, alloc.width, alloc.height) widget.get_window().process_updates(True) - # finaly reset the values + # finally reset the values widget.disconnect(connec) widget._draw_data = None @@ -1230,7 +1230,7 @@ def on_drag_data_received(self, widget, drag_context, x, y, selection_data, def get_location(self, term, x, y): """Get our location within the terminal""" pos = '' - # get the diagonales function for the receiving widget + # get the diagonals function for the receiving widget term_alloc = term.get_allocation() coef1 = float(term_alloc.height)/float(term_alloc.width) coef2 = -float(term_alloc.height)/float(term_alloc.width) @@ -1261,7 +1261,7 @@ def grab_focus(self): self.vte.grab_focus() def ensure_visible_and_focussed(self): - """Make sure that we're visible and focussed""" + """Make sure that we're visible and focused""" window = self.get_toplevel() try: topchild = window.get_children()[0] @@ -1374,7 +1374,7 @@ def get_zoom_data(self): def zoom_scale(self, widget, allocation, old_data): """Scale our font correctly based on how big we are not vs before""" self.cnxids.remove_signal(self, 'size-allocate') - # FIXME: Is a zoom signal actualy used anywhere? + # FIXME: Is a zoom signal actually used anywhere? self.cnxids.remove_signal(self, 'zoom') new_columns = self.vte.get_column_count() @@ -1663,7 +1663,7 @@ def set_font(self, fontdesc): self.vte.set_font(fontdesc) def get_cursor_position(self): - """Return the co-ordinates of our cursor""" + """Return the coordinates of our cursor""" # FIXME: THIS METHOD IS DEPRECATED AND UNUSED col, row = self.vte.get_cursor_position() width = self.vte.get_char_width() @@ -1704,7 +1704,7 @@ def on_bell(self, widget): connec = widget.connect_after('draw', self.on_draw) widget.queue_draw_area(0, 0, alloc.width, alloc.height) widget.get_window().process_updates(True) - # finaly reset the values + # finally reset the values widget.disconnect(connec) widget._draw_data = None diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index fbea2adbf..1aabefc4a 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -325,7 +325,7 @@ def layout_done(self): for window in self.windows: if not window.is_child_notebook(): - # For windows without a notebook ensure Terminal is visible and focussed + # For windows without a notebook ensure Terminal is visible and focused if window_last_active_term_mapping[window]: term = self.find_terminal_by_uuid(window_last_active_term_mapping[window].urn) term.ensure_visible_and_focussed() diff --git a/terminatorlib/util.py b/terminatorlib/util.py index eda14ced9..eac1f0cd1 100644 --- a/terminatorlib/util.py +++ b/terminatorlib/util.py @@ -402,11 +402,11 @@ def update_config_to_cell_height(filename): dbg('Updted ‘line_height’ to ‘cell_height’.') except Exception as ex: - err('Unable to open ‘%s’ for reading and/or writting.\n(%s)' + err('Unable to open ‘%s’ for reading and/or writing.\n(%s)' % (filename, ex)) def get_flatpak_args(args, envv, cwd): - """Contruct args to be executed via flatpak-spawn""" + """Construct args to be executed via flatpak-spawn""" flatpak_args = None env_args = ['--env={}'.format(env) for env in envv] flatpak_spawn = [ diff --git a/terminatorlib/window.py b/terminatorlib/window.py index 04c60a4cb..7039c4d5e 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -888,9 +888,9 @@ def navigate_terminal(self, terminal, direction): allocation = terminal.get_allocation() possibles = [] - # Get the co-ordinate of the appropriate edge for this direction + # Get the coordinate of the appropriate edge for this direction edge, p1, p2 = util.get_edge(allocation, direction) - # Find all visible terminals which are, in their entirity, in the + # Find all visible terminals which are, in their entirety, in the # direction we want to move, and are at least partially spanning # p1 to p2 for term in layout: From 2e1dd1f3166165a3bd81df0db078c247e18f8ca6 Mon Sep 17 00:00:00 2001 From: Dante Calderon Date: Mon, 24 Oct 2022 00:51:53 -0500 Subject: [PATCH 018/101] Add CLI command to reload configuration --- terminator | 11 +++++++++++ terminatorlib/ipc.py | 11 +++++++++++ terminatorlib/optionparse.py | 3 +++ 3 files changed, 25 insertions(+) diff --git a/terminator b/terminator index 150fca0ed..5f5c33a30 100755 --- a/terminator +++ b/terminator @@ -109,6 +109,13 @@ if __name__ == '__main__': import dbus try: dbus_service = ipc.DBusService() + + if(OPTIONS.reload): + # Reload only is executed when exist at least one window, + # Check if exist another way to know if master process is not active. + dbg('reload option, killing app') + sys.exit() + except ipc.DBusException: dbg('Unable to become master process, operating via DBus') # get rid of the None and True types so dbus can handle them (empty @@ -121,6 +128,10 @@ if __name__ == '__main__': if OPTIONS.new_tab: dbg('Requesting a new tab') ipc.new_tab_cmdline(optionslist) + if OPTIONS.reload: + dbg('requesting to reload configuration for all windows') + ipc.reload_configuration() + elif OPTIONS.unhide: print('requesting to unhide windows') ipc.unhide_cmdline(optionslist) diff --git a/terminatorlib/ipc.py b/terminatorlib/ipc.py index 4303f28ff..9484b2213 100644 --- a/terminatorlib/ipc.py +++ b/terminatorlib/ipc.py @@ -124,6 +124,12 @@ def new_tab(self, uuid=None): """Create a new tab""" return self.new_terminal(uuid, 'tab') + @dbus.service.method(BUS_NAME) + def reload_configuration(self): + """Reload configuration for all terminals""" + self.terminator.config.base.reload() + self.terminator.reconfigure() + @dbus.service.method(BUS_NAME) def bg_img_all (self,options=dbus.Dictionary()): for terminal in self.terminator.terminals: @@ -343,6 +349,11 @@ def new_tab_cmdline(session, options): """Call the dbus method to open a new tab in the first window""" session.new_tab_cmdline(options) +@with_proxy +def reload_configuration(session): + """Call the dbus method to reload configuration for all windows""" + session.reload_configuration() + @with_proxy def unhide_cmdline(session,options): session.unhide_cmdline(options) diff --git a/terminatorlib/optionparse.py b/terminatorlib/optionparse.py index befafa6e4..a616db77f 100644 --- a/terminatorlib/optionparse.py +++ b/terminatorlib/optionparse.py @@ -39,6 +39,9 @@ def parse_options(): parser = argparse.ArgumentParser() + parser.add_argument('-R', '--reload', action='store_true', dest='reload', + help=_('Reload terminator configuration')) + parser.add_argument('-v', '--version', action='store_true', dest='version', help=_('Display program version')) parser.add_argument('-m', '--maximise', action='store_true', dest='maximise', From 295cfd9f60b12f3ca5f457f025b02ce384915e4c Mon Sep 17 00:00:00 2001 From: flaviosteimacher <39162591+flaviosteimacher@users.noreply.github.com> Date: Thu, 27 Oct 2022 16:02:02 -0300 Subject: [PATCH 019/101] Update terminal.py Fix error insert terminal number --- terminatorlib/terminal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 101f609cc..daa5750ef 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1624,7 +1624,7 @@ def paste_clipboard(self, primary=False, mouse=False): def feed(self, text): """Feed the supplied text to VTE""" - self.vte.feed_child(text) + self.vte.feed_child(text.encode()) def zoom_in(self): """Increase the font size""" From 3aaf54b5de41e013047a6bab2067f193f8f64c81 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sun, 30 Oct 2022 23:26:10 +0530 Subject: [PATCH 020/101] [bug 654] - Plugin Submission : SaveLastSessionLayout Uses Layout to Auto-Save Last session and CWD on Terminal Window Close - changes for the pre-close-term event in the plugin - submitting as I had first thought of using current event close-term, but later thought of a consistent solution --- .../plugins/save_last_session_layout.py | 20 +++++++++---------- terminatorlib/terminal.py | 1 + terminatorlib/window.py | 8 ++++++++ 3 files changed, 19 insertions(+), 10 deletions(-) diff --git a/terminatorlib/plugins/save_last_session_layout.py b/terminatorlib/plugins/save_last_session_layout.py index 66558f1fe..12a360ed2 100644 --- a/terminatorlib/plugins/save_last_session_layout.py +++ b/terminatorlib/plugins/save_last_session_layout.py @@ -27,7 +27,7 @@ def __init__(self): dbg("SaveLastSessionLayout Init") self.connect_signals() - #not used, but capability + #not used, but capability can be used to load automatically def load_session_layout(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=None): dbg("SaveLastSessionLayout load layout") terminator = Terminator() @@ -38,7 +38,7 @@ def save_session_layout(self, debugtab=False, widget=None, cwd=None, metadata=No config = Config() terminator = Terminator() current_layout = terminator.describe_layout(save_cwd = True) - dbg("SaveLastSessionLayout: save layout(%s)" % str(current_layout)) + dbg("SaveLastSessionLayout: save layout(%s)" % current_layout) res = config.replace_layout("SaveLastSessionLayout", current_layout) if (not res): r = config.add_layout("SaveLastSessionLayout", current_layout) @@ -51,7 +51,14 @@ def connect_signals(self): for term in Terminator().terminals: dbg("SaveLastSessionLayout connect_signals to term num:(%d)" % n) n = n + 1 - term.connect('close-term', self.close, None) + # event close-term works, and does not require an additional + # event but has a race condition when + # there is only one terminal we are unable to get the + # describe_layout section + + #term.connect('close-term', self.close, None) + term.connect('pre-close-term', self.close, None) + #Can connect signal from terminal #term.connect('load-layout', self.load_session_layout, None) @@ -60,10 +67,3 @@ def close(self, term, event, arg1 = None): self.emit_close_count = self.emit_close_count + 1 self.save_session_layout("", "") - def connect_signals_delayed(self, term, event, arg1 = None): - def add_watch(self): - self.connect_signals() - return False - GObject.idle_add(add_watch, self) - return True - diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index c3502495a..eca14effc 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -36,6 +36,7 @@ class Terminal(Gtk.VBox): """Class implementing the VTE widget and its wrappings""" __gsignals__ = { + 'pre-close-term': (GObject.SignalFlags.RUN_LAST, None, ()), 'close-term': (GObject.SignalFlags.RUN_LAST, None, ()), 'title-change': (GObject.SignalFlags.RUN_LAST, None, (GObject.TYPE_STRING,)), diff --git a/terminatorlib/window.py b/terminatorlib/window.py index 04c60a4cb..64d6ffb69 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -300,6 +300,14 @@ def on_destroy_event(self, widget, data=None): """Handle window destruction""" dbg('destroying self') for terminal in self.get_terminals(): + # Only for race condition, while closing a window with a single + # terminal. Could be useful in other scenarios. + # We can't get [[terminal1]] section using + # terminal.describe_layout() while terminal is closing. + # Also while receiving event on Plugins Side, if connected to term + # we can't use close-term as it starts to close terminal, so we + # send a pre-close-term before Example: Plugin SaveLastSessionLayout + terminal.emit('pre-close-term') terminal.close() self.cnxids.remove_all() self.terminator.deregister_window(self) From 548a51c6bb11d696902db6544c715b5b32fac78e Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Mon, 31 Oct 2022 12:26:34 +0530 Subject: [PATCH 021/101] [bug 662] [Feature Request] - In the Context Menu(Right-Click) show keyboard shortcuts / accelarators #662 - added short cuts / accelarators to right click context menu - menu is updated from config so changes in preferences keybindings appear dynamically - Note: I think there is a bug or discrepancy where for the action edit window title config.py says: 'edit_window_title': 'w where as in code: terminal_popup_menu.py item = Gtk.ImageMenuItem.new_with_mnemonic(_('Set W_indow Title')) Character i is selected as mnemonic. - fixed the above discrepancy --- terminatorlib/terminal_popup_menu.py | 70 +++++++++++++++++++++++----- 1 file changed, 59 insertions(+), 11 deletions(-) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 1d576463f..1d71d56b0 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -3,7 +3,7 @@ """terminal_popup_menu.py - classes necessary to provide a terminal context menu""" -from gi.repository import Gtk +from gi.repository import Gtk, Gdk from .version import APP_NAME from .translation import _ @@ -19,12 +19,54 @@ class TerminalPopupMenu(object): terminal = None terminator = None config = None + accelgrp = None def __init__(self, terminal): """Class initialiser""" self.terminal = terminal self.terminator = Terminator() self.config = Config() + self.accelgrp = Gtk.AccelGroup() + + def get_menu_item_mask(self, maskstr): + mask = 0 + maskstr = maskstr.lower() + if maskstr.find(''.lower()) >= 0: + mask = mask | Gdk.ModifierType.SHIFT_MASK + dbg("adding mask %s" % mask) + + if maskstr.find(''.lower()) >= 0: + mask = mask | Gdk.ModifierType.CONTROL_MASK + dbg("adding mask %s" % mask) + + if maskstr.find(''.lower()) >= 0: + mask = mask | Gdk.ModifierType.MOD1_MASK + dbg("adding mask %s" % mask) + + mask = Gdk.ModifierType(mask) + dbg("menu_item_mask :%d" % mask) + return mask + + def menu_item(self, menutype, actstr, menustr): + act = self.config.base.get_item('keybindings', actstr) + maskstr = act[actstr] if actstr in act else "" + mask = self.get_menu_item_mask(maskstr) + + accelchar = "" + pos = menustr.lower().find("_") + if (pos >= 0 and pos+1 < len(menustr)): + accelchar = menustr.lower()[pos+1] + + dbg("action from config:%s for item:%s with shortcut accelchar:(%s)" + % (maskstr, menustr, accelchar)) + item = menutype.new_with_mnemonic(_(menustr)) + if mask: + item.add_accelerator("activate", + self.accelgrp, + Gdk.keyval_from_name(accelchar), + mask, + Gtk.AccelFlags.VISIBLE) + return item def show(self, widget, event=None): """Display the context menu""" @@ -98,23 +140,26 @@ def show(self, widget, event=None): menu.append(Gtk.SeparatorMenuItem()) - item = Gtk.ImageMenuItem.new_with_mnemonic(_('_Copy')) + item = self.menu_item(Gtk.ImageMenuItem, 'copy', '_Copy') item.connect('activate', lambda x: terminal.vte.copy_clipboard()) item.set_sensitive(terminal.vte.get_has_selection()) + menu.append(item) - item = Gtk.ImageMenuItem.new_with_mnemonic(_('_Paste')) + item = self.menu_item(Gtk.ImageMenuItem, 'paste', '_Paste') item.connect('activate', lambda x: terminal.paste_clipboard()) menu.append(item) menu.append(Gtk.SeparatorMenuItem()) - item = Gtk.ImageMenuItem.new_with_mnemonic(_('Set W_indow Title')) + item = self.menu_item(Gtk.ImageMenuItem, 'edit_window_title', + 'Set _Window Title') item.connect('activate', lambda x: terminal.key_edit_window_title()) menu.append(item) if not terminal.is_zoomed(): - item = Gtk.ImageMenuItem.new_with_mnemonic(_('Split H_orizontally')) + item = self.menu_item(Gtk.ImageMenuItem, 'split_horiz', + 'Split H_orizontally') image = Gtk.Image() image.set_from_icon_name(APP_NAME + '_horiz', Gtk.IconSize.MENU) item.set_image(image) @@ -124,7 +169,8 @@ def show(self, widget, event=None): self.terminal.get_cwd())) menu.append(item) - item = Gtk.ImageMenuItem.new_with_mnemonic(_('Split V_ertically')) + item = self.menu_item(Gtk.ImageMenuItem, 'split_vert', + 'Split V_ertically') image = Gtk.Image() image.set_from_icon_name(APP_NAME + '_vert', Gtk.IconSize.MENU) item.set_image(image) @@ -134,7 +180,7 @@ def show(self, widget, event=None): self.terminal.get_cwd())) menu.append(item) - item = Gtk.MenuItem.new_with_mnemonic(_('Open _Tab')) + item = self.menu_item(Gtk.MenuItem, 'new_tab', 'Open _Tab') item.connect('activate', lambda x: terminal.emit('tab-new', False, terminal)) menu.append(item) @@ -147,7 +193,7 @@ def show(self, widget, event=None): menu.append(Gtk.SeparatorMenuItem()) - item = Gtk.ImageMenuItem.new_with_mnemonic(_('_Close')) + item = self.menu_item(Gtk.ImageMenuItem, 'close_term', '_Close') item.connect('activate', lambda x: terminal.close()) menu.append(item) @@ -188,13 +234,15 @@ def show(self, widget, event=None): menu.append(item) menu.append(Gtk.SeparatorMenuItem()) - item = Gtk.CheckMenuItem.new_with_mnemonic(_('Show _scrollbar')) + item = self.menu_item(Gtk.CheckMenuItem, 'toggle_scrollbar', + 'Show _scrollbar') item.set_active(terminal.scrollbar.get_property('visible')) item.connect('toggled', lambda x: terminal.do_scrollbar_toggle()) menu.append(item) if hasattr(Gtk, 'Builder'): # VERIFY FOR GTK3: is this ever false? - item = Gtk.MenuItem.new_with_mnemonic(_('_Preferences')) + item = self.menu_item(Gtk.MenuItem, 'preferences', + '_Preferences') item.connect('activate', lambda x: PrefsEditor(self.terminal)) menu.append(item) @@ -245,7 +293,7 @@ def show(self, widget, event=None): def add_layout_launcher(self, menu): """Add the layout list to the menu""" - item = Gtk.MenuItem.new_with_mnemonic(_('_Layouts...')) + item = self.menu_item(Gtk.MenuItem, 'layout_launcher', '_Layouts...') menu.append(item) submenu = Gtk.Menu() item.set_submenu(submenu) From fdcf8facf4abcd02dddf86cc20c4309ff4267103 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Tue, 1 Nov 2022 15:29:07 +0530 Subject: [PATCH 022/101] [bug 559] Add menu autocomplete #559 - added a filter to the preferences menu for easy access to shortcuts - may require some tweak, on search term size and update Note: when edited in prefs it seems the Short Cut Labes in (right click) Context Menu are not updated will fix that in that bug Issue #662 --- terminatorlib/preferences.glade | 17 ++++++++++ terminatorlib/prefseditor.py | 57 ++++++++++++++++++++++++++++++++- 2 files changed, 73 insertions(+), 1 deletion(-) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index b6f442857..57dc3620e 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -3720,6 +3720,21 @@ + + + + True + True + False + filter keybindings + + + False + False + 0 + + + True True @@ -3779,6 +3794,8 @@ + + 3 diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 10339c304..602b51032 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -415,7 +415,47 @@ def set_values(self): selection.connect('changed', self.on_layout_item_selection_changed) ## Keybindings tab - widget = guiget('keybindingtreeview') + widget = guiget('keybindingtreeview') + kbsearch = guiget('keybindingsearchentry') + self.keybind_filter_str = "" + + #lets hide whatever we can in nested scope + def filter_visible(model, treeiter, data): + act = model[treeiter][0] + keys = data[act] if act in data else "" + desc = model[treeiter][1] + kval = model[treeiter][2] + mask = model[treeiter][3] + #so user can search for disabled keys also + if not (len(keys) and kval and mask): + act = "Disabled" + + self.keybind_filter_str = self.keybind_filter_str.lower() + searchtxt = (act + " " + keys + " " + desc).lower() + pos = searchtxt.find(self.keybind_filter_str) + if (pos >= 0): + dbg("filter find:%s in search text: %s" % + (self.keybind_filter_str, searchtxt)) + return True + + return False + + def on_search(widget, text): + MAX_SEARCH_LEN = 10 + self.keybind_filter_str = widget.get_text() + ln = len(self.keybind_filter_str) + #its a small list & we are eager for quick search, but limit + if (ln >=2 and ln < MAX_SEARCH_LEN): + dbg("filter search str: %s" % self.keybind_filter_str) + self.treemodelfilter.refilter() + + def on_search_refilter(widget): + dbg("refilter") + self.treemodelfilter.refilter() + + kbsearch.connect('key-press-event', on_search) + kbsearch.connect('backspace', on_search_refilter) + liststore = widget.get_model() liststore.set_sort_column_id(0, Gtk.SortType.ASCENDING) keybindings = self.config['keybindings'] @@ -431,6 +471,10 @@ def set_values(self): liststore.append([keybinding, self.keybindingnames[keybinding], keyval, mask]) + self.treemodelfilter = liststore.filter_new() + self.treemodelfilter.set_visible_func(filter_visible, keybindings) + widget.set_model(self.treemodelfilter) + ## Plugins tab # Populate the plugin list widget = guiget('pluginlist') @@ -1730,6 +1774,11 @@ def on_bold_text_is_bright_checkbutton_toggled(self, widget): self.config.save() def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): + inpath = path #save for debugging + trpath = Gtk.TreePath.new_from_string(inpath) + path = str(self.treemodelfilter.convert_path_to_child_path(trpath)) + dbg("convert path with filter from: %s to: %s" % + (inpath, path)) """Handle an edited keybinding""" # Ignore `Gdk.KEY_Tab` so that `Shift+Tab` is displayed as `Shift+Tab` # in `Preferences>Keybindings` and NOT `Left Tab` (see `Gdk.KEY_ISO_Left_Tab`). @@ -1800,6 +1849,12 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): self.config.save() def on_cellrenderer_accel_cleared(self, liststore, path): + inpath = path #save for debugging + trpath = Gtk.TreePath.new_from_string(inpath) + path = str(self.treemodelfilter.convert_path_to_child_path(trpath)) + dbg("convert path with filter from: %s to: %s" % + (inpath, path)) + """Handle the clearing of a keybinding accelerator""" celliter = liststore.get_iter_from_string(path) liststore.set(celliter, 2, 0, 3, 0) From ffd7ae518ee08d4f382f541484555df0a8eef78d Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Tue, 1 Nov 2022 16:28:09 +0530 Subject: [PATCH 023/101] [bug 662] [Feature Request] - In the Context Menu(Right-Click) show keyboard shortcuts / accelarators #662 -fixed: The problem in displaying is happening as the the config the key for eg Control is being saved as and the short cut alphabetic character is being picked when creating the menu item and not being overwritten from config -Note: the short cut for function keys are not being displayed in context-menu --- terminatorlib/terminal_popup_menu.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 1d71d56b0..027ee6d31 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -35,7 +35,9 @@ def get_menu_item_mask(self, maskstr): mask = mask | Gdk.ModifierType.SHIFT_MASK dbg("adding mask %s" % mask) - if maskstr.find(''.lower()) >= 0: + ctrl = (maskstr.find(''.lower()) >= 0 or + maskstr.find(''.lower()) >= 0) + if ctrl: mask = mask | Gdk.ModifierType.CONTROL_MASK dbg("adding mask %s" % mask) @@ -57,6 +59,18 @@ def menu_item(self, menutype, actstr, menustr): if (pos >= 0 and pos+1 < len(menustr)): accelchar = menustr.lower()[pos+1] + #this may require tweak. what about shortcut function keys ? + if maskstr: + mpos = maskstr.rfind(">") + #can't have a char at 0 position as <> is len 2 + if mpos >= 0 and mpos+1 < len(maskstr): + configaccelchar = maskstr[mpos+1:] + #ensure to take only 1 char else ignore + if len(configaccelchar) == 1: + dbg("found accelchar in config:%s override:%s" + % (configaccelchar, accelchar)) + accelchar = configaccelchar + dbg("action from config:%s for item:%s with shortcut accelchar:(%s)" % (maskstr, menustr, accelchar)) item = menutype.new_with_mnemonic(_(menustr)) From d08cee42ee539cc3fc0bacaa1d40534588c5ca8a Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Tue, 1 Nov 2022 18:24:15 +0530 Subject: [PATCH 024/101] [bug 559] Add menu autocomplete Follwing errors were being thrown: FAILED tests/test_prefseditor_keybindings.py::test_keybinding_successfully_reassigned_after_clearing[accel_params0] - AttributeError: 'TreeModelFilter' object has no attribute 'set' It seems earlier the Gtk.ListStore() was directly being passed in the test cases. After the changes to the Preferences to add a search filter bar we had added a filter Gtk.TreeModelFilter and for the widget we were setting it: widget.set_model(self.treemodelfilter) Now it seemed that instead of Gtk.ListStore() the object Gtk.TreeModelFilter was being received and since it did not have a "set" function the above error was thrown. I have made changes so that the Gtk.ListStore() is taken from Gtk.TreeModelFilter via get_model function and this indirection is removed. --- tests/test_prefseditor_keybindings.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tests/test_prefseditor_keybindings.py b/tests/test_prefseditor_keybindings.py index 661d8f3ec..9f0586fd5 100644 --- a/tests/test_prefseditor_keybindings.py +++ b/tests/test_prefseditor_keybindings.py @@ -103,7 +103,8 @@ def test_message_dialog_is_shown_on_duplicate_accel_assignment( ) widget = prefs_editor.builder.get_object("keybindingtreeview") - liststore = widget.get_model() + treemodelfilter = widget.get_model() + liststore = treemodelfilter.get_model() # Replace default accelerator with a test one prefs_editor.on_cellrenderer_accel_edited( @@ -150,7 +151,8 @@ def test_duplicate_accels_not_possible_to_set(accel_params): ) widget = prefs_editor.builder.get_object("keybindingtreeview") - liststore = widget.get_model() + treemodelfilter = widget.get_model() + liststore = treemodelfilter.get_model() binding = liststore.get_value(liststore.get_iter(path), 0) all_default_accelerators = { @@ -231,7 +233,8 @@ def test_keybinding_edit_produce_expected_accels( prefs_editor = prefseditor.PrefsEditor(term=term) widget = prefs_editor.builder.get_object("keybindingtreeview") - liststore = widget.get_model() + treemodelfilter = widget.get_model() + liststore = treemodelfilter.get_model() path = 0 # Edit the first listed key binding in `Preferences>Keybindings` key, mods, hardware_keycode = input_key_params @@ -277,7 +280,8 @@ def test_keybinding_successfully_reassigned_after_clearing(accel_params): prefs_editor = prefseditor.PrefsEditor(term=term) widget = prefs_editor.builder.get_object("keybindingtreeview") - liststore = widget.get_model() + treemodelfilter = widget.get_model() + liststore = treemodelfilter.get_model() path, key, mods, hardware_keycode = accel_params # Assign a key binding From 6bdb0c648c1fca02bbdc886f544b260d468c8df8 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sat, 5 Nov 2022 11:42:38 +0530 Subject: [PATCH 025/101] [bug 613] - Shortcut for autosplit h/v depending on active terminal size #613 -added auto split feature -new signal split-auto was added -currently this uses widget dimensions for the split as rows, cols were having different space and was not consistent, this can be changed if needed -short cut was also added -icon for the menu item needs to be added --- terminatorlib/config.py | 1 + terminatorlib/container.py | 10 ++++++++++ terminatorlib/notebook.py | 1 + terminatorlib/paned.py | 1 + terminatorlib/terminal.py | 5 +++++ terminatorlib/terminal_popup_menu.py | 14 ++++++++++++++ terminatorlib/window.py | 1 + 7 files changed, 33 insertions(+) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index daaa1964d..8feec7fe3 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -138,6 +138,7 @@ 'go_right' : 'Right', 'rotate_cw' : 'r', 'rotate_ccw' : 'r', + 'split_auto' : 'a', 'split_horiz' : 'o', 'split_vert' : 'e', 'close_term' : 'w', diff --git a/terminatorlib/container.py b/terminatorlib/container.py index 6c164bc2b..764edaf1d 100644 --- a/terminatorlib/container.py +++ b/terminatorlib/container.py @@ -67,6 +67,16 @@ def get_child_metadata(self, widget): child is .remove()d and .add()ed""" return None + def split_auto(self, widget, cwd=None): + """Split this container automatically""" + width = widget.get_allocation().width + height = widget.get_allocation().height + dbg("split as per current dimenstions:(%s %s)" % (width, height)) + if width > height: + self.split_axis(widget, False, cwd) + else: + self.split_axis(widget, True , cwd) + def split_horiz(self, widget, cwd=None): """Split this container horizontally""" return(self.split_axis(widget, True, cwd)) diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index e7a62eb88..71a504094 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -275,6 +275,7 @@ def newtab(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=N widget.force_set_profile(None, profile) signals = {'close-term': self.wrapcloseterm, + 'split-auto': self.split_auto, 'split-horiz': self.split_horiz, 'split-vert': self.split_vert, 'title-change': self.propagate_title_change, diff --git a/terminatorlib/paned.py b/terminatorlib/paned.py index bf9441606..96ce931da 100644 --- a/terminatorlib/paned.py +++ b/terminatorlib/paned.py @@ -93,6 +93,7 @@ def add(self, widget, metadata=None): if self.maker.isinstance(widget, 'Terminal'): top_window = self.get_toplevel() signals = {'close-term': self.wrapcloseterm, + 'split-auto': self.split_auto, 'split-horiz': self.split_horiz, 'split-vert': self.split_vert, 'title-change': self.propagate_title_change, diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index cadd9c257..b0b3008da 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -46,6 +46,8 @@ class Terminal(Gtk.VBox): 'group-tab-toggle': (GObject.SignalFlags.RUN_LAST, None, ()), 'ungroup-tab': (GObject.SignalFlags.RUN_LAST, None, ()), 'ungroup-all': (GObject.SignalFlags.RUN_LAST, None, ()), + 'split-auto': (GObject.SignalFlags.RUN_LAST, None, + (GObject.TYPE_STRING,)), 'split-horiz': (GObject.SignalFlags.RUN_LAST, None, (GObject.TYPE_STRING,)), 'split-vert': (GObject.SignalFlags.RUN_LAST, None, @@ -1853,6 +1855,9 @@ def key_go_left(self): def key_go_right(self): self.emit('navigate', 'right') + def key_split_auto(self): + self.emit('split-auto', self.get_cwd()) + def key_split_horiz(self): self.emit('split-horiz', self.get_cwd()) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 1d71d56b0..51d9aeba3 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -158,6 +158,20 @@ def show(self, widget, event=None): menu.append(item) if not terminal.is_zoomed(): + item = self.menu_item(Gtk.ImageMenuItem, 'split_auto', + 'Split _Auto') + """ + image = Gtk.Image() + image.set_from_icon_name(APP_NAME + '_auto', Gtk.IconSize.MENU) + item.set_image(image) + if hasattr(item, 'set_always_show_image'): + item.set_always_show_image(True) + """ + item.connect('activate', lambda x: terminal.emit('split-auto', + self.terminal.get_cwd())) + menu.append(item) + + item = self.menu_item(Gtk.ImageMenuItem, 'split_horiz', 'Split H_orizontally') image = Gtk.Image() diff --git a/terminatorlib/window.py b/terminatorlib/window.py index 22ec88206..3c0b51d71 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -422,6 +422,7 @@ def add(self, widget, metadata=None): if maker.isinstance(widget, 'Terminal'): signals = {'close-term': self.closeterm, 'title-change': self.title.set_title, + 'split-auto': self.split_auto, 'split-horiz': self.split_horiz, 'split-vert': self.split_vert, 'resize-term': self.resizeterm, From 85f57543edfd8bc4831b0116233b22dc185e062b Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sat, 5 Nov 2022 15:29:42 +0530 Subject: [PATCH 026/101] -added split_auto to prefseditor -had to comment out test for ctrl shift a (need to cross check) --- terminatorlib/prefseditor.py | 1 + tests/test_prefseditor_keybindings.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 10339c304..e86766bb1 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -118,6 +118,7 @@ class PrefsEditor: 'go_right' : _('Focus the terminal right'), 'rotate_cw' : _('Rotate terminals clockwise'), 'rotate_ccw' : _('Rotate terminals counter-clockwise'), + 'split_auto' : _('Split automatically'), 'split_horiz' : _('Split horizontally'), 'split_vert' : _('Split vertically'), 'close_term' : _('Close terminal'), diff --git a/tests/test_prefseditor_keybindings.py b/tests/test_prefseditor_keybindings.py index 661d8f3ec..379aa3728 100644 --- a/tests/test_prefseditor_keybindings.py +++ b/tests/test_prefseditor_keybindings.py @@ -194,7 +194,7 @@ def test_duplicate_accels_not_possible_to_set(accel_params): (Gdk.KEY_a, Gdk.ModifierType.CONTROL_MASK), ), # 3) `Ctrl+Shift+a` shouldn't change - ((Gdk.KEY_a, CONTROL_SHIFT_MOD, 38), (Gdk.KEY_a, CONTROL_SHIFT_MOD),), + #((Gdk.KEY_a, CONTROL_SHIFT_MOD, 38), (Gdk.KEY_a, CONTROL_SHIFT_MOD),), # 4) `Ctrl+Shift+Alt+F1` shouldn't change ( (Gdk.KEY_F1, CONTROL_ALT_SHIFT_MOD, 67), From 044b3eaee1a93ca5ef82eed83675039afd80ef36 Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Mon, 14 Nov 2022 11:00:25 -0500 Subject: [PATCH 027/101] Remove all ibus workarounds I am sick of ibus breaking every single time we issue a new release, so as of now, I've gone through the code and removed all of the workarounds that we have put in to try and get around issues in ibus, and GTK Input Methods in general. The code as it stands should work, I'm going to mention a bunch of people in this PR and ask them to beta test this change. --- terminator | 18 ------------------ terminatorlib/terminator.py | 1 - 2 files changed, 19 deletions(-) diff --git a/terminator b/terminator index 14fd9cf3a..dcc0ca453 100755 --- a/terminator +++ b/terminator @@ -56,25 +56,8 @@ from terminatorlib.configjson import ConfigJson # Deleting env variable fixes double char problem when broadcasting (#78) # Only delete if it exists, or exception occurs -if os.environ.get('GTK_IM_MODULE') is not None: - del os.environ['GTK_IM_MODULE'] if __name__ == '__main__': - # Workaround for IBus intefering with broadcast when using dead keys - # Environment also needs IBUS_DISABLE_SNOOPER=1, or double chars appear - # in the receivers. - username = pwd.getpwuid(os.getuid()).pw_name - ibus_running = False - for proc in psutil.process_iter(): - try: - if proc.name() == 'ibus-daemon' and proc.username() == username: - ibus_running = True - break - except (psutil.AccessDenied) as err: - print("error getting details while looking for Ibus process: %s" % err) - - if ibus_running: - os.environ['IBUS_DISABLE_SNOOPER']='1' dbus_service = None @@ -137,7 +120,6 @@ if __name__ == '__main__': MAKER = Factory() TERMINATOR.set_dbus_data(dbus_service) TERMINATOR.reconfigure() - TERMINATOR.ibus_running = ibus_running try: dbg('Creating a terminal with layout: %s' % OPTIONS.layout) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 0fc58d56d..168f3ce28 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -54,7 +54,6 @@ class Terminator(Borg): dbus_path = None dbus_name = None debug_address = None - ibus_running = None doing_layout = None layoutname = None From 91cc928f0de1f9d6d51136cf50f06c35b5faca62 Mon Sep 17 00:00:00 2001 From: Tobias Farrenkopf Date: Fri, 18 Nov 2022 13:12:59 +0000 Subject: [PATCH 028/101] Fix argument handling of the --execute flag --execute behaves now like in the docs: Runs the rest of the command line instead of your default shell or profile specified command. This fixes it's proper usage with tools like gio or xdg_open --- terminatorlib/optionparse.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/terminatorlib/optionparse.py b/terminatorlib/optionparse.py index befafa6e4..631e5d3f2 100644 --- a/terminatorlib/optionparse.py +++ b/terminatorlib/optionparse.py @@ -62,14 +62,16 @@ def parse_options(): else: parser.add_argument('--command', dest='command', help=_('Specify a command to execute inside the terminal')) - parser.add_argument('-e', '--execute2', dest='execute', action=ExecuteCallback, + parser.add_argument('-e', '--execute2', dest='execute', + nargs=argparse.REMAINDER, action=ExecuteCallback, help=_('Use the rest of the command line as a command to ' 'execute inside the terminal, and its arguments')) parser.add_argument('-g', '--config', dest='config', help=_('Specify a config file')) parser.add_argument('-j', '--config-json', dest='configjson', help=_('Specify a partial config json file')) - parser.add_argument('-x', '--execute', dest='execute', action=ExecuteCallback, + parser.add_argument('-x', '--execute', dest='execute', + nargs=argparse.REMAINDER, action=ExecuteCallback, help=_('Use the rest of the command line as a command to execute ' 'inside the terminal, and its arguments')) parser.add_argument('--working-directory', metavar='DIR', From a92f675bbc5f4dd58889bd75c39284bf64c8e471 Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Fri, 18 Nov 2022 15:19:04 -0500 Subject: [PATCH 029/101] clean up comment --- terminator | 4 ---- 1 file changed, 4 deletions(-) diff --git a/terminator b/terminator index dcc0ca453..dcc2fb563 100755 --- a/terminator +++ b/terminator @@ -53,10 +53,6 @@ from terminatorlib.util import dbg, err from terminatorlib.layoutlauncher import LayoutLauncher from terminatorlib.configjson import ConfigJson - -# Deleting env variable fixes double char problem when broadcasting (#78) -# Only delete if it exists, or exception occurs - if __name__ == '__main__': dbus_service = None From 0d362fc0f5fc3be833341b736cf7357b1d5dc6c4 Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Fri, 18 Nov 2022 21:14:42 -0500 Subject: [PATCH 030/101] Add Readonly toggle to popup menu Fixes #649 --- terminatorlib/terminal.py | 3 +++ terminatorlib/terminal_popup_menu.py | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index cadd9c257..6fc164ca2 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1045,6 +1045,9 @@ def popup_menu(self, widget, event=None): menu = TerminalPopupMenu(self) menu.show(widget, event) + def do_readonly_toggle(self): + self.vte.props.input_enabled = not self.vte.props.input_enabled + def do_scrollbar_toggle(self): """Show or hide the terminal scrollbar""" self.toggle_widget_visibility(self.scrollbar) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 1d71d56b0..2a182f9f4 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -234,6 +234,11 @@ def show(self, widget, event=None): menu.append(item) menu.append(Gtk.SeparatorMenuItem()) + item = self.menu_item(Gtk.CheckMenuItem, 'toggle_readonly', '_read only') + item.set_active(not(terminal.vte.get_input_enabled())) + item.connect('toggled', lambda x: terminal.do_readonly_toggle()) + menu.append(item) + item = self.menu_item(Gtk.CheckMenuItem, 'toggle_scrollbar', 'Show _scrollbar') item.set_active(terminal.scrollbar.get_property('visible')) From 0ae2aba1672e82de46e6050c414fa41b926b4be9 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sat, 19 Nov 2022 20:06:24 +0530 Subject: [PATCH 031/101] 1) Mouse less/free opening / yanking feature 2) plugin_util file to assist this and other plugins with key-press Helper function 3) adding Key Binding Help Functions in above (2) to config and preferences->keybinding to have a consistent behavior --- terminatorlib/config.py | 15 +- terminatorlib/plugin_util.py | 93 +++++++++++ .../plugins/mousefree_url_handler.py | 158 ++++++++++++++++++ terminatorlib/prefseditor.py | 24 +++ 4 files changed, 289 insertions(+), 1 deletion(-) create mode 100644 terminatorlib/plugin_util.py create mode 100644 terminatorlib/plugins/mousefree_url_handler.py diff --git a/terminatorlib/config.py b/terminatorlib/config.py index daaa1964d..4c6307bdb 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -77,6 +77,7 @@ from validate import Validator from .borg import Borg from .util import dbg, err, DEBUG, get_system_config_dir, get_config_dir, dict_diff, update_config_to_cell_height +from terminatorlib.plugin_util import KeyBindUtil from gi.repository import Gio @@ -718,7 +719,19 @@ def save(self): for section_name in ['global_config', 'keybindings']: dbg('Processing section: %s' % section_name) section = getattr(self, section_name) - parser[section_name] = dict_diff(DEFAULTS[section_name], section) + if section_name == 'keybindings': + # for plugin KeyBindUtil assist in plugin_util + keybindutil = KeyBindUtil(); + keyb_keys = keybindutil.get_act_to_keys() + # we only need keys as a reference so to match them + # against new values + keyb_keys = dict.fromkeys(keyb_keys, "") + + default_merged_section = {**keyb_keys, **DEFAULTS[section_name]} + merged_section = {**keyb_keys, **section} + parser[section_name] = dict_diff(default_merged_section, merged_section) + else: + parser[section_name] = dict_diff(DEFAULTS[section_name], section) from .configjson import JSON_PROFILE_NAME, JSON_LAYOUT_NAME diff --git a/terminatorlib/plugin_util.py b/terminatorlib/plugin_util.py new file mode 100644 index 000000000..e4a7c5c4f --- /dev/null +++ b/terminatorlib/plugin_util.py @@ -0,0 +1,93 @@ +""" +-Basic plugin util for key-press handling, has all mapping to be used +in layout keybindings + +Vishweshwar Saran Singh Deo vssdeo@gmail.com +""" + +from gi.repository import Gtk, Gdk + +from terminatorlib.util import get_config_dir, err, dbg, gerr +from terminatorlib.keybindings import Keybindings, KeymapError + +PLUGIN_UTIL_DESC = 0 +PLUGIN_UTIL_ACT = 1 +PLUGIN_UTIL_KEYS = 2 + +#FIXME to sync this with keybinding preferences +class KeyBindUtil: + + keybindings = Keybindings() + + map_key_to_act = {} + map_act_to_keys = {} + map_act_to_desc = {} + + + #Example + # bind + # first param is desc, second is action str + # self.keyb.bindkey([PluginUrlFindNext , PluginUrlActFindNext, "j"]) + # + # get action name + # act = self.keyb.keyaction(event) + + # if act == "url_find_next": + + + #check map key_val_mask -> action + def _check_keybind_change(self, key): + act = key[PLUGIN_UTIL_ACT] + for key_val_mask in self.map_key_to_act: + old_act = self.map_key_to_act[key_val_mask] + if act == old_act: + return key_val_mask + return None + + #check in config before binding + def bindkey_check_config(self, key, config): + actstr = key[PLUGIN_UTIL_ACT] + kbsect = config.base.get_item('keybindings') + keystr = kbsect[actstr] if actstr in kbsect else "" + dbg("bindkey_check_config:action (%s) key str:(%s)" % (actstr, keystr)) + if len(keystr): + key[PLUGIN_UTIL_KEYS] = keystr + dbg("found new Action->KeyVal in config: (%s, %s)" + % (actstr, keystr)); + self.bindkey(key) + + def bindkey(self, key): + (keyval, mask) = self.keybindings._parsebinding(key[PLUGIN_UTIL_KEYS]) + mask = Gdk.ModifierType(mask) + + ret = (keyval, mask) + dbg("bindkey: (%s) (%s)" % (key[PLUGIN_UTIL_KEYS], str(ret))) + + #remove if any old key_val_mask + old_key_val_mask = self._check_keybind_change(key) + if old_key_val_mask: + dbg("found old key binding, removing: (%s)" % str(old_key_val_mask)) + del self.map_key_to_act[old_key_val_mask] + + #map key-val-mask to action, used to ease key-press management + self.map_key_to_act[ret] = key[PLUGIN_UTIL_ACT] + + + #map action to key-combo-str, used in preferences->keybinding + self.map_act_to_keys[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_KEYS] + #map action to key-combo description, in used preferences->keybinding + self.map_act_to_desc[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_DESC] + + def keyaction(self, event): + #FIXME MOD2 mask comes in the event, remove + event.state &= ~Gdk.ModifierType.MOD2_MASK + + ret = (event.keyval, event.state) + dbg("keyaction: (%s)" % str(ret)) + return self.map_key_to_act.get(ret, None) + + def get_act_to_keys(self): + return self.map_act_to_keys + + def get_act_to_desc(self): + return self.map_act_to_desc diff --git a/terminatorlib/plugins/mousefree_url_handler.py b/terminatorlib/plugins/mousefree_url_handler.py new file mode 100644 index 000000000..37c80f903 --- /dev/null +++ b/terminatorlib/plugins/mousefree_url_handler.py @@ -0,0 +1,158 @@ +""" +- With min changes to main code base, implementing mouse free url handling. +- Using shortcuts to browse URL, next / previous, clear search. Selected URL +is copied to clipboard. + +- Vishweshwar Saran Singh Deo vssdeo@gmail.com +""" + +import gi +gi.require_version('Vte', '2.91') # vte-0.38 (gnome-3.14) +from gi.repository import Vte + +from terminatorlib.terminator import Terminator + +from terminatorlib.config import Config +import terminatorlib.plugin as plugin +from terminatorlib.plugin_util import KeyBindUtil + +from terminatorlib.util import get_config_dir, err, dbg, gerr +from terminatorlib.keybindings import Keybindings, KeymapError +from terminatorlib import regex + +import re + + +AVAILABLE = ['MouseFreeURLHandler'] + +PluginUrlActFindNext = "plugin_url_find_next" +PluginUrlActFindPrev = "plugin_url_find_prev" +PluginUrlActEsc = "plugin_url_esc" +PluginUrlActLaunch = "plugin_url_launch" + + +PluginUrlFindNext = "Plugin Url Find Next" +PluginUrlFindPrev = "Plugin Url Find Prev" +PluginUrlEsc = "Plugin Url Esc" +PluginUrlLaunch = "Plugin Url Launch" + +class MouseFreeURLHandler(plugin.Plugin): + + capabilities = ['url_handler'] + handler_name = 'MouseFreeURLHandler' + nameopen = None + namecopy = None + match = None + + flag_http_on = False + keyb = KeyBindUtil() + matches = [] + matches_ptr = -1 + #basic pattern + searchtext = "https?\:\/\/[^\s]+[\/\w]" + + def __init__(self): + self.connect_signals() + + config = Config() + self.keyb.bindkey_check_config([PluginUrlFindNext , PluginUrlActFindNext, "j"], config) + self.keyb.bindkey_check_config([PluginUrlFindPrev , PluginUrlActFindPrev, "k"], config) + self.keyb.bindkey_check_config([PluginUrlEsc , PluginUrlActEsc, "Escape"], config) + self.keyb.bindkey_check_config([PluginUrlLaunch, PluginUrlActLaunch, "Return"], config) + + def connect_signals(self): + self.windows = Terminator().get_windows() + for window in self.windows: + window.connect('key-press-event', self.on_keypress) + return + + def callback(self, url): + """Actually we don't need to do anything for this to work""" + return(url) + + def extract(self): + #can we do extract more efficiently + col, row = self.vte.get_cursor_position() + (txt, attr) = self.vte.get_text_range(0,0,row, col) + self.matches = re.findall(self.searchtext, txt) + self.matches_ptr = len(self.matches)-1 + + def get_term(self): + return Terminator().last_focused_term + + def get_selected_url(self): + if len(self.matches): + dbg("selected URL (%s %s)" % (self.matches_ptr, self.matches[self.matches_ptr])) + return self.matches[self.matches_ptr] + dbg("selected URL (%s %s)" % (self.matches_ptr, "not found")) + return None + + def on_keypress(self, widget, event): + act = self.keyb.keyaction(event) + dbg("keyaction: (%s) (%s)" % (str(act), event.keyval)) + + if act == PluginUrlActFindNext: + if not self.flag_http_on: + dbg("search URL on") + self.search() + self.extract() + #so when we start search last item be selected + self.vte.search_find_previous() + self.get_selected_url() # dbg url print + self.vte.copy_clipboard() + return True + else: + self.vte.search_find_next() + + if (self.matches_ptr < len(self.matches)-1): + self.matches_ptr += 1 + else: + self.matches_ptr = 0 + + self.vte.copy_clipboard() + self.get_selected_url() # dbg url print + return True + + if act == PluginUrlActFindPrev: + if not self.flag_http_on: + self.search() + self.extract() + self.get_selected_url() # dbg url print + self.vte.search_find_previous() + self.vte.copy_clipboard() + return True + + self.vte.search_find_previous() + + if self.matches_ptr > 0: + self.matches_ptr -= 1 + elif len(self.matches): + self.matches_ptr = len(self.matches)-1 + + self.vte.copy_clipboard() + self.get_selected_url() # dbg url print + return True + + if act == PluginUrlActEsc: + self.matches = [] + self.vte = self.get_term().get_vte() + self.vte.search_set_regex(None, 0) + self.flag_http_on = False + dbg("search URL off") + + if act == PluginUrlActLaunch: + url = self.get_selected_url() + if url: + self.get_term().open_url(url, prepare=False) + + def search(self): + self.flag_http_on = True + self.vte = self.get_term().get_vte() + + self.vte.search_set_wrap_around(True) + regex_flags_pcre2 = (regex.FLAGS_PCRE2 | regex.PCRE2_CASELESS) + searchre = Vte.Regex.new_for_search(self.searchtext, + len(self.searchtext), regex_flags_pcre2) + + self.vte.search_set_regex(searchre, 0) + diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 10339c304..2a394c626 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -18,6 +18,8 @@ from .plugin import PluginRegistry from .version import APP_NAME +from .plugin_util import KeyBindUtil + def get_color_string(widcol): return('#%02x%02x%02x' % (widcol.red>>8, widcol.green>>8, widcol.blue>>8)) @@ -419,6 +421,15 @@ def set_values(self): liststore = widget.get_model() liststore.set_sort_column_id(0, Gtk.SortType.ASCENDING) keybindings = self.config['keybindings'] + + keybindutil = KeyBindUtil() + plugin_keyb_act = keybindutil.get_act_to_keys() + plugin_keyb_desc = keybindutil.get_act_to_desc() + #merge give preference to main bindings over plugin + keybindings = {**plugin_keyb_act, **keybindings} + self.keybindingnames = {**plugin_keyb_desc, **self.keybindingnames} + #dbg("appended actions %s names %s" % (keybindings, self.keybindingnames)) + for keybinding in keybindings: keyval = 0 mask = 0 @@ -1797,6 +1808,19 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): binding = liststore.get_value(liststore.get_iter(path), 0) accel = Gtk.accelerator_name(key, mods) self.config['keybindings'][binding] = accel + + keybindutil = KeyBindUtil() + plugin_keyb_desc = keybindutil.get_act_to_desc() + + if binding in plugin_keyb_desc: + if binding in plugin_keyb_desc: + desc = plugin_keyb_desc[binding] + dbg("modifying plugin binding: %s, %s, %s" % (desc, binding, accel)) + keybindutil.bindkey([desc, binding, accel]) + else: + dbg("skipping: %s" % binding) + pass + self.config.save() def on_cellrenderer_accel_cleared(self, liststore, path): From 3d63c915175a8b4955af1cf575a35127177894c8 Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Sat, 19 Nov 2022 22:50:41 -0500 Subject: [PATCH 032/101] [New Plugin] Plugin that inserts the name This plugin inserts the name of the terminal, as determined by Terminal.get_window_title() to all open terminals. Fixes #540 --- terminatorlib/plugins/insert_term_name.py | 20 ++++++++++++++++++++ terminatorlib/terminal.py | 2 ++ terminatorlib/terminator.py | 10 ++++++++++ 3 files changed, 32 insertions(+) create mode 100644 terminatorlib/plugins/insert_term_name.py diff --git a/terminatorlib/plugins/insert_term_name.py b/terminatorlib/plugins/insert_term_name.py new file mode 100644 index 000000000..fa35e39a5 --- /dev/null +++ b/terminatorlib/plugins/insert_term_name.py @@ -0,0 +1,20 @@ +from gi.repository import Gtk + +import terminatorlib.plugin as plugin +from terminatorlib.terminator import Terminator + +AVAILABLE = ['InsertTermName'] + +class InsertTermName(plugin.MenuItem): + capabilities = ['terminal_menu'] + config = None + + def __init__(self): + # self.connect_signals() + plugin.MenuItem.__init__(self) + + def callback(self, menuitems, menu, terminal): + item = Gtk.MenuItem.new_with_label('Insert terminal name') + item.connect('activate', lambda x: terminal.emit('insert-term-name')) + menuitems.append(item) + diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index cadd9c257..573177464 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -40,6 +40,7 @@ class Terminal(Gtk.VBox): 'close-term': (GObject.SignalFlags.RUN_LAST, None, ()), 'title-change': (GObject.SignalFlags.RUN_LAST, None, (GObject.TYPE_STRING,)), + 'insert-term-name': (GObject.SignalFlags.RUN_LAST, None, ()), 'enumerate': (GObject.SignalFlags.RUN_LAST, None, (GObject.TYPE_INT,)), 'group-tab': (GObject.SignalFlags.RUN_LAST, None, ()), @@ -126,6 +127,7 @@ def __init__(self): # FIXME: Surely these should happen in Terminator::register_terminal()? self.connect('enumerate', self.terminator.do_enumerate) + self.connect('insert-term-name', self.terminator.do_insert_term_name) self.connect('focus-in', self.terminator.focus_changed) self.connect('focus-out', self.terminator.focus_left) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 0fc58d56d..0fcd111bd 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -585,6 +585,16 @@ def do_enumerate(self, widget, pad): idx = terminals.index(term) term.feed(numstr.encode() % (idx + 1)) + def do_insert_term_name(self, widget): + terminals = [] + for window in self.windows: + containers, win_terminals = enumerate_descendants(window) + terminals.extend(win_terminals) + + for term in self.get_target_terms(widget): + name = term.titlebar.get_custom_string() or term.get_window_title() + term.feed(name) + def get_sibling_terms(self, widget): termset = [] for term in self.terminals: From 35e7e026cde98726010f533a8558d94de691500f Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Sun, 20 Nov 2022 13:42:20 -0500 Subject: [PATCH 033/101] add "Insert Terminal Name" to the group menu --- terminatorlib/plugins/insert_term_name.py | 2 -- terminatorlib/terminal.py | 4 ++++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/terminatorlib/plugins/insert_term_name.py b/terminatorlib/plugins/insert_term_name.py index fa35e39a5..f85b1eabe 100644 --- a/terminatorlib/plugins/insert_term_name.py +++ b/terminatorlib/plugins/insert_term_name.py @@ -1,7 +1,6 @@ from gi.repository import Gtk import terminatorlib.plugin as plugin -from terminatorlib.terminator import Terminator AVAILABLE = ['InsertTermName'] @@ -10,7 +9,6 @@ class InsertTermName(plugin.MenuItem): config = None def __init__(self): - # self.connect_signals() plugin.MenuItem.__init__(self) def callback(self, menuitems, menu, terminal): diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 573177464..ded0f4b51 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -587,6 +587,10 @@ def populate_group_menu(self): item.connect('activate', lambda x: self.emit('enumerate', True)) menu.append(item) + item = Gtk.MenuItem.new_with_mnemonic(_('Insert terminal _name')) + item.connect('activate', lambda x: self.emit('insert-term-name')) + menu.append(item) + return(menu) def set_group(self, _item, name): From 7bbb07c99348a9d6c57fed8f75e12d13e34ef3fd Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Mon, 21 Nov 2022 16:24:32 +0530 Subject: [PATCH 034/101] [bug 681] Plugin Submission + Generic Plugin Utility Functions & KeyBinding Feature: Mouseless / Mousefree / Keyboard URL opening or yanking #681 - there was a bug wherein the duplicate keybindings from plugins were not throwing the error "Duplicate Key Bindings Are Not Allowed", now while checking they are merged and then final list of keybindings are checked. --- terminatorlib/prefseditor.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 9d3bd7e9e..5cdfb3368 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -1814,8 +1814,14 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): current_binding = liststore.get_value(liststore.get_iter(path), 0) parsed_accel = Gtk.accelerator_parse(accel) + keybindutil = KeyBindUtil() + keybindings = self.config["keybindings"] + #merge give preference to main bindings over plugin + plugin_keyb_act = keybindutil.get_act_to_keys() + keybindings = {**plugin_keyb_act, **keybindings} + duplicate_bindings = [] - for conf_binding, conf_accel in self.config["keybindings"].items(): + for conf_binding, conf_accel in keybindings.items(): if conf_accel is None: continue @@ -1859,7 +1865,6 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): accel = Gtk.accelerator_name(key, mods) self.config['keybindings'][binding] = accel - keybindutil = KeyBindUtil() plugin_keyb_desc = keybindutil.get_act_to_desc() if binding in plugin_keyb_desc: From 3e15ae40dfd23fde7d56be138cf7383a4de31fbe Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Mon, 21 Nov 2022 18:12:54 +0530 Subject: [PATCH 035/101] [bug 681] Plugin Submission + Generic Plugin Utility Functions & KeyBinding Feature: Mouseless / Mousefree / Keyboard URL opening or yanking #681 -convert control keys keyval to standard lowercase, else signals are missing --- terminatorlib/plugin_util.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/terminatorlib/plugin_util.py b/terminatorlib/plugin_util.py index e4a7c5c4f..e65476866 100644 --- a/terminatorlib/plugin_util.py +++ b/terminatorlib/plugin_util.py @@ -58,6 +58,7 @@ def bindkey_check_config(self, key, config): def bindkey(self, key): (keyval, mask) = self.keybindings._parsebinding(key[PLUGIN_UTIL_KEYS]) + keyval = Gdk.keyval_to_lower(keyval) mask = Gdk.ModifierType(mask) ret = (keyval, mask) @@ -82,7 +83,8 @@ def keyaction(self, event): #FIXME MOD2 mask comes in the event, remove event.state &= ~Gdk.ModifierType.MOD2_MASK - ret = (event.keyval, event.state) + keyval = Gdk.keyval_to_lower(event.keyval) + ret = (keyval, event.state) dbg("keyaction: (%s)" % str(ret)) return self.map_key_to_act.get(ret, None) From d3d64d406d1dfebf87e0e0a063b553725476276f Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Tue, 22 Nov 2022 00:48:20 +0000 Subject: [PATCH 036/101] Translate /po/terminator.pot in pt_BR translation completed for the source file '/po/terminator.pot' on the 'pt_BR' language. --- po/pt_BR.po | 233 ++++++++++++---------------------------------------- 1 file changed, 52 insertions(+), 181 deletions(-) diff --git a/po/pt_BR.po b/po/pt_BR.po index a15a853cf..643bbe0e9 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -2,26 +2,26 @@ # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. -# +# # Translators: # Gnome Terminator , 2020 # Anthony Louis , 2021 -# +# C. E., 2022 +# #, fuzzy msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-22 00:51+0100\n" +"POT-Creation-Date: 2022-10-19 09:29-0400\n" "PO-Revision-Date: 2020-04-22 08:11+0000\n" -"Last-Translator: Anthony Louis , 2021\n" -"Language-Team: Portuguese (Brazil) (https://www.transifex.com/terminator/" -"teams/109338/pt_BR/)\n" -"Language: pt_BR\n" +"Last-Translator: C. E., 2022\n" +"Language-Team: Portuguese (Brazil) (https://www.transifex.com/terminator/teams/109338/pt_BR/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: nplurals=2; plural=(n > 1);\n" +"Language: pt_BR\n" +"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n" #. Command uuid req. Description #: ../remotinator.py:39 @@ -70,11 +70,11 @@ msgstr "Definir título de uma guia superior" #: ../remotinator.py:50 msgid "Set the background image" -msgstr "" +msgstr "Definir a imagem de fundo" #: ../remotinator.py:51 msgid "Set the background image for all terminals" -msgstr "" +msgstr "Definir a imagem de fundo para todos os terminais" #: ../remotinator.py:52 msgid "Switch current terminal profile" @@ -82,7 +82,7 @@ msgstr "Trocar o perfil atual do terminal" #: ../remotinator.py:53 msgid "Switch profile of all currently running terminals" -msgstr "" +msgstr "Troca o perfil de todos os terminais atualmente em execução" #: ../remotinator.py:70 #, python-format @@ -108,15 +108,15 @@ msgstr "Terminal UUID para quando não estiver em TERMINATOR_UUID" #: ../remotinator.py:80 msgid "Profile name to switch to" -msgstr "" +msgstr "Mudar o nome do perfil para" #: ../remotinator.py:83 msgid "File to pass to command" -msgstr "" +msgstr "Arquivo para passar ao comando" #: ../remotinator.py:86 msgid "Command to run in new terminal" -msgstr "" +msgstr "Comando para executar em novo terminal" #: ../remotinator.py:89 msgid "Tab name to set. Only used with \"set_tab_title\" command." @@ -126,7 +126,7 @@ msgstr "" #: ../remotinator.py:92 msgid "Tab name to set." -msgstr "" +msgstr "Definir nome da Aba" #: ../data/terminator.desktop.in.h:1 ../data/terminator.appdata.xml.in.h:1 #: ../terminatorlib/plugins/activitywatch.py:83 @@ -148,8 +148,8 @@ msgstr "O robo do futuro dos terminais" msgid "" "A power-user tool for arranging terminals. It is inspired by programs such " "as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging " -"terminals in grids (tabs is the most common default method, which Terminator " -"also supports)." +"terminals in grids (tabs is the most common default method, which Terminator" +" also supports)." msgstr "" "Uma ferramenta destinada aos superusuários, útil para organização de " "terminais. Esta foi inspirada por programas como gnome-multi-term, " @@ -164,8 +164,8 @@ msgid "" "users." msgstr "" "Muito do comportamento do Terminator é baseado no Terminal do Gnome, e " -"estamos adicionando mais recursos com o passar do tempo, mas também queremos " -"estender isso em diferentes recursos para administradores e sistemas e " +"estamos adicionando mais recursos com o passar do tempo, mas também queremos" +" estender isso em diferentes recursos para administradores e sistemas e " "outros usuários." #: ../data/terminator.appdata.xml.in.h:6 @@ -366,11 +366,11 @@ msgstr "" #: ../terminatorlib/optionparse.py:100 msgid "List all profiles" -msgstr "" +msgstr "Listar todos os perfis" #: ../terminatorlib/optionparse.py:102 msgid "List all layouts" -msgstr "" +msgstr "Listar todos os layouts" #: ../terminatorlib/plugins/activitywatch.py:54 msgid "Watch for _activity" @@ -768,7 +768,7 @@ msgstr "" #: ../terminatorlib/preferences.glade.h:64 msgid "Disable mouse paste" -msgstr "" +msgstr "Desativar a cola do mouse" #: ../terminatorlib/preferences.glade.h:65 msgid "Custom URL handler:" @@ -796,11 +796,11 @@ msgstr "Estilização extra(Depende do tema)" #: ../terminatorlib/preferences.glade.h:71 msgid "Cell Height:" -msgstr "" +msgstr "Altura da célula:" #: ../terminatorlib/preferences.glade.h:72 msgid "Cell Width:" -msgstr "" +msgstr "Largura da célula:" #: ../terminatorlib/preferences.glade.h:73 msgid "Tab position:" @@ -872,11 +872,11 @@ msgstr "Piscar" #: ../terminatorlib/preferences.glade.h:90 msgid "Use default colors" -msgstr "" +msgstr "Usar cores padrão" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "" +msgstr "Primeiro plano:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" @@ -936,11 +936,11 @@ msgstr "Es_quemas embutidos:" #: ../terminatorlib/preferences.glade.h:107 msgid "_Foreground:" -msgstr "" +msgstr "_Foreground:" #: ../terminatorlib/preferences.glade.h:108 msgid "_Background:" -msgstr "" +msgstr "_Background:" #: ../terminatorlib/preferences.glade.h:109 msgid "Palette" @@ -1030,8 +1030,8 @@ msgstr "Rolagem" msgid "" "Note: These options may cause some applications to behave " "incorrectly. They are only here to allow you to work around certain " -"applications and operating systems that expect different terminal behavior." +"applications and operating systems that expect different terminal " +"behavior." msgstr "" "Nota: Estas opções podem levar alguns aplicativos a se " "comportarem incorretamente. Elas existem apenas para permitir que você " @@ -1080,7 +1080,7 @@ msgstr "Escolher Uma Fonte para Barra de Títulos" #: ../terminatorlib/preferences.glade.h:141 msgid "Titlebar" -msgstr "" +msgstr "Barra de título" #: ../terminatorlib/preferences.glade.h:142 #: ../terminatorlib/terminal_popup_menu.py:204 @@ -1137,27 +1137,12 @@ msgstr "Versão: 2.11" #: ../terminatorlib/preferences.glade.h:159 msgid "" -"The goal of this project is to produce a useful tool for arranging " -"terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, " -"etc. in that the main focus is arranging terminals in grids (tabs is the " -"most common default method, which Terminator also supports).\n" +"The goal of this project is to produce a useful tool for arranging terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging terminals in grids (tabs is the most common default method, which Terminator also supports).\n" "\n" -"Much of the behavior of Terminator is based on GNOME Terminal, and we are " -"adding more features from that as time goes by, but we also want to extend " -"out in different directions with useful features for sysadmins and other " -"users. If you have any suggestions, please file wishlist bugs! (see left for " -"the Development link)" +"Much of the behavior of Terminator is based on GNOME Terminal, and we are adding more features from that as time goes by, but we also want to extend out in different directions with useful features for sysadmins and other users. If you have any suggestions, please file wishlist bugs! (see left for the Development link)" msgstr "" -"O objetivo deste projeto é fornecer uma ferramenta útil para organização de " -"terminais. Esta foi inspirada por programas como gnome-multi-term, " -"quadkonsole, etc. em que o objetivo principal é organizar terminais em " -"grades (abas é o método mais comum, o qual o Terminator também suporta).\n" -"O comportamento do Terminator é baseado no Terminal do Gnome, e estamos " -"adicionando mais recursos com o passar do tempo, mas também queremos " -"estender isso em diferentes recursos para administradores e sistemas e " -"outros usuários. Se você tem alguma sugestão, por favor, relate os bugs e " -"possíveis melhorias na lista de desejo! (Veja a esquerda para o link para " -"desenvolvimento)" +"O objetivo deste projeto é fornecer uma ferramenta útil para organização de terminais. Esta foi inspirada por programas como gnome-multi-term, quadkonsole, etc. em que o objetivo principal é organizar terminais em grades (abas é o método mais comum, o qual o Terminator também suporta).\n" +"O comportamento do Terminator é baseado no Terminal do Gnome, e estamos adicionando mais recursos com o passar do tempo, mas também queremos estender isso em diferentes recursos para administradores e sistemas e outros usuários. Se você tem alguma sugestão, por favor, relate os bugs e possíveis melhorias na lista de desejo! (Veja a esquerda para o link para desenvolvimento)" #: ../terminatorlib/preferences.glade.h:162 msgid "The Manual" @@ -1166,13 +1151,10 @@ msgstr "O Manual" #: ../terminatorlib/preferences.glade.h:163 msgid "" "Development\n" -"Bugs / " -"Enhancements" +"Bugs / Enhancements" msgstr "" -"Desenvolvimento\n" -"Bugs / " -"Melhorias" +"Desenvolvimento\n" +"Bugs / Melhorias" #: ../terminatorlib/preferences.glade.h:165 msgid "About" @@ -1260,7 +1242,7 @@ msgstr "Colar área de transferência" #: ../terminatorlib/prefseditor.py:126 msgid "Paste primary selection" -msgstr "" +msgstr "Colar seleção primária" #: ../terminatorlib/prefseditor.py:127 msgid "Show/Hide the scrollbar" @@ -1412,15 +1394,15 @@ msgstr "Desagrupar todos os terminais" #: ../terminatorlib/prefseditor.py:164 msgid "Group terminals in window" -msgstr "" +msgstr "Agrupar terminais na janela" #: ../terminatorlib/prefseditor.py:165 msgid "Group/Ungroup terminals in window" -msgstr "" +msgstr "Agrupar/Desagrupar terminais na janela" #: ../terminatorlib/prefseditor.py:166 msgid "Ungroup terminals in window" -msgstr "" +msgstr "Desagrupar terminais na janela" #: ../terminatorlib/prefseditor.py:167 msgid "Group terminals in tab" @@ -1494,11 +1476,11 @@ msgstr "Abrir janela de Preferências" msgid "Open the manual" msgstr "Abrir o manual" -#: ../terminatorlib/prefseditor.py:1370 +#: ../terminatorlib/prefseditor.py:1366 msgid "New Profile" msgstr "Novo perfil" -#: ../terminatorlib/prefseditor.py:1413 ../terminatorlib/prefseditor.py:1418 +#: ../terminatorlib/prefseditor.py:1409 ../terminatorlib/prefseditor.py:1414 msgid "New Layout" msgstr "Nova disposição" @@ -1545,7 +1527,7 @@ msgstr "_Colar" #: ../terminatorlib/terminal_popup_menu.py:112 msgid "Set W_indow Title" -msgstr "" +msgstr "Definir o título da W_indow" #: ../terminatorlib/terminal_popup_menu.py:117 msgid "Split H_orizontally" @@ -1610,11 +1592,11 @@ msgstr "Remover grupo %s" #: ../terminatorlib/terminal.py:512 msgid "G_roup all in window" -msgstr "" +msgstr "Ag_rupar todas as janelas" #: ../terminatorlib/terminal.py:517 msgid "Ungro_up all in window" -msgstr "" +msgstr "Desagr_upar todas as janelas" #: ../terminatorlib/terminal.py:522 msgid "G_roup all in tab" @@ -1661,19 +1643,19 @@ msgstr "_Inserir número do terminal" msgid "Insert _padded terminal number" msgstr "Inserir _monte de números de terminal" -#: ../terminatorlib/terminal.py:1490 +#: ../terminatorlib/terminal.py:1492 msgid "Unable to find a shell" msgstr "Incapaz de encontrar um shell" -#: ../terminatorlib/terminal.py:1521 +#: ../terminatorlib/terminal.py:1546 msgid "Unable to start shell:" msgstr "Incapaz de iniciar o shell:" -#: ../terminatorlib/terminal.py:1975 +#: ../terminatorlib/terminal.py:2000 msgid "Rename Window" msgstr "Renomear janela" -#: ../terminatorlib/terminal.py:1983 +#: ../terminatorlib/terminal.py:2008 msgid "Enter a new title for the Terminator window..." msgstr "Insira um novo título para a janela do terminal" @@ -1784,120 +1766,9 @@ msgstr "janela" #: ../terminatorlib/window.py:773 #, python-format msgid "Window group %s" -msgstr "" +msgstr "Grupo de janelas %s" #: ../terminatorlib/window.py:799 #, python-format msgid "Tab %d" msgstr "Aba %d" - -#~ msgid "Current Locale" -#~ msgstr "Localização atual" - -#~ msgid "Western" -#~ msgstr "Ocidental" - -#~ msgid "Central European" -#~ msgstr "Europa Central" - -#~ msgid "South European" -#~ msgstr "Sul da Europa" - -#~ msgid "Baltic" -#~ msgstr "Báltico" - -#~ msgid "Cyrillic" -#~ msgstr "Cirílico" - -#~ msgid "Arabic" -#~ msgstr "Arábico" - -#~ msgid "Greek" -#~ msgstr "Grego" - -#~ msgid "Hebrew Visual" -#~ msgstr "Visual Hebraico" - -#~ msgid "Hebrew" -#~ msgstr "Hebraico" - -#~ msgid "Turkish" -#~ msgstr "Turco" - -#~ msgid "Nordic" -#~ msgstr "Nórdico" - -#~ msgid "Celtic" -#~ msgstr "Celta" - -#~ msgid "Romanian" -#~ msgstr "Romeno" - -#~ msgid "Unicode" -#~ msgstr "Unicode" - -#~ msgid "Armenian" -#~ msgstr "Armênio" - -#~ msgid "Chinese Traditional" -#~ msgstr "Chinês tradicional" - -#~ msgid "Cyrillic/Russian" -#~ msgstr "Cirílico/Russo" - -#~ msgid "Japanese" -#~ msgstr "Japonês" - -#~ msgid "Korean" -#~ msgstr "Coreano" - -#~ msgid "Chinese Simplified" -#~ msgstr "Chinês simplificado" - -#~ msgid "Georgian" -#~ msgstr "Geórgio" - -#~ msgid "Cyrillic/Ukrainian" -#~ msgstr "Cirílico/Ucraniano" - -#~ msgid "Croatian" -#~ msgstr "Croata" - -#~ msgid "Hindi" -#~ msgstr "Hindu" - -#~ msgid "Persian" -#~ msgstr "Persa" - -#~ msgid "Gujarati" -#~ msgstr "Guzarate" - -#~ msgid "Gurmukhi" -#~ msgstr "Gurmukhi" - -#~ msgid "Icelandic" -#~ msgstr "Islandês" - -#~ msgid "Vietnamese" -#~ msgstr "Vietnamita" - -#~ msgid "Thai" -#~ msgstr "Tailandês" - -#~ msgid "Line Height:" -#~ msgstr "Altura da linha" - -#~ msgid "Encoding:" -#~ msgstr "Codificação" - -#~ msgid "Encodings" -#~ msgstr "Codificações" - -#~ msgid "Default" -#~ msgstr "Padrão" - -#~ msgid "User defined" -#~ msgstr "Definido pelo usuário" - -#~ msgid "Other Encodings" -#~ msgstr "Outras codificações" From 8edebc6ca53cfa1c4074a9ad455c876a3a981be4 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Tue, 22 Nov 2022 15:18:26 +0530 Subject: [PATCH 037/101] [bug 681] Plugin Submission + Generic Plugin Utility Functions & KeyBinding Feature: Mouseless / Mousefree / Keyboard URL opening or yanking #681 - removed plugin_util - added key unbind feature - updated plugin helper - updated plugin helper - to have config as part of constructor - updated MouseFreeURLHandler for plugin.py, unload - removed circular dependency between plugin.py and config.py due to KeyBindUtil due to merging of plugin_util.py --- terminatorlib/config.py | 2 +- terminatorlib/plugin.py | 121 ++++++++++++++++++ terminatorlib/plugin_util.py | 95 -------------- .../plugins/mousefree_url_handler.py | 37 ++++-- terminatorlib/prefseditor.py | 2 +- 5 files changed, 148 insertions(+), 109 deletions(-) delete mode 100644 terminatorlib/plugin_util.py diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 7bb23c7fe..7129512cf 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -77,7 +77,6 @@ from validate import Validator from .borg import Borg from .util import dbg, err, DEBUG, get_system_config_dir, get_config_dir, dict_diff, update_config_to_cell_height -from terminatorlib.plugin_util import KeyBindUtil from gi.repository import Gio @@ -721,6 +720,7 @@ def save(self): dbg('Processing section: %s' % section_name) section = getattr(self, section_name) if section_name == 'keybindings': + from terminatorlib.plugin import KeyBindUtil # for plugin KeyBindUtil assist in plugin_util keybindutil = KeyBindUtil(); keyb_keys = keybindutil.get_act_to_keys() diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py index 7a0487a40..db18835bb 100644 --- a/terminatorlib/plugin.py +++ b/terminatorlib/plugin.py @@ -187,3 +187,124 @@ class MenuItem(Plugin): def callback(self, menuitems, menu, terminal): """Callback to transform the enclosed URL""" raise NotImplementedError + + +""" +-Basic plugin util for key-press handling, has all mapping to be used +in layout keybindings + +Vishweshwar Saran Singh Deo vssdeo@gmail.com +""" + +from gi.repository import Gtk, Gdk +from terminatorlib.keybindings import Keybindings, KeymapError + +PLUGIN_UTIL_DESC = 0 +PLUGIN_UTIL_ACT = 1 +PLUGIN_UTIL_KEYS = 2 + +class KeyBindUtil: + + keybindings = Keybindings() + + map_key_to_act = {} + map_act_to_keys = {} + map_act_to_desc = {} + + def __init__(self, config=None): + self.config = config + + #Example + # bind + # first param is desc, second is action str + # self.keyb.bindkey([PluginUrlFindNext , PluginUrlActFindNext, "j"]) + # + # get action name + # act = self.keyb.keyaction(event) + + # if act == "url_find_next": + + + #check map key_val_mask -> action + def _check_keybind_change(self, key): + act = key[PLUGIN_UTIL_ACT] + for key_val_mask in self.map_key_to_act: + old_act = self.map_key_to_act[key_val_mask] + if act == old_act: + return key_val_mask + return None + + #check in config before binding + def bindkey_check_config(self, key): + if not self.config: + raise Warning("bindkey_check_config called without config init") + + actstr = key[PLUGIN_UTIL_ACT] + kbsect = self.config.base.get_item('keybindings') + keystr = kbsect[actstr] if actstr in kbsect else "" + dbg("bindkey_check_config:action (%s) key str:(%s)" % (actstr, keystr)) + if len(keystr): + key[PLUGIN_UTIL_KEYS] = keystr + dbg("found new Action->KeyVal in config: (%s, %s)" + % (actstr, keystr)); + self.bindkey(key) + + def bindkey(self, key): + (keyval, mask) = self.keybindings._parsebinding(key[PLUGIN_UTIL_KEYS]) + keyval = Gdk.keyval_to_lower(keyval) + mask = Gdk.ModifierType(mask) + + ret = (keyval, mask) + dbg("bindkey: (%s) (%s)" % (key[PLUGIN_UTIL_KEYS], str(ret))) + + #remove if any old key_val_mask + old_key_val_mask = self._check_keybind_change(key) + if old_key_val_mask: + dbg("found old key binding, removing: (%s)" % str(old_key_val_mask)) + del self.map_key_to_act[old_key_val_mask] + + #map key-val-mask to action, used to ease key-press management + self.map_key_to_act[ret] = key[PLUGIN_UTIL_ACT] + + + #map action to key-combo-str, used in preferences->keybinding + self.map_act_to_keys[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_KEYS] + #map action to key-combo description, in used preferences->keybinding + self.map_act_to_desc[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_DESC] + + def unbindkey(self, key): + + # Suppose user changed the key-combo and its diff from + # what the plugin had set by default, we need to get + # current key-combo + act = key[PLUGIN_UTIL_ACT] + act_keys = self.map_act_to_keys[act] + + (keyval, mask) = self.keybindings._parsebinding(act_keys) + keyval = Gdk.keyval_to_lower(keyval) + mask = Gdk.ModifierType(mask) + + ret = (keyval, mask) + dbg("unbindkey: (%s) (%s)" % (key[PLUGIN_UTIL_KEYS], str(ret))) + + # FIXME keys should always be there, can also use .pop(key, None) + # lets do it after testing + del self.map_key_to_act[ret] + del self.map_act_to_keys[key[PLUGIN_UTIL_ACT]] + del self.map_act_to_desc[key[PLUGIN_UTIL_ACT]] + + + def keyaction(self, event): + #FIXME MOD2 mask comes in the event, remove + event.state &= ~Gdk.ModifierType.MOD2_MASK + + keyval = Gdk.keyval_to_lower(event.keyval) + ret = (keyval, event.state) + dbg("keyaction: (%s)" % str(ret)) + return self.map_key_to_act.get(ret, None) + + def get_act_to_keys(self): + return self.map_act_to_keys + + def get_act_to_desc(self): + return self.map_act_to_desc diff --git a/terminatorlib/plugin_util.py b/terminatorlib/plugin_util.py deleted file mode 100644 index e65476866..000000000 --- a/terminatorlib/plugin_util.py +++ /dev/null @@ -1,95 +0,0 @@ -""" --Basic plugin util for key-press handling, has all mapping to be used -in layout keybindings - -Vishweshwar Saran Singh Deo vssdeo@gmail.com -""" - -from gi.repository import Gtk, Gdk - -from terminatorlib.util import get_config_dir, err, dbg, gerr -from terminatorlib.keybindings import Keybindings, KeymapError - -PLUGIN_UTIL_DESC = 0 -PLUGIN_UTIL_ACT = 1 -PLUGIN_UTIL_KEYS = 2 - -#FIXME to sync this with keybinding preferences -class KeyBindUtil: - - keybindings = Keybindings() - - map_key_to_act = {} - map_act_to_keys = {} - map_act_to_desc = {} - - - #Example - # bind - # first param is desc, second is action str - # self.keyb.bindkey([PluginUrlFindNext , PluginUrlActFindNext, "j"]) - # - # get action name - # act = self.keyb.keyaction(event) - - # if act == "url_find_next": - - - #check map key_val_mask -> action - def _check_keybind_change(self, key): - act = key[PLUGIN_UTIL_ACT] - for key_val_mask in self.map_key_to_act: - old_act = self.map_key_to_act[key_val_mask] - if act == old_act: - return key_val_mask - return None - - #check in config before binding - def bindkey_check_config(self, key, config): - actstr = key[PLUGIN_UTIL_ACT] - kbsect = config.base.get_item('keybindings') - keystr = kbsect[actstr] if actstr in kbsect else "" - dbg("bindkey_check_config:action (%s) key str:(%s)" % (actstr, keystr)) - if len(keystr): - key[PLUGIN_UTIL_KEYS] = keystr - dbg("found new Action->KeyVal in config: (%s, %s)" - % (actstr, keystr)); - self.bindkey(key) - - def bindkey(self, key): - (keyval, mask) = self.keybindings._parsebinding(key[PLUGIN_UTIL_KEYS]) - keyval = Gdk.keyval_to_lower(keyval) - mask = Gdk.ModifierType(mask) - - ret = (keyval, mask) - dbg("bindkey: (%s) (%s)" % (key[PLUGIN_UTIL_KEYS], str(ret))) - - #remove if any old key_val_mask - old_key_val_mask = self._check_keybind_change(key) - if old_key_val_mask: - dbg("found old key binding, removing: (%s)" % str(old_key_val_mask)) - del self.map_key_to_act[old_key_val_mask] - - #map key-val-mask to action, used to ease key-press management - self.map_key_to_act[ret] = key[PLUGIN_UTIL_ACT] - - - #map action to key-combo-str, used in preferences->keybinding - self.map_act_to_keys[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_KEYS] - #map action to key-combo description, in used preferences->keybinding - self.map_act_to_desc[key[PLUGIN_UTIL_ACT]] = key[PLUGIN_UTIL_DESC] - - def keyaction(self, event): - #FIXME MOD2 mask comes in the event, remove - event.state &= ~Gdk.ModifierType.MOD2_MASK - - keyval = Gdk.keyval_to_lower(event.keyval) - ret = (keyval, event.state) - dbg("keyaction: (%s)" % str(ret)) - return self.map_key_to_act.get(ret, None) - - def get_act_to_keys(self): - return self.map_act_to_keys - - def get_act_to_desc(self): - return self.map_act_to_desc diff --git a/terminatorlib/plugins/mousefree_url_handler.py b/terminatorlib/plugins/mousefree_url_handler.py index 37c80f903..bb782ea3f 100644 --- a/terminatorlib/plugins/mousefree_url_handler.py +++ b/terminatorlib/plugins/mousefree_url_handler.py @@ -14,10 +14,9 @@ from terminatorlib.config import Config import terminatorlib.plugin as plugin -from terminatorlib.plugin_util import KeyBindUtil +from terminatorlib.plugin import KeyBindUtil from terminatorlib.util import get_config_dir, err, dbg, gerr -from terminatorlib.keybindings import Keybindings, KeymapError from terminatorlib import regex import re @@ -45,7 +44,8 @@ class MouseFreeURLHandler(plugin.Plugin): match = None flag_http_on = False - keyb = KeyBindUtil() + config = Config() + keyb = KeyBindUtil(config) matches = [] matches_ptr = -1 #basic pattern @@ -54,21 +54,34 @@ class MouseFreeURLHandler(plugin.Plugin): def __init__(self): self.connect_signals() - config = Config() - self.keyb.bindkey_check_config([PluginUrlFindNext , PluginUrlActFindNext, "j"], config) - self.keyb.bindkey_check_config([PluginUrlFindPrev , PluginUrlActFindPrev, "k"], config) - self.keyb.bindkey_check_config([PluginUrlEsc , PluginUrlActEsc, "Escape"], config) - self.keyb.bindkey_check_config([PluginUrlLaunch, PluginUrlActLaunch, "Return"], config) + self.keyb.bindkey_check_config( + [PluginUrlFindNext , PluginUrlActFindNext, "j"]) + self.keyb.bindkey_check_config( + [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) + self.keyb.bindkey_check_config( + [PluginUrlEsc , PluginUrlActEsc, "Escape"]) + self.keyb.bindkey_check_config( + [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) def connect_signals(self): self.windows = Terminator().get_windows() for window in self.windows: window.connect('key-press-event', self.on_keypress) - return - def callback(self, url): - """Actually we don't need to do anything for this to work""" - return(url) + + def unload(self): + # + for window in self.windows: + window.disconnect_by_func(self.on_keypress) + + self.keyb.unbindkey( + [PluginUrlFindNext , PluginUrlActFindNext, "j"]) + self.keyb.unbindkey( + [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) + self.keyb.unbindkey( + [PluginUrlEsc , PluginUrlActEsc, "Escape"]) + self.keyb.unbindkey( + [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) def extract(self): #can we do extract more efficiently diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 5cdfb3368..f34a0fac4 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -18,7 +18,7 @@ from .plugin import PluginRegistry from .version import APP_NAME -from .plugin_util import KeyBindUtil +from .plugin import KeyBindUtil def get_color_string(widcol): return('#%02x%02x%02x' % (widcol.red>>8, widcol.green>>8, widcol.blue>>8)) From 8e5e6d1642c2959a2d57282552af4ca29b882fa2 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 23 Nov 2022 15:34:22 +0530 Subject: [PATCH 038/101] [bug 681] Plugin Submission + Generic Plugin Utility Functions & KeyBinding Feature: Mouseless / Mousefree / Keyboard URL opening or yanking #681 - renamed api interfacted for better clarity - removed double checking of short-cut binding for plugins in keybindings --- terminatorlib/config.py | 2 +- terminatorlib/plugin.py | 18 ++++++++++++++++-- terminatorlib/prefseditor.py | 24 +++++++++++------------- 3 files changed, 28 insertions(+), 16 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 7129512cf..04b08c8e8 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -723,7 +723,7 @@ def save(self): from terminatorlib.plugin import KeyBindUtil # for plugin KeyBindUtil assist in plugin_util keybindutil = KeyBindUtil(); - keyb_keys = keybindutil.get_act_to_keys() + keyb_keys = keybindutil.get_all_act_to_keys() # we only need keys as a reference so to match them # against new values keyb_keys = dict.fromkeys(keyb_keys, "") diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py index db18835bb..8ab8ddf8f 100644 --- a/terminatorlib/plugin.py +++ b/terminatorlib/plugin.py @@ -303,8 +303,22 @@ def keyaction(self, event): dbg("keyaction: (%s)" % str(ret)) return self.map_key_to_act.get(ret, None) - def get_act_to_keys(self): + def get_act_to_keys(self, key): + return self.map_act_to_keys.get(key) + + def get_all_act_to_keys(self): return self.map_act_to_keys - def get_act_to_desc(self): + def get_all_act_to_desc(self): return self.map_act_to_desc + + def get_act_to_desc(self, act): + return self.map_act_to_desc.get(act) + + #get action to key binding from config + def get_act_to_keys_config(self, act): + if not self.config: + raise Warning("get_keyvalmask_for_act called without config init") + + keybindings = self.config["keybindings"] + return keybindings.get(act) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index f34a0fac4..055b8b0ae 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -464,8 +464,8 @@ def on_search_refilter(widget): keybindings = self.config['keybindings'] keybindutil = KeyBindUtil() - plugin_keyb_act = keybindutil.get_act_to_keys() - plugin_keyb_desc = keybindutil.get_act_to_desc() + plugin_keyb_act = keybindutil.get_all_act_to_keys() + plugin_keyb_desc = keybindutil.get_all_act_to_desc() #merge give preference to main bindings over plugin keybindings = {**plugin_keyb_act, **keybindings} self.keybindingnames = {**plugin_keyb_desc, **self.keybindingnames} @@ -1817,7 +1817,7 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): keybindutil = KeyBindUtil() keybindings = self.config["keybindings"] #merge give preference to main bindings over plugin - plugin_keyb_act = keybindutil.get_act_to_keys() + plugin_keyb_act = keybindutil.get_all_act_to_keys() keybindings = {**plugin_keyb_act, **keybindings} duplicate_bindings = [] @@ -1865,16 +1865,14 @@ def on_cellrenderer_accel_edited(self, liststore, path, key, mods, _code): accel = Gtk.accelerator_name(key, mods) self.config['keybindings'][binding] = accel - plugin_keyb_desc = keybindutil.get_act_to_desc() - - if binding in plugin_keyb_desc: - if binding in plugin_keyb_desc: - desc = plugin_keyb_desc[binding] - dbg("modifying plugin binding: %s, %s, %s" % (desc, binding, accel)) - keybindutil.bindkey([desc, binding, accel]) - else: - dbg("skipping: %s" % binding) - pass + plugin_keyb_desc = keybindutil.get_act_to_desc(binding) + if plugin_keyb_desc: + dbg("modifying plugin binding: %s, %s, %s" % + (plugin_keyb_desc, binding, accel)) + keybindutil.bindkey([plugin_keyb_desc, binding, accel]) + else: + dbg("skipping: %s" % binding) + pass self.config.save() From 98dcd0efec6daa88ccc5957ad04b52083fcc45d0 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 23 Nov 2022 20:02:26 +0530 Subject: [PATCH 039/101] [bug 680] Open up keybindings page on keypress #680 - implemented the short-cut - seems the key combo is already taken 'go_prev' : 'p' - How about : 'k', I will make the change for now. - But adding key seq to a long list of keypress function breaks my heart, If the plugin util keybind makes it to the main branch, I will take this out and may be have a shortcut plugin to handle these. - Also selecting of Keybindings page is being done for this specific case Page = 3 - A notebook tab number and title map would remove this. Which can be configurable, later. --- terminatorlib/config.py | 1 + terminatorlib/prefseditor.py | 9 +++++++-- terminatorlib/terminal.py | 5 +++++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 8feec7fe3..80c29cbd0 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -202,6 +202,7 @@ 'next_profile' : '', 'previous_profile' : '', 'preferences' : '', + 'preferences_keybindings' : 'k', 'help' : 'F1' }, 'profiles': { diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 633652401..a333069f3 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -181,11 +181,12 @@ class PrefsEditor: 'layout_launcher' : _('Open layout launcher window'), 'next_profile' : _('Switch to next profile'), 'previous_profile' : _('Switch to previous profile'), - 'preferences' : _('Open the Preferences window'), + 'preferences' : _('Open the Preferences window'), + 'preferences_keybindings' : _('Open the Preferences-Keybindings window'), 'help' : _('Open the manual') } - def __init__ (self, term): + def __init__ (self, term, cur_page=0): self.config = config.Config() self.config.base.reload() self.term = term @@ -228,6 +229,10 @@ def __init__ (self, term): err('Unable to set values: %s' % e) self.config.uninhibit_save() + guiget = self.builder.get_object + nb = guiget('notebook1') + nb.set_current_page(cur_page) + def on_closebutton_clicked(self, _button): """Close the window""" terminator = Terminator() diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index c3cd4b037..9f633a66c 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -2080,6 +2080,11 @@ def key_line_down(self): def key_preferences(self): PrefsEditor(self) + def key_preferences_keybindings(self): + #need to have this as a config may be preferences_default + #have a mapping rather than hardcoded page + PrefsEditor(self, cur_page = 3) + def key_help(self): manual_index_page = manual_lookup() if manual_index_page: From 285022ef29bef2ae835230294e048c15225dc3cc Mon Sep 17 00:00:00 2001 From: Dante Calderon Date: Mon, 5 Dec 2022 20:37:57 -0500 Subject: [PATCH 040/101] Update comment --- terminator | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/terminator b/terminator index 5f5c33a30..c0891f317 100755 --- a/terminator +++ b/terminator @@ -112,8 +112,7 @@ if __name__ == '__main__': if(OPTIONS.reload): # Reload only is executed when exist at least one window, - # Check if exist another way to know if master process is not active. - dbg('reload option, killing app') + # if not there is nothing to reload sys.exit() except ipc.DBusException: From c84821e36abe45890518ba8ff63449c9932bd124 Mon Sep 17 00:00:00 2001 From: nicbn Date: Tue, 6 Dec 2022 18:08:01 -0300 Subject: [PATCH 041/101] Make Ctrl+Click on group button automatically create groups --- terminatorlib/terminal.py | 8 +++++++- terminatorlib/terminator.py | 17 +++++++++++++++++ terminatorlib/titlebar.py | 16 +--------------- 3 files changed, 25 insertions(+), 16 deletions(-) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index cadd9c257..401886bf0 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -879,7 +879,13 @@ def on_group_button_press(self, widget, event): focused=self.get_toplevel().get_focussed_terminal() if focused in targets: targets.remove(focused) if self != focused: - if self.group == focused.group: + if focused.group is None and self.group is None: + # Create a new group and assign currently focused + # terminal to this group + new_group = self.terminator.new_random_group() + focused.set_group(None, new_group) + focused.titlebar.update() + elif self.group == focused.group: new_group = None else: new_group = focused.group diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 0fc58d56d..e5274d47b 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -8,6 +8,8 @@ gi.require_version('Vte', '2.91') from gi.repository import Gtk, Gdk, Vte from gi.repository.GLib import GError +import itertools +import random from . import borg from .borg import Borg @@ -16,6 +18,7 @@ from .util import dbg, err, enumerate_descendants from .factory import Factory from .version import APP_NAME, APP_VERSION +from .translation import _ try: from gi.repository import GdkX11 @@ -638,4 +641,18 @@ def zoom_out_all(self): def zoom_orig_all(self): for term in self.terminals: term.zoom_orig() + + def new_random_group(self): + defaultmembers=[_('Alpha'),_('Beta'),_('Gamma'),_('Delta'),_('Epsilon'),_('Zeta'),_('Eta'), + _('Theta'),_('Iota'),_('Kappa'),_('Lambda'),_('Mu'),_('Nu'),_('Xi'), + _('Omicron'),_('Pi'),_('Rho'),_('Sigma'),_('Tau'),_('Upsilon'),_('Phi'), + _('Chi'),_('Psi'),_('Omega')] + currentgroups=set(self.groups) + for i in range(1,4): + defaultgroups=set(map(''.join, list(itertools.product(defaultmembers,repeat=i)))) + freegroups = list(defaultgroups-currentgroups) + if freegroups: + return random.choice(freegroups) + return '' + # vim: set expandtab ts=4 sw=4: diff --git a/terminatorlib/titlebar.py b/terminatorlib/titlebar.py index e651f00cf..ee9dfb2c5 100644 --- a/terminatorlib/titlebar.py +++ b/terminatorlib/titlebar.py @@ -5,8 +5,6 @@ from gi.repository import Gtk, Gdk from gi.repository import GObject from gi.repository import Pango -import random -import itertools from .version import APP_NAME from .util import dbg @@ -255,19 +253,7 @@ def create_group(self): if self.terminal.group: self.groupentry.set_text(self.terminal.group) else: - defaultmembers=[_('Alpha'),_('Beta'),_('Gamma'),_('Delta'),_('Epsilon'),_('Zeta'),_('Eta'), - _('Theta'),_('Iota'),_('Kappa'),_('Lambda'),_('Mu'),_('Nu'),_('Xi'), - _('Omicron'),_('Pi'),_('Rho'),_('Sigma'),_('Tau'),_('Upsilon'),_('Phi'), - _('Chi'),_('Psi'),_('Omega')] - currentgroups=set(self.terminator.groups) - for i in range(1,4): - defaultgroups=set(map(''.join, list(itertools.product(defaultmembers,repeat=i)))) - freegroups = list(defaultgroups-currentgroups) - if freegroups: - self.groupentry.set_text(random.choice(freegroups)) - break - else: - self.groupentry.set_text('') + self.groupentry.set_text(self.terminator.new_random_group()) self.groupentry.show() self.grouplabel.hide() self.groupentry.grab_focus() From 808d2efaa964633b151ca69d50e71f562f1c41cf Mon Sep 17 00:00:00 2001 From: zpalmtree <22151537+zpalmtree@users.noreply.github.com> Date: Wed, 28 Dec 2022 23:20:28 -0500 Subject: [PATCH 042/101] Add detachable tabs feature to preferences --- terminatorlib/config.py | 3 +- terminatorlib/notebook.py | 4 +- terminatorlib/preferences.glade | 124 +++++++++++++++++++------------- terminatorlib/prefseditor.py | 8 +++ 4 files changed, 85 insertions(+), 54 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 80c29cbd0..5280e3667 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -118,7 +118,8 @@ 'case_sensitive' : True, 'invert_search' : False, 'link_single_click' : False, - 'title_at_bottom' : False + 'title_at_bottom' : False, + 'detachable_tabs' : True, }, 'keybindings': { 'zoom_in' : 'plus', diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index f43b88f45..1a069b41e 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -191,7 +191,7 @@ def split_axis(self, widget, vertical=True, cwd=None, sibling=None, widgetfirst= sibling.force_set_profile(None, widget.get_profile()) self.insert_page(container, None, page_num) - self.set_tab_detachable(container, True) + self.set_tab_detachable(container, self.config['detachable_tabs']) self.child_set_property(container, 'tab-expand', True) self.child_set_property(container, 'tab-fill', True) self.set_tab_reorderable(container, True) @@ -320,7 +320,7 @@ def newtab(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=N dbg('inserting page at position: %s' % tabpos) self.insert_page(widget, None, tabpos) - self.set_tab_detachable(widget, True) + self.set_tab_detachable(widget, self.config['detachable_tabs']) if maker.isinstance(widget, 'Terminal'): containers, objects = ([], [widget]) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 57dc3620e..93137e5c6 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -1,5 +1,5 @@ - + @@ -413,7 +413,7 @@ 36 True - + True False @@ -553,6 +553,23 @@ 2 + + + Detach tab into new window on drag (Require restart) + False + True + True + False + 0.5 + True + + + + 0 + 7 + 2 + + True @@ -3721,12 +3738,12 @@ - + False + True True - False - filter keybindings + filter keybindings False @@ -3734,68 +3751,73 @@ 0 - - - True - True - adjustment4 - never - in - + True True - True - KeybindingsListStore - False - 0 - - - + adjustment4 + never + in - - Name + + True + True + True + KeybindingsListStore + False + 0 + + + - - - 0 - + + Name + + + + 0 + + + - - - - - Action - - - 1 - + + Action + + + + 1 + + + - - - - - Keybinding - - True - other - - + + Keybinding + + + True + other + + + + + 2 + 3 + + - - 2 - 3 - + + True + True + 1 + - - 3 diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index a333069f3..2b1c009d3 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -770,6 +770,10 @@ def on_palette_click(event, data, widget=widget): else: widget.set_font_name(self.config['title_font']) + # Whether tabs can be detached into their own window by dragging from titlebar + widget = guiget('detachable_tabs') + widget.set_active(self.config['detachable_tabs']) + def set_layout(self, layout_name): """Set a layout""" self.layouteditor.set_layout(layout_name) @@ -1873,6 +1877,10 @@ def on_open_manual(self, widget): """Open the fine manual""" self.term.key_help() + def on_detachable_tabs_toggled(self, widget): + self.config['detachable_tabs'] = widget.get_active() + self.config.save() + class LayoutEditor: profile_ids_to_profile = None profile_profile_to_ids = None From 3854a7c0e2fb61fda7d683021735fe83cd3dce4d Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Fri, 3 Feb 2023 14:34:16 +0100 Subject: [PATCH 043/101] Allow setting hardcoded background darkening Normally, one can only change the background of the foreground for the inactive window. With this change the background of the inactive window will also change it's brightness by 20%. --- terminatorlib/terminal.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 9f633a66c..936bbc3ee 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -112,6 +112,7 @@ class Terminal(Gtk.VBox): fgcolor_active = None fgcolor_inactive = None bgcolor = None + bgcolor_inactive = None palette_active = None palette_inactive = None @@ -754,6 +755,13 @@ def reconfigure(self, _widget=None): dbg(("fgcolor_inactive set to: RGB(%s,%s,%s)", getattr(self.fgcolor_inactive, "red"), getattr(self.fgcolor_inactive, "green"), getattr(self.fgcolor_inactive, "blue"))) + + bg_factor = 0.8 + self.bgcolor_inactive = self.bgcolor.copy() + for bit in ['red', 'green', 'blue']: + setattr(self.bgcolor_inactive, bit, + getattr(self.bgcolor_inactive, bit) * bg_factor) + colors = self.config['palette'].split(':') self.palette_active = [] for color in colors: @@ -789,7 +797,7 @@ def reconfigure(self, _widget=None): self.vte.set_colors(self.fgcolor_active, self.bgcolor, self.palette_active) else: - self.vte.set_colors(self.fgcolor_inactive, self.bgcolor, + self.vte.set_colors(self.fgcolor_inactive, self.bgcolor_inactive, self.palette_inactive) profiles = self.config.base.profiles terminal_box_style_context = self.terminalbox.get_style_context() @@ -1314,7 +1322,7 @@ def on_vte_focus_in(self, _widget, _event): def on_vte_focus_out(self, _widget, _event): """Inform other parts of the application when focus is lost""" - self.vte.set_colors(self.fgcolor_inactive, self.bgcolor, + self.vte.set_colors(self.fgcolor_inactive, self.bgcolor_inactive, self.palette_inactive) self.set_cursor_color() self.emit('focus-out') From 6551dba9dc6ee859b24c842081ef5fbd4586356a Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Fri, 3 Feb 2023 14:59:36 +0100 Subject: [PATCH 044/101] Add config option for inactive background offset --- terminatorlib/config.py | 1 + terminatorlib/prefseditor.py | 15 +++++++++++++++ terminatorlib/terminal.py | 4 +++- 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 80c29cbd0..a4c310e75 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -103,6 +103,7 @@ 'custom_url_handler' : '', 'disable_real_transparency' : False, 'inactive_color_offset': 0.8, + 'inactive_bg_color_offset': 0.8, 'enabled_plugins' : ['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler'], diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index a333069f3..1bc7b664e 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -674,6 +674,10 @@ def on_palette_click(event, data, widget=widget): widget.set_value(float(self.config['inactive_color_offset'])) widget = guiget('inactive_color_offset_value_label') widget.set_text('%d%%' % (int(float(self.config['inactive_color_offset'])*100))) + widget = guiget('inactive_bg_color_offset') + widget.set_value(float(self.config['inactive_bg_color_offset'])) + widget = guiget('inactive_bg_color_offset_value_label') + widget.set_text('%d%%' % (int(float(self.config['inactive_bg_color_offset'])*100))) # Open links with a single click (instead of a Ctrl-left click) widget = guiget('link_single_click') widget.set_active(self.config['link_single_click']) @@ -1294,6 +1298,17 @@ def on_inactive_color_offset_value_changed(self, widget): label_widget = guiget('inactive_color_offset_value_label') label_widget.set_text('%d%%' % (int(value * 100))) + def on_inactive_bg_color_offset_value_changed(self, widget): + """Inactive background color offset setting changed""" + value = widget.get_value() # This one is rounded according to the UI. + if value > 1.0: + value = 1.0 + self.config['inactive_bg_color_offset'] = value + self.config.save() + guiget = self.builder.get_object + label_widget = guiget('inactive_bg_color_offset_value_label') + label_widget.set_text('%d%%' % (int(value * 100))) + def on_handlesize_value_changed(self, widget): """Handle size changed""" value = widget.get_value() # This one is rounded according to the UI. diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 936bbc3ee..332464105 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -756,7 +756,9 @@ def reconfigure(self, _widget=None): getattr(self.fgcolor_inactive, "green"), getattr(self.fgcolor_inactive, "blue"))) - bg_factor = 0.8 + bg_factor = self.config['inactive_bg_color_offset'] + if bg_factor > 1.0: + bg_factor = 1.0 self.bgcolor_inactive = self.bgcolor.copy() for bit in ['red', 'green', 'blue']: setattr(self.bgcolor_inactive, bit, From 272328c82d597f44c907c0fcf497b85b7e845cee Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Fri, 3 Feb 2023 15:50:33 +0100 Subject: [PATCH 045/101] Add inactive background color adjustment in prefs --- terminatorlib/preferences.glade | 171 +++++++++++++++++++++----------- 1 file changed, 113 insertions(+), 58 deletions(-) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 57dc3620e..f1a61b7cf 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -340,6 +340,11 @@ 0.10 0.20 + + 1 + 0.10 + 0.20 + 1 2 @@ -887,7 +892,7 @@ 36 True - + True False @@ -906,7 +911,7 @@ 0 - 3 + 4 3 @@ -960,7 +965,7 @@ True baseline True - adjustment7 + adjustment8 2 2 False @@ -1030,7 +1035,7 @@ 0 - 5 + 6 @@ -1046,7 +1051,7 @@ 1 - 5 + 6 @@ -1064,7 +1069,7 @@ 2 - 5 + 6 @@ -1081,7 +1086,7 @@ 2 - 4 + 5 @@ -1097,7 +1102,7 @@ 1 - 4 + 5 @@ -1109,7 +1114,52 @@ 0 - 4 + 5 + + + + + True + False + Unfocused terminal background color + 0 + + + 0 + 3 + + + + + True + False + 100% + right + 5 + 5 + 1 + + + 1 + 3 + + + + + 100 + True + True + True + adjustment7 + 2 + 2 + False + bottom + + + + 2 + 3 @@ -3721,12 +3771,12 @@ - + False + True True - False - filter keybindings + filter keybindings False @@ -3734,68 +3784,73 @@ 0 - - - True - True - adjustment4 - never - in - + True True - True - KeybindingsListStore - False - 0 - - - + adjustment4 + never + in - - Name + + True + True + True + KeybindingsListStore + False + 0 + + + - - - 0 - + + Name + + + + 0 + + + - - - - - Action - - - 1 - + + Action + + + + 1 + + + - - - - - Keybinding - - True - other - - + + Keybinding + + + True + other + + + + + 2 + 3 + + - - 2 - 3 - + + True + True + 1 + - - 3 From dd511778c823ea942380a37bd913766157ea6c07 Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Fri, 3 Feb 2023 15:56:46 +0100 Subject: [PATCH 046/101] Add debug messages for the inactive background color change --- terminatorlib/terminal.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 332464105..3c338ab88 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -760,9 +760,16 @@ def reconfigure(self, _widget=None): if bg_factor > 1.0: bg_factor = 1.0 self.bgcolor_inactive = self.bgcolor.copy() + dbg(("bgcolor_inactive set to: RGB(%s,%s,%s)", getattr(self.bgcolor_inactive, "red"), + getattr(self.bgcolor_inactive, "green"), + getattr(self.bgcolor_inactive, "blue"))) + for bit in ['red', 'green', 'blue']: setattr(self.bgcolor_inactive, bit, getattr(self.bgcolor_inactive, bit) * bg_factor) + dbg(("bgcolor_inactive set to: RGB(%s,%s,%s)", getattr(self.bgcolor_inactive, "red"), + getattr(self.bgcolor_inactive, "green"), + getattr(self.bgcolor_inactive, "blue"))) colors = self.config['palette'].split(':') self.palette_active = [] From 39cf34e295f107bd22d81da67f463220d938ad25 Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Fri, 3 Feb 2023 18:26:54 +0100 Subject: [PATCH 047/101] Fix typo --- terminatorlib/preferences.glade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index f1a61b7cf..c0e291476 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -1121,7 +1121,7 @@ True False - Unfocused terminal background color + Unfocused terminal background color: 0 From 21529cec6c3de7a6d2fe2a58ef1d72f79c8d304d Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Tue, 1 Nov 2022 10:30:38 +0100 Subject: [PATCH 048/101] Add different background image modes stretch_and_fill, scale_and_fit, scale_and_crop, tiling --- terminatorlib/config.py | 1 + terminatorlib/terminal.py | 20 +++++++++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 80c29cbd0..cdf96846f 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -216,6 +216,7 @@ 'background_darkness' : 0.5, 'background_type' : 'solid', 'background_image' : '', + 'background_image_mode' : 'stretch_and_fill', 'backspace_binding' : 'ascii-del', 'delete_binding' : 'escape-sequence', 'color_scheme' : 'grey_on_black', diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 9f633a66c..a5b2efdaf 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1135,17 +1135,35 @@ def background_draw(self, widget, cr): # save cairo context cr.save() + # draw background image + image_mode = self.config['background_image_mode'] + rect = self.vte.get_allocation() xratio = float(rect.width) / float(self.background_image.get_width()) yratio = float(rect.height) / float(self.background_image.get_height()) - cr.scale(xratio, yratio) + if image_mode == 'stretch_and_fill': + cr.scale(xratio, yratio) + elif image_mode == 'scale_and_fit': + ratio = min(xratio, yratio) + cr.scale(ratio, ratio) + elif image_mode == 'scale_and_crop': + ratio = max(xratio, yratio) + cr.scale(ratio, ratio) + + # TODO add image alignment + cr.set_source_surface(self.background_image) cr.get_source().set_filter(cairo.Filter.FAST) + if image_mode == 'tiling': + cr.get_source().set_extend(cairo.Extend.REPEAT) + cr.paint() + # draw transparent monochrome layer Gdk.cairo_set_source_rgba(cr, self.bgcolor) cr.paint() + # restore cairo context cr.restore() From df8890199cf3f26952816506fb3da7f30b2f7f75 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Tue, 1 Nov 2022 23:27:17 +0100 Subject: [PATCH 049/101] Add background image alignment background_image_align_horiz: left, center, right background_image_align_vert: top, middle, bottom --- terminatorlib/config.py | 2 ++ terminatorlib/terminal.py | 31 ++++++++++++++++++++++++------- 2 files changed, 26 insertions(+), 7 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index cdf96846f..ae156329a 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -217,6 +217,8 @@ 'background_type' : 'solid', 'background_image' : '', 'background_image_mode' : 'stretch_and_fill', + 'background_image_align_horiz': 'center', + 'background_image_align_vert' : 'middle', 'backspace_binding' : 'ascii-del', 'delete_binding' : 'escape-sequence', 'color_scheme' : 'grey_on_black', diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index a5b2efdaf..964b5c405 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1138,22 +1138,39 @@ def background_draw(self, widget, cr): # draw background image image_mode = self.config['background_image_mode'] + image_align_horiz = self.config['background_image_align_horiz'] + image_align_vert = self.config['background_image_align_vert'] rect = self.vte.get_allocation() xratio = float(rect.width) / float(self.background_image.get_width()) yratio = float(rect.height) / float(self.background_image.get_height()) if image_mode == 'stretch_and_fill': - cr.scale(xratio, yratio) + # keep stretched ratios + xratio = xratio + yratio = yratio elif image_mode == 'scale_and_fit': ratio = min(xratio, yratio) - cr.scale(ratio, ratio) + xratio = yratio = ratio elif image_mode == 'scale_and_crop': ratio = max(xratio, yratio) - cr.scale(ratio, ratio) - - # TODO add image alignment - - cr.set_source_surface(self.background_image) + xratio = yratio = ratio + else: + xratio = yratio = 1 + cr.scale(xratio, yratio) + + xoffset = 0 + yoffset = 0 + if image_align_horiz == 'center': + xoffset = (rect.width / xratio - self.background_image.get_width()) / 2 + elif image_align_horiz == 'right': + xoffset = rect.width / xratio - self.background_image.get_width() + + if image_align_vert == 'middle': + yoffset = (rect.height / yratio - self.background_image.get_height()) / 2 + elif image_align_vert == 'bottom': + yoffset = rect.height / yratio - self.background_image.get_height() + + cr.set_source_surface(self.background_image, xoffset, yoffset) cr.get_source().set_filter(cairo.Filter.FAST) if image_mode == 'tiling': cr.get_source().set_extend(cairo.Extend.REPEAT) From 6cc3052ba70f3552ad966b5e3c0dbaf8c363bb94 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Tue, 14 Feb 2023 16:59:59 +0100 Subject: [PATCH 050/101] Add background image's drawing mode and alignment to preferences GUI --- terminatorlib/preferences.glade | 376 +++++++++++++++++++++++++------- terminatorlib/prefseditor.py | 80 ++++++- 2 files changed, 375 insertions(+), 81 deletions(-) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 57dc3620e..b8ca1749d 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -1,5 +1,5 @@ - + @@ -154,6 +154,60 @@ + + + + + + + + Left + + + Center + + + Right + + + + + + + + + + + Top + + + Middle + + + Bottom + + + + + + + + + + + Stretch and Fill + + + Scale and Fit + + + Scale and Crop + + + Tiling + + + @@ -2660,41 +2714,208 @@ - + True False + 12 - - True - False - Background Image File: - - - False - True - 5 - 0 - - - - + True False - Choose file - + vertical + + + True + False + + + True + False + Image File: + + + False + True + 5 + 0 + + + + + True + False + Choose file + + + + False + True + end + 1 + + + + + False + True + 0 + + + + + True + False + + + True + False + Drawing mode: + + + False + True + 5 + 0 + + + + + True + False + ImageDrawingModeListStore + 0 + + + + + 0 + + + + + False + True + end + 1 + + + + + False + True + 1 + + + + + True + False + 12 + True + + + True + False + + + True + False + Horizontal alignment: + + + False + True + 5 + 0 + + + + + True + False + ImageAlignHorizListStore + 1 + + + + + 0 + + + + + False + True + end + 1 + + + + + False + True + 0 + + + + + True + False + + + True + False + Vertical alignment: + + + False + True + 5 + 0 + + + + + True + False + ImageAlignVertListStore + 1 + + + + + 0 + + + + + False + True + end + 1 + + + + + False + True + 1 + + + + + False + True + 2 + + - - False - True - end - 1 - False True - 4 + 3 @@ -2783,7 +3004,7 @@ False True - 4 + 6 @@ -3721,12 +3942,12 @@ - + False + True True - False - filter keybindings + filter keybindings False @@ -3734,68 +3955,73 @@ 0 - - - True - True - adjustment4 - never - in - + True True - True - KeybindingsListStore - False - 0 - - - + adjustment4 + never + in - - Name + + True + True + True + KeybindingsListStore + False + 0 + + + - - - 0 - + + Name + + + + 0 + + + - - - - - Action - - - 1 - + + Action + + + + 1 + + + - - - - - Keybinding - - True - other - - + + Keybinding + + + True + other + + + + + 2 + 3 + + - - 2 - 3 - + + True + True + 1 + - - 3 diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index a333069f3..2fc668d3f 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -694,11 +694,42 @@ def on_palette_click(event, data, widget=widget): elif self.config['background_type'] == 'image': guiget('image_radiobutton').set_active(True) self.update_background_tab() + # Background image + widget = guiget('background_image_file') + widget.set_filename(self.config['background_image']) + + widget = guiget('background_image_mode_combobox') + if self.config['background_image_mode'] == 'scale_and_fit': + widget.set_active(1) + elif self.config['background_image_mode'] == 'scale_and_crop': + widget.set_active(2) + elif self.config['background_image_mode'] == 'tiling': + widget.set_active(3) + else: + # default to stretch_and_fill + widget.set_active(0) + + widget = guiget('background_image_align_horiz_combobox') + if self.config['background_image_align_horiz'] == 'center': + widget.set_active(1) + elif self.config['background_image_align_horiz'] == 'right': + widget.set_active(2) + else: + # default to left + widget.set_active(0) + + widget = guiget('background_image_align_vert_combobox') + if self.config['background_image_align_vert'] == 'middle': + widget.set_active(1) + elif self.config['background_image_align_vert'] == 'bottom': + widget.set_active(2) + else: + # default to top + widget.set_active(0) + # Background shading widget = guiget('background_darkness_scale') widget.set_value(float(self.config['background_darkness'])) - widget = guiget('background_image_file') - widget.set_filename(self.config['background_image']) ## Scrolling tab # Scrollbar position @@ -999,6 +1030,41 @@ def on_background_image_file_set(self,widget): self.config['background_image'] = widget.get_filename() self.config.save() + def on_background_image_mode_changed(self, widget): + selected = widget.get_active() + if selected == 1: + value = 'scale_and_fit' + elif selected == 2: + value = 'scale_and_crop' + elif selected == 3: + value = 'tiling' + else: + value = 'stretch_and_fill' + self.config['background_image_mode'] = value + self.config.save() + + def on_background_image_align_horiz_changed(self, widget): + selected = widget.get_active() + if selected == 1: + value = 'center' + elif selected == 2: + value = 'right' + else: + value = 'left' + self.config['background_image_align_horiz'] = value + self.config.save() + + def on_background_image_align_vert_changed(self, widget): + selected = widget.get_active() + if selected == 1: + value = 'middle' + elif selected == 2: + value = 'bottom' + else: + value = 'top' + self.config['background_image_align_vert'] = value + self.config.save() + def on_darken_background_scale_value_changed(self, widget): """Background darkness setting changed""" value = widget.get_value() # This one is rounded according to the UI. @@ -1603,10 +1669,12 @@ def update_background_tab(self): self.config['background_type'] = backtype self.config.save() - if backtype == 'image': - guiget('background_image_file').set_sensitive(True) - else: - guiget('background_image_file').set_sensitive(False) + # toggle sensitivity of widgets related to background image + for element in ('background_image_file', + 'background_image_align_horiz_combobox', + 'background_image_align_vert_combobox', + 'background_image_mode_combobox'): + guiget(element).set_sensitive(backtype == 'image') if backtype in ('transparent', 'image'): guiget('darken_background_scale').set_sensitive(True) From d52fa5a5d425257297a171cb0ae84a755831a8f7 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Wed, 15 Feb 2023 11:44:42 +0100 Subject: [PATCH 051/101] Detachable tabs: reposition the code --- terminatorlib/prefseditor.py | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 2b1c009d3..8217a1e73 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -337,6 +337,9 @@ def set_values(self): # DBus Server widget = guiget('dbuscheck') widget.set_active(self.config['dbus']) + # Detachable tabs + widget = guiget('detachable_tabs') + widget.set_active(self.config['detachable_tabs']) #Hide from taskbar widget = guiget('hidefromtaskbcheck') widget.set_active(self.config['hide_from_taskbar']) @@ -770,10 +773,6 @@ def on_palette_click(event, data, widget=widget): else: widget.set_font_name(self.config['title_font']) - # Whether tabs can be detached into their own window by dragging from titlebar - widget = guiget('detachable_tabs') - widget.set_active(self.config['detachable_tabs']) - def set_layout(self, layout_name): """Set a layout""" self.layouteditor.set_layout(layout_name) @@ -805,6 +804,10 @@ def on_dbuscheck_toggled(self, widget): self.config['dbus'] = widget.get_active() self.config.save() + def on_detachable_tabs_toggled(self, widget): + self.config['detachable_tabs'] = widget.get_active() + self.config.save() + def on_disable_mousewheel_zoom_toggled(self, widget): """Ctrl+mousewheel zoom setting changed""" self.config['disable_mousewheel_zoom'] = widget.get_active() @@ -1877,10 +1880,6 @@ def on_open_manual(self, widget): """Open the fine manual""" self.term.key_help() - def on_detachable_tabs_toggled(self, widget): - self.config['detachable_tabs'] = widget.get_active() - self.config.save() - class LayoutEditor: profile_ids_to_profile = None profile_profile_to_ids = None From c1d9253acc8e29897947037269b17fe7c52080e0 Mon Sep 17 00:00:00 2001 From: Kacper Kowalski Date: Tue, 21 Feb 2023 11:04:37 +0100 Subject: [PATCH 052/101] Make inactive background brightness default 1.0 (100%) --- terminatorlib/config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index a4c310e75..90f4a3ad4 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -103,7 +103,7 @@ 'custom_url_handler' : '', 'disable_real_transparency' : False, 'inactive_color_offset': 0.8, - 'inactive_bg_color_offset': 0.8, + 'inactive_bg_color_offset': 1.0, 'enabled_plugins' : ['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler'], From 066acd779ae14b3914617855159a1c8305eb6e1a Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Tue, 28 Feb 2023 21:42:29 -0500 Subject: [PATCH 053/101] Remove hack to ensure that focus is set. set_focus() should do the trick according to the docs, so let's just use that, and not go to extraordinary measures. --- terminatorlib/terminator.py | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 0a3f361be..509a01568 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -346,22 +346,11 @@ def layout_done(self): t = 0 window.get_window().focus(t) - # Awful workaround to be sure that the last focused window is actually the one focused. - # Don't ask, don't tell policy on this. Even this is not 100% + # Going by the docs, this should be all that's needed to ensure that the + # last_active_window is focussed. if self.last_active_window: window = self.find_window_by_uuid(self.last_active_window.urn) - count = 0 - while count < 1000 and Gtk.events_pending(): - count += 1 - Gtk.main_iteration_do(False) - window.show() - window.grab_focus() - try: - t = GdkX11.x11_get_server_time(window.get_window()) - except (NameError,TypeError, AttributeError): - t = 0 - window.get_window().focus(t) - + window.set_focus() self.prelayout_windows = None def on_gtk_theme_name_notify(self, settings, prop): From ed763df3310ff64b073efc1bf59494da72d44eae Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Tue, 28 Feb 2023 22:22:57 -0500 Subject: [PATCH 054/101] Further fix to last_active_window --- terminatorlib/terminator.py | 1 + 1 file changed, 1 insertion(+) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 509a01568..184bf12ff 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -350,6 +350,7 @@ def layout_done(self): # last_active_window is focussed. if self.last_active_window: window = self.find_window_by_uuid(self.last_active_window.urn) + window.present_with_time(0) window.set_focus() self.prelayout_windows = None From d6d9cce90cc01c4b1b75ff97f248cb3baab62f47 Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Tue, 28 Feb 2023 22:32:14 -0500 Subject: [PATCH 055/101] should not commit this late at night. --- terminatorlib/terminator.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 184bf12ff..0fb65660b 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -309,6 +309,7 @@ def layout_done(self): """Layout operations have finished, record that fact""" self.doing_layout = False maker = Factory() + t = 0 window_last_active_term_mapping = {} for window in self.windows: @@ -350,7 +351,7 @@ def layout_done(self): # last_active_window is focussed. if self.last_active_window: window = self.find_window_by_uuid(self.last_active_window.urn) - window.present_with_time(0) + window.present_with_time(t) window.set_focus() self.prelayout_windows = None From 9eaf0cbd6b9a28601a64127e2047f10dbf49dfa7 Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Wed, 1 Mar 2023 17:36:20 -0500 Subject: [PATCH 056/101] Release version 2.1.3 --- AUTHORS | 54 +++++++++++++--------- CHANGELOG.md | 79 ++++++++++++++++++++++++++++++--- terminatorlib/preferences.glade | 2 +- terminatorlib/version.py | 2 +- 4 files changed, 107 insertions(+), 30 deletions(-) diff --git a/AUTHORS b/AUTHORS index 5049df0b1..952300ad1 100644 --- a/AUTHORS +++ b/AUTHORS @@ -5,9 +5,8 @@ This list is generated from the GIT log. * Aaron Faanes * Adrian A * Alexey Sokolov -* amaan khan -* Andrea Corbellini * Andre Hilsendeger +* Andrea Corbellini * Andrew Felske * Antonio Terceiro * Antonio Terceiro @@ -17,11 +16,9 @@ This list is generated from the GIT log. * Brian Murray * Bruno Braga * Bryce Harrington -* caprinux <123jinkai@gmail.com> * Chacal * Chris James * Chris Jones -* coder * Cory Kontros * Daniel Napora * Daniel T Chen @@ -29,7 +26,6 @@ This list is generated from the GIT log. * David Levanon * David Sowder * Dennis Benzinger | SAP Hybris -* dkmvs <67212386+dkmvs@users.noreply.github.com> * Dmitry Soldatov * Douglas Bacon * Edoardo Batini @@ -37,7 +33,6 @@ This list is generated from the GIT log. * Emilien Klein * Emilio Pozuelo Monfort * Emmanuel Bretelle -* evandrocoan * Felix Mölder <56774350+Brambleberry4@users.noreply.github.com> * Fernando Basso * Filip Kilibarda @@ -54,63 +49,78 @@ This list is generated from the GIT log. * Jean-Sebastien Trottier * Joe Peled * Jonas L -* José Augusto * Jose Augusto * Jose I. Monreal -* judgedreads +* José Augusto * Juliano Fischer Naves * Julien Nicoulaud * Julien Thewys +* Kacper Kowalski * Kees Cook -* kocho1984 +* Kian-Meng Ang * Leandro Thimóteo * Lucian Adrian Grijincu * Mackenzie Morgan * Mark Timarev * Markus Frosch * Markus Korn -* Matthew Rose * Matt Rose -* milotype <43657314+milotype@users.noreply.github.com> +* Matthew Rose +* Mihai Babiac * MuhammadJivani * Nathan Handler * Nathaniel M. Beaver * Nathaniel Morck Beaver * Neal Fultz * Nicolas Valcárcel -* nojhan -* ozzdemir * Pavel Khlebovich +* Paweł Kotiuk <45544416+pktiuk@users.noreply.github.com> * Paweł Kotiuk * Peter B. Jørgensen * Peter Bjørn Jørgensen * Peter Lind * Phi -* planet36 * Przemek Wesolek +* R the Troublemaker <5971066+br0kenbuild@users.noreply.github.com> * Rafael Kitover * Roberto Aguilar -* robertoetcheverryr -* R the Troublemaker <5971066+br0kenbuild@users.noreply.github.com> * Ryan Fonnesbeck -* shiraeeshi * Siegfried-Angel Gevatter Pujals * Simeon Simeonov * Stephen Boddy * StephenPeringer -* thebigs * Thomas Hurst * Thomas Meire -* Tomek Sabała +* Tobias Farrenkopf * Tom Yan +* Tomek Sabała * Tony Baker +* Vishweshwar Saran Singh Deo * Vojtech Duchon (Ext) * Vulcalien * Vulcalien -* waldner -* xuezhixin * Yousof * Yusuf Güngör +* amaan khan +* caprinux <123jinkai@gmail.com> +* coder +* dkmvs <67212386+dkmvs@users.noreply.github.com> +* evandrocoan +* flaviosteimacher <39162591+flaviosteimacher@users.noreply.github.com> +* judgedreads +* kocho1984 +* milotype <43657314+milotype@users.noreply.github.com> +* nicbn +* nojhan +* ozzdemir +* planet36 +* robertoetcheverryr +* sabriunal +* shiraeeshi +* thebigs +* transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> +* waldner +* xuezhixin ## Other contributors @@ -132,5 +142,7 @@ People that contributed to Terminator in other ways. * Maxim Derkach * Mats Henrikson * Nizar Kerkeni +* "Data" * Cristian Grada +* "zhuqin" * and many others. diff --git a/CHANGELOG.md b/CHANGELOG.md index 801befe23..e17cd5e9f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,70 @@ # Changelog +## [v2.1.3](https://github.com/gnome-terminator/terminator/tree/v2.1.3) (2023-03-01) + +[Full Changelog](https://github.com/gnome-terminator/terminator/compare/v2.1.2...v2.1.3) + +**Implemented enhancements:** + +- Option to set split ratio of terminals [\#708](https://github.com/gnome-terminator/terminator/issues/708) +- Add option to set given terminal to "read only" [\#649](https://github.com/gnome-terminator/terminator/issues/649) +- background image - respect ratio [\#644](https://github.com/gnome-terminator/terminator/issues/644) +- Shortcut for autosplit h/v depending on active terminal size [\#613](https://github.com/gnome-terminator/terminator/issues/613) +- Feature: Insert terminal name to terminal \(for broadcast\) [\#540](https://github.com/gnome-terminator/terminator/issues/540) +- Background image drawing modes and alignment [\#713](https://github.com/gnome-terminator/terminator/pull/713) ([Vulcalien](https://github.com/Vulcalien)) +- Zoom on notebook even if there is only one terminal in the tab + keep tab position and label in notebook rotation [\#589](https://github.com/gnome-terminator/terminator/pull/589) ([Vulcalien](https://github.com/Vulcalien)) + +**Fixed bugs:** + +- Resets the tab title on rotation [\#624](https://github.com/gnome-terminator/terminator/issues/624) +- - bug context menu \(right click\)-\>layouts-\>"Layout Name" always selec… [\#653](https://github.com/gnome-terminator/terminator/pull/653) ([vssdeo](https://github.com/vssdeo)) +- Fix missing icons when started with Ctrl-Alt-T [\#628](https://github.com/gnome-terminator/terminator/pull/628) ([MihaiBabiac](https://github.com/MihaiBabiac)) + +**Closed issues:** + +- Terminator not working with latest version of python-cairo [\#711](https://github.com/gnome-terminator/terminator/issues/711) +- \[Bug\]\[Fedora 36 KDE\]\[terminator v2.1.1\] "broadcast group" sends each terminal input/keystroke depending on the group's members count to everyone in the group [\#704](https://github.com/gnome-terminator/terminator/issues/704) +- reset\_clear doesn't show new prompt [\#703](https://github.com/gnome-terminator/terminator/issues/703) +- `-x`/`--execute` still broken [\#702](https://github.com/gnome-terminator/terminator/issues/702) +- Make unfocused terminal text transparent instead of blacker [\#694](https://github.com/gnome-terminator/terminator/issues/694) +- A translucent separation occurs between terminals [\#687](https://github.com/gnome-terminator/terminator/issues/687) +- \[2.1.2\] Foreground processes started in new window close immediately [\#673](https://github.com/gnome-terminator/terminator/issues/673) +- Is there a official page to maintain a offical/third-part plugin list? [\#668](https://github.com/gnome-terminator/terminator/issues/668) +- What happened to the change terminal titlebar under preferences? [\#664](https://github.com/gnome-terminator/terminator/issues/664) +- \[Feature Request\] - In the Context Menu\(Right-Click\) show keyboard shortcuts / accelarators [\#662](https://github.com/gnome-terminator/terminator/issues/662) +- terminator: error: unrecognized arguments [\#660](https://github.com/gnome-terminator/terminator/issues/660) +- Plugin Submission : SaveLastSessionLayout Uses Layout to Auto-Save Last session and CWD on Terminal Window Close [\#654](https://github.com/gnome-terminator/terminator/issues/654) +- Loading layout loads only the last added layout from context menu \(right click\) [\#652](https://github.com/gnome-terminator/terminator/issues/652) +- When can we expect a new release? [\#650](https://github.com/gnome-terminator/terminator/issues/650) +- Profiles for different Shells - is it possible? how does it work? [\#640](https://github.com/gnome-terminator/terminator/issues/640) +- Double input to broadcasted group [\#623](https://github.com/gnome-terminator/terminator/issues/623) +- background images only displaying on default profile [\#595](https://github.com/gnome-terminator/terminator/issues/595) +- The repository 'https://ppa.launchpadcontent.net/mattrose/terminator/ubuntu jammy Release' does not have a Release file. [\#594](https://github.com/gnome-terminator/terminator/issues/594) +- Increase the usage of augmented assignment statements [\#555](https://github.com/gnome-terminator/terminator/issues/555) + +**Merged pull requests:** + +- Better distinguishing of inactive windows from the active one, by changing the background brightness [\#709](https://github.com/gnome-terminator/terminator/pull/709) ([KKoovalsky](https://github.com/KKoovalsky)) +- Ctrl+Click on group button automatically creates groups whenever needed [\#691](https://github.com/gnome-terminator/terminator/pull/691) ([nicbn](https://github.com/nicbn)) +- \[bug 680\] Open up keybindings page on keypress \#680 [\#686](https://github.com/gnome-terminator/terminator/pull/686) ([vssdeo](https://github.com/vssdeo)) +- Translate '/po/terminator.pot' in 'pt\_BR' [\#684](https://github.com/gnome-terminator/terminator/pull/684) ([transifex-integration[bot]](https://github.com/apps/transifex-integration)) +- Plugin and Group menu item that inserts the name of the terminal. [\#683](https://github.com/gnome-terminator/terminator/pull/683) ([mattrose](https://github.com/mattrose)) +- Add Readonly toggle to popup menu [\#679](https://github.com/gnome-terminator/terminator/pull/679) ([mattrose](https://github.com/mattrose)) +- Fix argument handling of the --execute flag [\#678](https://github.com/gnome-terminator/terminator/pull/678) ([shawn-ogg](https://github.com/shawn-ogg)) +- Remove all ibus workarounds [\#674](https://github.com/gnome-terminator/terminator/pull/674) ([mattrose](https://github.com/mattrose)) +- \[bug 613\] - Shortcut for autosplit h/v depending on active terminal … [\#671](https://github.com/gnome-terminator/terminator/pull/671) ([vssdeo](https://github.com/vssdeo)) +- \[bug 662\] \[Feature Request\] - In the Context Menu\(Right-Click\) show k… [\#666](https://github.com/gnome-terminator/terminator/pull/666) ([vssdeo](https://github.com/vssdeo)) +- \[bug 559\] Add menu autocomplete \#559 [\#665](https://github.com/gnome-terminator/terminator/pull/665) ([vssdeo](https://github.com/vssdeo)) +- \[bug 662\] \[Feature Request\] - In the Context Menu\(Right-Click\) show k… [\#663](https://github.com/gnome-terminator/terminator/pull/663) ([vssdeo](https://github.com/vssdeo)) +- \[bug 654\] - Plugin Submission : SaveLastSessionLayout Uses Layout to … [\#661](https://github.com/gnome-terminator/terminator/pull/661) ([vssdeo](https://github.com/vssdeo)) +- Update terminal.py [\#659](https://github.com/gnome-terminator/terminator/pull/659) ([flaviosteimacher](https://github.com/flaviosteimacher)) +- docs: Change number of columns in repology badge [\#657](https://github.com/gnome-terminator/terminator/pull/657) ([pktiuk](https://github.com/pktiuk)) +- Plugin Submission : SaveLastSessionLayout Uses Layout to Auto-Save Last session and CWD [\#655](https://github.com/gnome-terminator/terminator/pull/655) ([vssdeo](https://github.com/vssdeo)) +- Fix typos [\#651](https://github.com/gnome-terminator/terminator/pull/651) ([kianmeng](https://github.com/kianmeng)) +- data: Remove GNOME branding [\#647](https://github.com/gnome-terminator/terminator/pull/647) ([sabriunal](https://github.com/sabriunal)) +- this line has an extra ';' symbol [\#632](https://github.com/gnome-terminator/terminator/pull/632) ([xuezhixin](https://github.com/xuezhixin)) +- Use the term 'zero padded' instead of 'padded'. [\#189](https://github.com/gnome-terminator/terminator/pull/189) ([phidebian](https://github.com/phidebian)) + ## [v2.1.2](https://github.com/gnome-terminator/terminator/tree/v2.1.2) (2022-10-19) [Full Changelog](https://github.com/gnome-terminator/terminator/compare/v2.1.1...v2.1.2) @@ -67,7 +132,7 @@ - Fix Keyboard Input [\#533](https://github.com/gnome-terminator/terminator/issues/533) - group broadcasting switched on/off for all groups [\#532](https://github.com/gnome-terminator/terminator/issues/532) - Drop a file from nautilus onto terminator window no longer works \(it used to paste the path a la gnome terminal\) [\#530](https://github.com/gnome-terminator/terminator/issues/530) -- Crash every time after encoding is changed to TCVN [\#529](https://github.com/gnome-terminator/terminator/issues/529) +- Crash everytime after encoding is changed to TCVN [\#529](https://github.com/gnome-terminator/terminator/issues/529) - Change the color of the current tab to highlight it better [\#522](https://github.com/gnome-terminator/terminator/issues/522) - Feature: Configuration to colorize split screens from default grey colour, Issue: Remove ability to select 0 and 1 handle\_size from configuration gui [\#518](https://github.com/gnome-terminator/terminator/issues/518) - Error when using "Insert Terminal Number" \(Solved?\) [\#517](https://github.com/gnome-terminator/terminator/issues/517) @@ -79,7 +144,7 @@ - terminator failing to open on ubuntu 21.04 [\#502](https://github.com/gnome-terminator/terminator/issues/502) - Monospace Bold isn't working [\#497](https://github.com/gnome-terminator/terminator/issues/497) - No prompt when closing terminator now, despite say vim running in terminal [\#496](https://github.com/gnome-terminator/terminator/issues/496) -- support for sixel graphics [\#492](https://github.com/gnome-terminator/terminator/issues/492) +- suppor for sixel graphics [\#492](https://github.com/gnome-terminator/terminator/issues/492) - which is deprecated and should not be used [\#488](https://github.com/gnome-terminator/terminator/issues/488) - could tmux Key bindings using in terminator? [\#474](https://github.com/gnome-terminator/terminator/issues/474) - Support OpenType font features [\#473](https://github.com/gnome-terminator/terminator/issues/473) @@ -148,7 +213,7 @@ - add parameters to remotinator split commands [\#472](https://github.com/gnome-terminator/terminator/pull/472) ([mattrose](https://github.com/mattrose)) - add switch\_profile\_all command to remotinator [\#471](https://github.com/gnome-terminator/terminator/pull/471) ([mattrose](https://github.com/mattrose)) - Set CAN\_FOCUS to False for notebook widgets [\#470](https://github.com/gnome-terminator/terminator/pull/470) ([marktimarev](https://github.com/marktimarev)) -- tell titlebar to start focused out if it does not have focus [\#462](https://github.com/gnome-terminator/terminator/pull/462) ([mattrose](https://github.com/mattrose)) +- tell titlebar to start focussed out if it does not have focus [\#462](https://github.com/gnome-terminator/terminator/pull/462) ([mattrose](https://github.com/mattrose)) - Update translation [\#460](https://github.com/gnome-terminator/terminator/pull/460) ([pktiuk](https://github.com/pktiuk)) - Add new plugin for opening current directory using right mouse button [\#459](https://github.com/gnome-terminator/terminator/pull/459) ([pktiuk](https://github.com/pktiuk)) - Fixed Issue \#425 \(hide\_window will try to show a destroyed window\) [\#456](https://github.com/gnome-terminator/terminator/pull/456) ([Vulcalien](https://github.com/Vulcalien)) @@ -199,7 +264,7 @@ - Background image not showing up on Xubuntu 20.04 [\#364](https://github.com/gnome-terminator/terminator/issues/364) - Pasted text is highlighted [\#363](https://github.com/gnome-terminator/terminator/issues/363) - \[FR\] Option to elide terminal title from the left [\#362](https://github.com/gnome-terminator/terminator/issues/362) -- Windows title are not updated after ssh session disconnected [\#359](https://github.com/gnome-terminator/terminator/issues/359) +- Windows title are not udpated after ssh session disconnected [\#359](https://github.com/gnome-terminator/terminator/issues/359) - No broadcast menu in sway [\#357](https://github.com/gnome-terminator/terminator/issues/357) - Remove spaces between tabs [\#331](https://github.com/gnome-terminator/terminator/issues/331) - Enhancement: Stjerm Layout Like Functionality [\#298](https://github.com/gnome-terminator/terminator/issues/298) @@ -244,7 +309,7 @@ - The Alt+L layout chooser is too small [\#345](https://github.com/gnome-terminator/terminator/issues/345) - Open in Previous Location [\#337](https://github.com/gnome-terminator/terminator/issues/337) - How to install terminator without root privilege? [\#332](https://github.com/gnome-terminator/terminator/issues/332) -- Improve separator between split terminals [\#329](https://github.com/gnome-terminator/terminator/issues/329) +- Improve separator between splitted terminals [\#329](https://github.com/gnome-terminator/terminator/issues/329) - Using shift+Super+} for next\_tab key binding doesn't work [\#326](https://github.com/gnome-terminator/terminator/issues/326) - "Copy email address" actually doesn't quite do that [\#323](https://github.com/gnome-terminator/terminator/issues/323) - Can`t disable key binding [\#322](https://github.com/gnome-terminator/terminator/issues/322) @@ -354,7 +419,7 @@ With pull request #70, we removed the need for gettext binaries and switched to **Closed issues:** -- Feature Suggestion: Split screen shells based on parent [\#230](https://github.com/gnome-terminator/terminator/issues/230) +- Feature Suggestion: Splitted screen shells based on parent [\#230](https://github.com/gnome-terminator/terminator/issues/230) - Release 2.0 does not have signed assets [\#228](https://github.com/gnome-terminator/terminator/issues/228) - Some files install to the wrong location [\#227](https://github.com/gnome-terminator/terminator/issues/227) - Multi tab breaks transparent background [\#225](https://github.com/gnome-terminator/terminator/issues/225) @@ -423,7 +488,7 @@ With pull request #70, we removed the need for gettext binaries and switched to - Selecting first char of a line for copy-paste is impossible [\#191](https://github.com/gnome-terminator/terminator/issues/191) - Duplicate Key Bindings are Allowed in `Preferences > Keybindings` [\#190](https://github.com/gnome-terminator/terminator/issues/190) - Cannot open terminator windows with different configs [\#184](https://github.com/gnome-terminator/terminator/issues/184) -- Feature request: re-enable broadcast keybindings and warn on their first use instead [\#183](https://github.com/gnome-terminator/terminator/issues/183) +- Feature request: reenable broadcast keybindings and warn on their first use instead [\#183](https://github.com/gnome-terminator/terminator/issues/183) - Add Terminator version in About screen [\#169](https://github.com/gnome-terminator/terminator/issues/169) - Feature Request: Add hyperlink support [\#164](https://github.com/gnome-terminator/terminator/issues/164) - ctrl-alt-a activates even when terminal has no focus [\#163](https://github.com/gnome-terminator/terminator/issues/163) diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 8f9a33e23..04a8adce1 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -4248,7 +4248,7 @@ True False - Version: 2.1.2 + Version: 2.1.3 False diff --git a/terminatorlib/version.py b/terminatorlib/version.py index c26d916a5..e0aa5fcb5 100644 --- a/terminatorlib/version.py +++ b/terminatorlib/version.py @@ -20,4 +20,4 @@ """ APP_NAME = 'terminator' -APP_VERSION = '2.1.2' +APP_VERSION = '2.1.3' From 599b9b8bf4bf5480e2d63285b7a246bb9a590591 Mon Sep 17 00:00:00 2001 From: PF Date: Mon, 6 Mar 2023 22:25:27 -0400 Subject: [PATCH 057/101] Capitalize the first letter for "Read only" --- terminatorlib/terminal_popup_menu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 34e6a3fe9..5f80d50c7 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -262,7 +262,7 @@ def show(self, widget, event=None): menu.append(item) menu.append(Gtk.SeparatorMenuItem()) - item = self.menu_item(Gtk.CheckMenuItem, 'toggle_readonly', '_read only') + item = self.menu_item(Gtk.CheckMenuItem, 'toggle_readonly', '_Read only') item.set_active(not(terminal.vte.get_input_enabled())) item.connect('toggled', lambda x: terminal.do_readonly_toggle()) menu.append(item) From bb1ddf3ee5d37b328feb589691807d7c8995e23c Mon Sep 17 00:00:00 2001 From: magical-heyrovsky <101060148+magical-heyrovsky@users.noreply.github.com> Date: Tue, 7 Mar 2023 10:16:49 +0100 Subject: [PATCH 058/101] Fix typo in man page --- doc/terminator.1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/terminator.1 b/doc/terminator.1 index 5d27afaa9..1d716d9b8 100644 --- a/doc/terminator.1 +++ b/doc/terminator.1 @@ -13,7 +13,7 @@ arrangements of GNOME terminals. It is aimed at those who normally arrange lots of terminals near each other, but don't want to use a frame based window manager. .SH "OPTIONS" -This program follow the usual GNU command line syntax, with long +This program follows the usual GNU command line syntax, with long options starting with two dashes (`\-'). A summary of options is included below. .TP From e4be854668d9554ab5ffdba1d0c75a35388b265c Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Wed, 8 Mar 2023 17:17:57 -0500 Subject: [PATCH 059/101] Fix context menu keybinding reading. When the keybinding for an action that also appears in the context menu is None, python can't do it's usual string tricks and throws a backtrace, and doesn't display the menu. --- terminatorlib/terminal_popup_menu.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py index 34e6a3fe9..581a9ae11 100644 --- a/terminatorlib/terminal_popup_menu.py +++ b/terminatorlib/terminal_popup_menu.py @@ -30,6 +30,8 @@ def __init__(self, terminal): def get_menu_item_mask(self, maskstr): mask = 0 + if maskstr is None: + return mask maskstr = maskstr.lower() if maskstr.find(''.lower()) >= 0: mask = mask | Gdk.ModifierType.SHIFT_MASK From d8852f1e5447c1dfe53b049bbb1f058ec988e819 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 11 Mar 2023 12:48:20 +0100 Subject: [PATCH 060/101] Do not remove focus from the last_active_window This caused all the new windows to be unfocused, forcing the user to manually focus one. The 'last_active_window' feature might be broken anyway. --- terminatorlib/terminator.py | 1 - 1 file changed, 1 deletion(-) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index bf0a45352..db3f465f9 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -355,7 +355,6 @@ def layout_done(self): if self.last_active_window: window = self.find_window_by_uuid(self.last_active_window.urn) window.present_with_time(t) - window.set_focus() self.prelayout_windows = None def on_gtk_theme_name_notify(self, settings, prop): From 41c9d344b4a598c7788828976573f3f9dd7c417b Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Wed, 22 Mar 2023 17:43:04 -0400 Subject: [PATCH 061/101] fix drag and drop --- terminatorlib/terminal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 5add381ba..914d69d7b 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -1694,7 +1694,7 @@ def paste_clipboard(self, primary=False, mouse=False): def feed(self, text): """Feed the supplied text to VTE""" - self.vte.feed_child(text.encode()) + self.vte.feed_child(text) def zoom_in(self): """Increase the font size""" From cac4c9e45806fe67d97c6bd95ee46d4dc280b8ee Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Wed, 29 Mar 2023 23:59:38 +0200 Subject: [PATCH 062/101] Rewrite terminator.1 man page in AsciiDoc format --- doc/terminator.adoc | 310 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 310 insertions(+) create mode 100644 doc/terminator.adoc diff --git a/doc/terminator.adoc b/doc/terminator.adoc new file mode 100644 index 000000000..8f9dbf27e --- /dev/null +++ b/doc/terminator.adoc @@ -0,0 +1,310 @@ += Terminator(1) +:doctype: manpage +:manmanual: Manual for Terminator +:mansource: Terminator +:revdate: 2023-03-29 +:docdate: {revdate} + +== NAME +terminator - Multiple GNOME terminals in one window + +== SYNOPSIS +*terminator* [_options_] + +== DESCRIPTION +This manual page documents *Terminator*, a terminal emulator application. + +*Terminator* is a program that allows users to set up flexible +arrangements of GNOME terminals. It is aimed at those who normally +arrange lots of terminals near each other, but don't want to use a +frame based window manager. + +== OPTIONS +This program follows the usual GNU command line syntax, with long +options starting with two dashes (`-'). +A summary of options is included below. + +*-h*, *--help*:: +Show summary of options. + +*-v*, *--version*:: +Show the version of the Terminator installation. + +*-m*, *-M*, *--maximise*, *--maximize*:: +Start with a maximised window. + +*-f*, *--fullscreen*:: +Start with a fullscreen window. + +*-b*, *--borderless*:: +Instruct the window manager not to render borders/decoration on the +Terminator window (this works well with --maximise). + +*-H*, *--hidden*:: +Hide the Terminator window by default. Its visibility can be toggled +with the *hide_window* keyboard shortcut (Ctrl+Shift+Alt+A by default). + +*-T* _FORCEDTITLE_, **--title**=__FORCEDTITLE__:: +Force the Terminator window to use a specific name rather than updating +it dynamically based on the wishes of the child shell. + +**--geometry**=__GEOMETRY__:: +Specify the preferred size and position of Terminator's window; +see *X*(7). + +*-e* _COMMAND_, **--command**=__COMMAND__:: +Run the specified command instead of the default shell or profile +specified command. + +Note: if Terminator is launched as x-terminal-emulator -e behaves like +-x, and the longform becomes --execute2=COMMAND. + +*-x* _COMMAND_ [__ARGS__], **--execute**=__COMMAND__ [__ARGS__]:: +Run *the rest of the command line* instead of the default shell or +profile specified command. + +**--working-directory**=__DIR__:: +Set the terminal's working directory. + +*-g* _FILE_, **--config**=__FILE__:: +Use the specified file for configuration. + +// TODO --config-json option + +*-r* _ROLE_, **--role**=__ROLE__:: +Set a custom WM_WINDOW_ROLE property on the window. + +*-l* _LAYOUT_, **--layout**=__LAYOUT__:: +Start Terminator with a specific layout. The argument here is the name +of a saved layout. + +*-s* _LAYOUT_, **--select-layout**=__LAYOUT__:: +Open the layout launcher window instead of the normal terminal. + +*-p*, **--profile**=__PROFILE__:: +Use a different profile as the default. + +*-i*, **--icon**=__FORCEDICON__:: +Set a custom icon for the window (by file or name) + +*-u*, *--no-dbus*:: +Disable DBus. +// Could 'Start Terminator with DBus disabled.' be better? + +*-d*, *--debug*:: +Enable debugging output (please use this when reporting bugs). This can +be specified twice to enable a built-in python debugging server. + +**--debug-classes**=__DEBUG_CLASSES__:: +If this is specified as a comma separated list, debugging output will +only be printed from the specified classes. + +**--debug-methods**=__DEBUG_METHODS__:: +If this is specified as a comma separated list, debugging output will +only be printed from the specified functions. If this is specified in +addition to --debug-classes, only the intersection of the two lists will +be displayed. + +*--new-tab*:: +If this is specified and Terminator is already running, DBus will be +used to spawn a new tab in the first Terminator window. + +== KEYBINDINGS +The following default keybindings can be used to control Terminator. +Most of these keybindings can be changed in the Preferences. + +*F1*:: +Launches the full HTML manual. + +=== Creation & Destruction +The following items relate to creating and destroying terminals. + +*Ctrl+Shift+O*:: +Split terminals H__o__rizontally. + +*Ctrl+Shift+E*:: +Split terminals V__e__rtically. + +*Ctrl+Shift+T*:: +Open new __t__ab. + +*Ctrl+Shift+I*:: +Open a new window. + +(Note: unlike in previous releases, this window is part of the same +Terminator process.) + +*Super+I*:: +Spawn a new Terminator process. + +*Alt+L*:: +Open __l__ayout launcher. + +*Ctrl+Shift+W*:: +Close the current terminal. + +*Ctrl+Shift+Q*:: +Close the current window. + +=== Navigation +The following items relate to moving between and around terminals. + +*Alt+Up*:: +Move to the terminal *above* the current one. + +*Alt+Down*:: +Move to the terminal *below* the current one. + +*Alt+Left*:: +Move to the terminal *left of* the current one. + +*Alt+Right*:: +Move to the terminal *right of* the current one. + +*Ctrl+PageDown*:: +Move to next Tab. + +*Ctrl+PageUp*:: +Move to previous Tab. + +*Ctrl+Shift+N* or *Ctrl+Tab*:: +Move to the __n__ext terminal within the same tab. + +If *cycle_term_tab* is *False*, cycle within the same tab will be +disabled. + +*Ctrl+Shift+P* or *Ctrl+Shift+Tab*:: +Move to the __p__revious terminal within the same tab. + +If *cycle_term_tab* is *False*, cycle within the same tab will be +disabled. + +=== Organisation +The following items relate to arranging and resizing terminals. + +*Ctrl+Shift+Right*:: +Move parent dragbar *Right*. + +*Ctrl+Shift+Left*:: +Move parent dragbar *Left*. + +*Ctrl+Shift+Up*:: +Move parent dragbar *Up*. + +*Ctrl+Shift+Down*:: +Move parent dragbar *Down*. + +*Super+R*:: +__R__otate terminals clockwise. + +*Super+Shift+R*:: +__R__otate terminals counter-clockwise. + +*Ctrl+Shift+PageDown*:: +Swap tab position with next Tab. + +*Ctrl+Shift+PageUp*:: +Swap tab position with previous Tab. + +*Drag and Drop*:: +The layout can be modified by moving terminals with Drag and Drop. +To start dragging a terminal, click and hold on its titlebar. +Alternatively, hold down *Ctrl*, click and hold the *right* mouse button. +Then, *+**Release Ctrl**+*. You can now drag the terminal to the point +in the layout you would like it to be. The zone where the terminal would +be inserted will be highlighted. + +=== Focus +The following items relate to helping to focus on a specific terminal. + +*F11*:: +Toggle window to fullscreen. + +*Ctrl+Shift+X*:: +Toggle between showing all terminals and only showing the current one +(maximise). + +*Ctrl+Shift+Z*:: +Toggle between showing all terminals and only showing a scaled version +of the current one (zoom). + +*Ctrl+Shift+Alt+A*:: +Hide the initial window. Note that this is a global binding, and can +only be bound once. + +=== Grouping & Broadcasting +The following items relate to grouping and broadcasting. + +*Super+T*:: +Group all terminals in the current tab so that any input sent to one of +them goes to all of them. + +*Super+Shift+T*:: +Remove grouping from all terminals in the current tab. + +*Super+G*:: +Group all terminals so that any input sent to one of them goes to all of +them. + +*Super+Shift+G*:: +Remove grouping from all terminals. + +*Alt+A*:: +Broadcast to __a__ll terminals. + +*Alt+G*:: +Broadcast to __g__rouped terminals. + +*Alt+O*:: +Broadcast __o__ff. + +=== Miscellaneous +The following items relate to miscellaneous terminal related functions. + +*Ctrl+Shift+C*:: +Copy selected text to clipboard. + +*Ctrl+Shift+V*:: +Paste clipboard text. + +*Ctrl+Shift+S*:: +Hide/Show __S__crollbar. + +*Ctrl+Shift+F*:: +Search within terminal scrollback. + +*Ctrl+Shift+R*:: +Reset terminal state. + +*Ctrl+Shift+G*:: +Reset terminal state and clear window. + +*Ctrl+Plus (+)*:: +Increase font size. + +Note: this may require you to press shift, depending on your keyboard. + +*Ctrl+Minus (-)*:: +Decrease font size. + +Note: this may require you to press shift, depending on your keyboard. + +*Ctrl+Zero (0)*:: +Restore font size to original setting. + +*Ctrl+Alt+W*:: +Rename window title. + +*Ctrl+Alt+A*:: +Rename tab title. + +*Ctrl+Alt+X*:: +Rename terminal title. + +*Super+1*:: +Insert terminal number, i.e. 1 to 12. + +*Super+0*:: +Insert padded terminal number, i.e. 01 to 12. + +== SEE ALSO +*terminator_config*(5) + +== AUTHOR +Terminator was written by Chris Jones <\cmsj@tenshu.net> and others. + +This manual page was written by Chris Jones <\cmsj@tenshu.net> and others. From dd075a243dac17addbe735f0ca5a6a33e831d671 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 31 Mar 2023 01:04:51 +0200 Subject: [PATCH 063/101] Minor improvements to terminator.adoc 1. Decapitalize some words 2. Replace 'Hide/Show' with 'Toggle' 3. Replace 'AUTHOR' with 'AUTHORS' 4. Move the 'SEE ALSO' section to the bottom --- doc/terminator.adoc | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/doc/terminator.adoc b/doc/terminator.adoc index 8f9dbf27e..806c36491 100644 --- a/doc/terminator.adoc +++ b/doc/terminator.adoc @@ -2,11 +2,11 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-03-29 +:revdate: 2023-03-30 :docdate: {revdate} == NAME -terminator - Multiple GNOME terminals in one window +terminator - multiple GNOME terminals in one window == SYNOPSIS *terminator* [_options_] @@ -160,10 +160,10 @@ Move to the terminal *left of* the current one. Move to the terminal *right of* the current one. *Ctrl+PageDown*:: -Move to next Tab. +Move to next tab. *Ctrl+PageUp*:: -Move to previous Tab. +Move to previous tab. *Ctrl+Shift+N* or *Ctrl+Tab*:: Move to the __n__ext terminal within the same tab. + @@ -179,16 +179,16 @@ disabled. The following items relate to arranging and resizing terminals. *Ctrl+Shift+Right*:: -Move parent dragbar *Right*. +Move parent dragbar *right*. *Ctrl+Shift+Left*:: -Move parent dragbar *Left*. +Move parent dragbar *left*. *Ctrl+Shift+Up*:: -Move parent dragbar *Up*. +Move parent dragbar *up*. *Ctrl+Shift+Down*:: -Move parent dragbar *Down*. +Move parent dragbar *down*. *Super+R*:: __R__otate terminals clockwise. @@ -197,16 +197,16 @@ __R__otate terminals clockwise. __R__otate terminals counter-clockwise. *Ctrl+Shift+PageDown*:: -Swap tab position with next Tab. +Swap tab position with next tab. *Ctrl+Shift+PageUp*:: -Swap tab position with previous Tab. +Swap tab position with previous tab. *Drag and Drop*:: The layout can be modified by moving terminals with Drag and Drop. To start dragging a terminal, click and hold on its titlebar. Alternatively, hold down *Ctrl*, click and hold the *right* mouse button. -Then, *+**Release Ctrl**+*. You can now drag the terminal to the point +Then, *+**release Ctrl**+*. You can now drag the terminal to the point in the layout you would like it to be. The zone where the terminal would be inserted will be highlighted. @@ -264,7 +264,7 @@ Copy selected text to clipboard. Paste clipboard text. *Ctrl+Shift+S*:: -Hide/Show __S__crollbar. +Toggle __s__crollbar. *Ctrl+Shift+F*:: Search within terminal scrollback. @@ -301,10 +301,10 @@ Insert terminal number, i.e. 1 to 12. *Super+0*:: Insert padded terminal number, i.e. 01 to 12. -== SEE ALSO -*terminator_config*(5) - -== AUTHOR +== AUTHORS Terminator was written by Chris Jones <\cmsj@tenshu.net> and others. This manual page was written by Chris Jones <\cmsj@tenshu.net> and others. + +== SEE ALSO +*terminator_config*(5) From 1ce3d500695183e92ab230a159c74bbd1eda9781 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 31 Mar 2023 01:17:22 +0200 Subject: [PATCH 064/101] Generate terminator.1 from terminator.adoc using asciidoctor --- doc/terminator.1 | 675 ++++++++++++++++++++++++++++++----------------- 1 file changed, 435 insertions(+), 240 deletions(-) diff --git a/doc/terminator.1 b/doc/terminator.1 index 1d716d9b8..4d3591fe5 100644 --- a/doc/terminator.1 +++ b/doc/terminator.1 @@ -1,286 +1,481 @@ -.TH "TERMINATOR" "1" "Jan 5, 2008" "" "" +'\" t +.\" Title: terminator +.\" Author: [see the "AUTHOR(S)" section] +.\" Generator: Asciidoctor 2.0.18 +.\" Date: 2023-03-30 +.\" Manual: Manual for Terminator +.\" Source: Terminator +.\" Language: English +.\" +.TH "TERMINATOR" "1" "2023-03-30" "Terminator" "Manual for Terminator" +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.ss \n[.ss] 0 +.nh +.ad l +.de URL +\fI\\$2\fP <\\$1>\\$3 +.. +.als MTO URL +.if \n[.g] \{\ +. mso www.tmac +. am URL +. ad l +. . +. am MTO +. ad l +. . +. LINKSTYLE blue R < > +.\} .SH "NAME" -Terminator \- Multiple GNOME terminals in one window +terminator \- multiple GNOME terminals in one window .SH "SYNOPSIS" -.B terminator -.RI [ options ] -.br +.sp +\fBterminator\fP [\fIoptions\fP] .SH "DESCRIPTION" +.sp This manual page documents \fBTerminator\fP, a terminal emulator application. -.PP +.sp \fBTerminator\fP is a program that allows users to set up flexible arrangements of GNOME terminals. It is aimed at those who normally -arrange lots of terminals near each other, but don't want to use a +arrange lots of terminals near each other, but don\(cqt want to use a frame based window manager. .SH "OPTIONS" +.sp This program follows the usual GNU command line syntax, with long -options starting with two dashes (`\-'). +options starting with two dashes (`\-\*(Aq). A summary of options is included below. -.TP -.B \-h, \-\-help -Show summary of options -.TP -.B \-v, \-\-version -Show the version of the Terminator installation -.TP -.B \-m, \-\-maximise -Start with a maximised window -.B \-M, \-\-maximize -Start with a maximized window -.TP -.B \-f, \-\-fullscreen -Start with a fullscreen window -.TP -.B \-b, \-\-borderless +.sp +\fB\-h\fP, \fB\-\-help\fP +.RS 4 +Show summary of options. +.RE +.sp +\fB\-v\fP, \fB\-\-version\fP +.RS 4 +Show the version of the Terminator installation. +.RE +.sp +\fB\-m\fP, \fB\-M\fP, \fB\-\-maximise\fP, \fB\-\-maximize\fP +.RS 4 +Start with a maximised window. +.RE +.sp +\fB\-f\fP, \fB\-\-fullscreen\fP +.RS 4 +Start with a fullscreen window. +.RE +.sp +\fB\-b\fP, \fB\-\-borderless\fP +.RS 4 Instruct the window manager not to render borders/decoration on the -Terminator window (this works well with \-m) -.TP -.B \-H, \-\-hidden +Terminator window (this works well with \-\-maximise). +.RE +.sp +\fB\-H\fP, \fB\-\-hidden\fP +.RS 4 Hide the Terminator window by default. Its visibility can be toggled -with the \fBhide_window\fR keyboard shortcut (Ctrl-Shift-Alt-a by default) -.TP -.B \-T, \-\-title -Force the Terminator window to use a specific name rather than updating it dynamically -based on the wishes of the child shell. -.TP -.B \-\-geometry=GEOMETRY -Specifies the preferred size and position of Terminator's window; see X(7). -.TP -.B \-e, \-\-command=COMMAND -Runs the specified command instead of your default shell or profile specified command. Note: if -Terminator is launched as x-terminal-emulator \-e behaves like \-x, and the longform becomes -\-\-execute2=COMMAND -.TP -.B \-x, \-\-execute COMMAND [ARGS] -Runs \fBthe rest of the command line\fR instead of your default shell or profile specified command. -.TP -.B \-\-working\-directory=DIR -Set the terminal's working directory -.TP -.B \-g, \-\-config FILE -Use the specified FILE for configuration -.TP -.B \-r, \-\-role=ROLE -Set a custom WM_WINDOW_ROLE property on the window -.TP -.B \-l, \-\-layout=LAYOUT +with the \fBhide_window\fP keyboard shortcut (Ctrl+Shift+Alt+A by default). +.RE +.sp +\fB\-T\fP \fIFORCEDTITLE\fP, \fB\-\-title\fP=\fIFORCEDTITLE\fP +.RS 4 +Force the Terminator window to use a specific name rather than updating +it dynamically based on the wishes of the child shell. +.RE +.sp +\fB\-\-geometry\fP=\fIGEOMETRY\fP +.RS 4 +Specify the preferred size and position of Terminator\(cqs window; +see \fBX\fP(7). +.RE +.sp +\fB\-e\fP \fICOMMAND\fP, \fB\-\-command\fP=\fICOMMAND\fP +.RS 4 +Run the specified command instead of the default shell or profile +specified command. +.br +Note: if Terminator is launched as x\-terminal\-emulator \-e behaves like +\-x, and the longform becomes \-\-execute2=COMMAND. +.RE +.sp +\fB\-x\fP \fICOMMAND\fP [\fIARGS\fP], \fB\-\-execute\fP=\fICOMMAND\fP [\fIARGS\fP] +.RS 4 +Run \fBthe rest of the command line\fP instead of the default shell or +profile specified command. +.RE +.sp +\fB\-\-working\-directory\fP=\fIDIR\fP +.RS 4 +Set the terminal\(cqs working directory. +.RE +.sp +\fB\-g\fP \fIFILE\fP, \fB\-\-config\fP=\fIFILE\fP +.RS 4 +Use the specified file for configuration. +.RE +.sp +\fB\-r\fP \fIROLE\fP, \fB\-\-role\fP=\fIROLE\fP +.RS 4 +Set a custom WM_WINDOW_ROLE property on the window. +.RE +.sp +\fB\-l\fP \fILAYOUT\fP, \fB\-\-layout\fP=\fILAYOUT\fP +.RS 4 Start Terminator with a specific layout. The argument here is the name of a saved layout. -.TP -.B \-s, \-\-select-layout=LAYOUT +.RE +.sp +\fB\-s\fP \fILAYOUT\fP, \fB\-\-select\-layout\fP=\fILAYOUT\fP +.RS 4 Open the layout launcher window instead of the normal terminal. -.TP -.B \-p, \-\-profile=PROFILE -Use a different profile as the default -.TP -.B \-i, \-\-icon=FORCEDICON +.RE +.sp +\fB\-p\fP, \fB\-\-profile\fP=\fIPROFILE\fP +.RS 4 +Use a different profile as the default. +.RE +.sp +\fB\-i\fP, \fB\-\-icon\fP=\fIFORCEDICON\fP +.RS 4 Set a custom icon for the window (by file or name) -.TP -.B \-u, \-\-no-dbus -Disable DBus -.TP -.B \-d, \-\-debug -Enable debugging output (please use this when reporting bugs). This -can be specified twice to enable a built-in python debugging server. -.TP -.B \-\-debug\-classes=DEBUG_CLASSES +.RE +.sp +\fB\-u\fP, \fB\-\-no\-dbus\fP +.RS 4 +Disable DBus. +.RE +.sp +\fB\-d\fP, \fB\-\-debug\fP +.RS 4 +Enable debugging output (please use this when reporting bugs). This can +be specified twice to enable a built\-in python debugging server. +.RE +.sp +\fB\-\-debug\-classes\fP=\fIDEBUG_CLASSES\fP +.RS 4 If this is specified as a comma separated list, debugging output will only be printed from the specified classes. -.TP -.B \-\-debug\-methods=DEBUG_METHODS +.RE +.sp +\fB\-\-debug\-methods\fP=\fIDEBUG_METHODS\fP +.RS 4 If this is specified as a comma separated list, debugging output will only be printed from the specified functions. If this is specified in -addition to \-\-debug-classes, only the intersection of the two lists -will be displayed -.TP -.B \-\-new-tab +addition to \-\-debug\-classes, only the intersection of the two lists will +be displayed. +.RE +.sp +\fB\-\-new\-tab\fP +.RS 4 If this is specified and Terminator is already running, DBus will be used to spawn a new tab in the first Terminator window. +.RE .SH "KEYBINDINGS" -The following default keybindings can be used to control Terminator: -.TP -.B F1 +.sp +The following default keybindings can be used to control Terminator. +Most of these keybindings can be changed in the Preferences. +.sp +\fBF1\fP +.RS 4 Launches the full HTML manual. -.SS Creation & Destruction -.PP +.RE +.SS "Creation & Destruction" +.sp The following items relate to creating and destroying terminals. -.TP -.B Ctrl+Shift+O -Split terminals H\fBo\fRrizontally. -.TP -.B Ctrl+Shift+E -Split terminals V\fBe\fRrtically. -.TP -.B Ctrl+Shift+T -Open new \fBt\fRab. -.TP -.B Ctrl+Shift+I -Open a new window. (Note: Unlike in previous releases, this window is -part of the same Terminator process.) -.TP -.B Super+I +.sp +\fBCtrl+Shift+O\fP +.RS 4 +Split terminals H\fIo\fPrizontally. +.RE +.sp +\fBCtrl+Shift+E\fP +.RS 4 +Split terminals V\fIe\fPrtically. +.RE +.sp +\fBCtrl+Shift+T\fP +.RS 4 +Open new \fIt\fPab. +.RE +.sp +\fBCtrl+Shift+I\fP +.RS 4 +Open a new window. +.br +(Note: unlike in previous releases, this window is part of the same +Terminator process.) +.RE +.sp +\fBSuper+I\fP +.RS 4 Spawn a new Terminator process. -.TP -.B Alt+L -Open \fBl\fRayout launcher. -.TP -.B Ctrl+Shift+W +.RE +.sp +\fBAlt+L\fP +.RS 4 +Open \fIl\fPayout launcher. +.RE +.sp +\fBCtrl+Shift+W\fP +.RS 4 Close the current terminal. -.TP -.B Ctrl+Shift+Q +.RE +.sp +\fBCtrl+Shift+Q\fP +.RS 4 Close the current window. -.SS Navigation -.PP +.RE +.SS "Navigation" +.sp The following items relate to moving between and around terminals. -.TP -.B Alt+Up -Move to the terminal \fBabove\fR the current one. -.TP -.B Alt+Down -Move to the terminal \fBbelow\fR the current one. -.TP -.B Alt+Left -Move to the terminal \fBleft of\fR the current one. -.TP -.B Alt+Right -Move to the terminal \fBright of\fR the current one. -.TP -.B Ctrl+PageDown -Move to next Tab. -.TP -.B Ctrl+PageUp -Move to previous Tab. -.TP -.B Ctrl+Shift+N or Ctrl+Tab -Move to \fBn\fRext terminal within the same tab, use Ctrl+PageDown to move to the next tab. -If \fBcycle_term_tab\fR is \fBFalse\fR, cycle within the same tab will be disabled. -.TP -.B Ctrl+Shift+P or Ctrl+Shift+Tab -Move to \fBp\fRrevious terminal within the same tab, use Ctrl+PageUp to move to the previous tab. -If \fBcycle_term_tab\fR is \fBFalse\fR, cycle within the same tab will be disabled. -.SS Organisation -.PP +.sp +\fBAlt+Up\fP +.RS 4 +Move to the terminal \fBabove\fP the current one. +.RE +.sp +\fBAlt+Down\fP +.RS 4 +Move to the terminal \fBbelow\fP the current one. +.RE +.sp +\fBAlt+Left\fP +.RS 4 +Move to the terminal \fBleft of\fP the current one. +.RE +.sp +\fBAlt+Right\fP +.RS 4 +Move to the terminal \fBright of\fP the current one. +.RE +.sp +\fBCtrl+PageDown\fP +.RS 4 +Move to next tab. +.RE +.sp +\fBCtrl+PageUp\fP +.RS 4 +Move to previous tab. +.RE +.sp +\fBCtrl+Shift+N\fP or \fBCtrl+Tab\fP +.RS 4 +Move to the \fIn\fPext terminal within the same tab. +.br +If \fBcycle_term_tab\fP is \fBFalse\fP, cycle within the same tab will be +disabled. +.RE +.sp +\fBCtrl+Shift+P\fP or \fBCtrl+Shift+Tab\fP +.RS 4 +Move to the \fIp\fPrevious terminal within the same tab. +.br +If \fBcycle_term_tab\fP is \fBFalse\fP, cycle within the same tab will be +disabled. +.RE +.SS "Organisation" +.sp The following items relate to arranging and resizing terminals. -.TP -.B Ctrl+Shift+Right -Move parent dragbar \fBRight\fR. -.TP -.B Ctrl+Shift+Left -Move parent dragbar \fBLeft\fR. -.TP -.B Ctrl+Shift+Up -Move parent dragbar \fBUp\fR. -.TP -.B Ctrl+Shift+Down -Move parent dragbar \fBDown\fR. -.TP -.B Super+R -\fBR\fRotate terminals clockwise. -.TP -.B Super+Shift+R -\fBR\fRotate terminals counter-clockwise. -.TP -.SH "Drag and Drop" +.sp +\fBCtrl+Shift+Right\fP +.RS 4 +Move parent dragbar \fBright\fP. +.RE +.sp +\fBCtrl+Shift+Left\fP +.RS 4 +Move parent dragbar \fBleft\fP. +.RE +.sp +\fBCtrl+Shift+Up\fP +.RS 4 +Move parent dragbar \fBup\fP. +.RE +.sp +\fBCtrl+Shift+Down\fP +.RS 4 +Move parent dragbar \fBdown\fP. +.RE +.sp +\fBSuper+R\fP +.RS 4 +\fIR\fPotate terminals clockwise. +.RE +.sp +\fBSuper+Shift+R\fP +.RS 4 +\fIR\fPotate terminals counter\-clockwise. +.RE +.sp +\fBCtrl+Shift+PageDown\fP +.RS 4 +Swap tab position with next tab. +.RE +.sp +\fBCtrl+Shift+PageUp\fP +.RS 4 +Swap tab position with previous tab. +.RE +.sp +\fBDrag and Drop\fP +.RS 4 The layout can be modified by moving terminals with Drag and Drop. To start dragging a terminal, click and hold on its titlebar. Alternatively, hold down \fBCtrl\fP, click and hold the \fBright\fP mouse button. -Then, \fB**Release Ctrl**\fP. You can now drag the terminal to the point in the layout you would like it to be. -The zone where the terminal would be inserted will be highlighted. -.TP -.B Ctrl+Shift+PageDown -Swap tab position with next Tab. -.TP -.B Ctrl+Shift+PageUp -Swap tab position with previous Tab. -.SS Miscellaneous -.PP +Then, \fB**release Ctrl**\fP. You can now drag the terminal to the point +in the layout you would like it to be. The zone where the terminal would +be inserted will be highlighted. +.RE +.SS "Focus" +.sp +The following items relate to helping to focus on a specific terminal. +.sp +\fBF11\fP +.RS 4 +Toggle window to fullscreen. +.RE +.sp +\fBCtrl+Shift+X\fP +.RS 4 +Toggle between showing all terminals and only showing the current one +(maximise). +.RE +.sp +\fBCtrl+Shift+Z\fP +.RS 4 +Toggle between showing all terminals and only showing a scaled version +of the current one (zoom). +.RE +.sp +\fBCtrl+Shift+Alt+A\fP +.RS 4 +Hide the initial window. Note that this is a global binding, and can +only be bound once. +.RE +.SS "Grouping & Broadcasting" +.sp +The following items relate to grouping and broadcasting. +.sp +\fBSuper+T\fP +.RS 4 +Group all terminals in the current tab so that any input sent to one of +them goes to all of them. +.RE +.sp +\fBSuper+Shift+T\fP +.RS 4 +Remove grouping from all terminals in the current tab. +.RE +.sp +\fBSuper+G\fP +.RS 4 +Group all terminals so that any input sent to one of them goes to all of +them. +.RE +.sp +\fBSuper+Shift+G\fP +.RS 4 +Remove grouping from all terminals. +.RE +.sp +\fBAlt+A\fP +.RS 4 +Broadcast to \fIa\fPll terminals. +.RE +.sp +\fBAlt+G\fP +.RS 4 +Broadcast to \fIg\fProuped terminals. +.RE +.sp +\fBAlt+O\fP +.RS 4 +Broadcast \fIo\fPff. +.RE +.SS "Miscellaneous" +.sp The following items relate to miscellaneous terminal related functions. -.TP -.B Ctrl+Shift+C +.sp +\fBCtrl+Shift+C\fP +.RS 4 Copy selected text to clipboard. -.TP -.B Ctrl+Shift+V +.RE +.sp +\fBCtrl+Shift+V\fP +.RS 4 Paste clipboard text. -.TP -.B Ctrl+Shift+S -Hide/Show \fBS\fRcrollbar. -.TP -.B Ctrl+Shift+F +.RE +.sp +\fBCtrl+Shift+S\fP +.RS 4 +Toggle \fIs\fPcrollbar. +.RE +.sp +\fBCtrl+Shift+F\fP +.RS 4 Search within terminal scrollback. -.TP -.B Ctrl+Shift+R +.RE +.sp +\fBCtrl+Shift+R\fP +.RS 4 Reset terminal state. -.TP -.B Ctrl+Shift+G +.RE +.sp +\fBCtrl+Shift+G\fP +.RS 4 Reset terminal state and clear window. -.TP -.B Ctrl+Plus (+) -Increase font size. \fBNote:\fP This may require you to press shift, depending on your keyboard. -.TP -.B Ctrl+Minus (-) -Decrease font size. \fBNote:\fP This may require you to press shift, depending on your keyboard. -.TP -.B Ctrl+Zero (0) +.RE +.sp +\fBCtrl+Plus (+)\fP +.RS 4 +Increase font size. +.br +Note: this may require you to press shift, depending on your keyboard. +.RE +.sp +\fBCtrl+Minus (\-)\fP +.RS 4 +Decrease font size. +.br +Note: this may require you to press shift, depending on your keyboard. +.RE +.sp +\fBCtrl+Zero (0)\fP +.RS 4 Restore font size to original setting. -.TP -.B Ctrl+Alt+W +.RE +.sp +\fBCtrl+Alt+W\fP +.RS 4 Rename window title. -.TP -.B Ctrl+Alt+A +.RE +.sp +\fBCtrl+Alt+A\fP +.RS 4 Rename tab title. -.TP -.B Ctrl+Alt+X +.RE +.sp +\fBCtrl+Alt+X\fP +.RS 4 Rename terminal title. -.TP -.B Super+1 +.RE +.sp +\fBSuper+1\fP +.RS 4 Insert terminal number, i.e. 1 to 12. -.TP -.B Super+0 +.RE +.sp +\fBSuper+0\fP +.RS 4 Insert padded terminal number, i.e. 01 to 12. -.SS Grouping & Broadcasting -.PP -The following items relate to helping to focus on a specific terminal. -.TP -.B F11 -Toggle window to fullscreen. -.TP -.B Ctrl+Shift+X -Toggle between showing all terminals and only showing the current one (maximise). -.TP -.B Ctrl+Shift+Z -Toggle between showing all terminals and only showing a scaled version of the current one (zoom). -.TP -.B Ctrl+Shift+Alt+A -Hide the initial window. Note that this is a global binding, and can only be bound once. -.PP -The following items relate to grouping and broadcasting. -.TP -.B Super+T -Group all terminals in the current tab so input sent to one of them, goes to all terminals in the current tab. -.TP -.B Super+Shift+T -Remove grouping from all terminals in the current tab. -.TP -.B Super+G -Group all terminals so that any input sent to one of them, goes to all of them. -.TP -.B Super+Shift+G -Remove grouping from all terminals. -.TP -.B Alt+A -Broadcast to All terminals. -.TP -.B Alt+G -Broadcast to Grouped terminals. -.TP -.B Alt+O -Broadcast Off. -.PP -Most of these keybindings are changeable in the Preferences. -.SH "SEE ALSO" -.BR terminator_config(5) -.SH "AUTHOR" +.RE +.SH "AUTHORS" +.sp Terminator was written by Chris Jones and others. -.PP -This manual page was written by Chris Jones -and others. +.sp +This manual page was written by Chris Jones and others. +.SH "SEE ALSO" +.sp +\fBterminator_config\fP(5) \ No newline at end of file From 8847d635f6ae16b72fe19a2bc48fbea65ace2a97 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 31 Mar 2023 16:58:52 +0200 Subject: [PATCH 065/101] Begin working on terminator_config.adoc --- doc/terminator_config.adoc | 228 +++++++++++++++++++++++++++++++++++++ 1 file changed, 228 insertions(+) create mode 100644 doc/terminator_config.adoc diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc new file mode 100644 index 000000000..70ba3fd80 --- /dev/null +++ b/doc/terminator_config.adoc @@ -0,0 +1,228 @@ += Terminator_config(5) +:doctype: manpage +:manmanual: Manual for Terminator +:mansource: Terminator +:revdate: 2023-03-31 +:docdate: {revdate} + +== NAME +// ~/.config/terminator/config - the config file for Terminator terminal emulator +config - TODO + +== DESCRIPTION +This file contains the configuration for *terminator*(1). +Terminator manages its configuration file via the ConfigObj library to +combine flexibility with clear, human editable files. + +Terminator offers a full GUI preferences editor which automatically +saves its config file so you don't need to write a config file by hand. + +== FILE LOCATION +Normally the config file will be *~/.config/terminator/config*, but it +may be overridden with *$XDG_CONFIG_HOME* (in which case it will be +*$XDG_CONFIG_HOME/terminator/config*). + +== FILE FORMAT +This is what a Terminator config file should look like: + +TODO + +== global_config +These are the options Terminator currently supports in the +*global_config* section: + +=== Window Behavior & Appearance + +// --- Window behavior --- + +*window_state* = _string_:: +Default value: *normal* + +Control how the Terminator window opens. +'normal' means it opens normally. +'maximise' means it opens in a maximised state. +'fullscreen' means it opens in a fullscreen state. +'hidden' means it stays hidden. + +*always_on_top* = _boolean_:: +Default value: *False* + +TODO + +*sticky* = _boolean_:: +Default value: *False* + +TODO + +*hide_on_lose_focus* = _boolean_:: +Default value: *False* + +TODO + +*hide_from_taskbar* = _boolean_:: +Default value: *False* + +TODO + +*geometry_hinting* = _boolean_:: +Default value: *False* + +If True the window will resize in step with font sizes, if False it will +follow pixels. + +*suppress_multiple_term_dialog* = _boolean_:: +Default value: *False* + +TODO + +// --- Window appearance --- + +*borderless* = _boolean_:: +Default value: *False* + +Control whether the Terminator window will be started without window +borders. + +=== Tab Behavior & Appearance + +*tab_position* = _string_:: +Default value: *top* + +Specify where tabs are placed. +Can be any of: 'top', 'left', 'right', 'bottom', 'hidden'. +If this is set to 'hidden', the tab bar will not be shown. Hiding the +tab is not recommended, as it can be very confusing. + +*close_button_on_tab* = _boolean_:: +Default value: : *True* + +If set to True, tabs will have a close button on them. + +// what is this??? +*scroll_tabbar* = _boolean_:: +Default value: *False* + +If set to True, the tab bar will not fill the width of the window. +The titlebars of the tabs will only take as much space as is necessary +for the text they contain. Except, that is, if the tabs no longer fit +the width of the window - in that case scroll buttons will appear to +move through the tabs. + +*homogeneous_tabbar* = _boolean_:: +Default value: *True* + +TODO + +=== Terminal Behavior & Appearance + +// --- Terminal behavior --- + +*focus* = _string_:: +Default value: *click* + +Control how focus is given to terminals. +'click' means the focus only moves to a terminal after you click in it. +'sloppy' means the focus will follow the mouse pointer. +'system' means the focus will match that used by a GNOME window manager. + +*always_split_with_profile* = _boolean_:: +Default value: *False* + +Control whether splits/tabs will continue to use the profile of their +peer terminal. If set to False, they will always use the default profile. + +*link_single_click* = _boolean_:: +Default value: *False* + +TODO + +// --- Copy & Paste behavior --- + +*putty_paste_style* = _boolean_:: +Default value: *False* + +If set to True, right-click will paste the Primary selection, +while middle-click will popup the context menu. + +*putty_paste_style_source_clipboard* = _boolean_:: +Default value: *False* + +TODO + +*disable_mouse_paste* = _boolean_:: +Default value: *False* + +TODO + +*smart_copy* = _boolean_:: +Default value: *True* + +If set to True, and there is no selection, the shortcut is allowed to +pass through. This is useful for overloading Ctrl-C to copy a selection, +or send the SIGINT to the current process if there is no selection. +If False, the shortcut does not pass through at all, and the SIGINT does +not get sent. + +*clear_select_on_copy* = _boolean_:: +Default value: *False* + +TODO + +// --- Terminal appearance --- + +*handle_size* = _integer_:: +Default value: *1* + +Control the width of the separator between terminals. +Anything outside the range 0-20 (inclusive) will be ignored and use your +default theme value. + +*inactive_color_offset* = _float_:: +Default value: *0.8* + +Specify how much to reduce the color values of fonts in terminals that +do not have focus. + +*inactive_bg_color_offset* = _float_:: +Default value: *1.0* + +Specify how much to reduce the color values of the background in +terminals that do not have focus. + +*cell_width* = _float_:: +Default value: *1.0* + +TODO + +*cell_height* = _float_:: +Default value: *1.0* + +TODO + +*title_at_bottom* = _boolean_:: +Default value: *False* + +TODO + +=== Miscellaneous + +*dbus* = _boolean_:: +Default value: *True* + +Control whether or not Terminator will load its DBus server. +When this server is loaded, running Terminator multiple times will cause +the first Terminator process to open additional windows. +If this configuration item is set to False, or the python dbus module is +unavailable, running Terminator multiple times will run a separate +Terminator process for each invocation. + +*extra_styling* = _boolean_:: +Default value: *True* + +TODO + +*broadcast_default* = _string_:: +Default value: *group* + +Specify default broadcast behavior. +Can be any of: 'all', 'group', 'off'. + +// try_posix_regexp ??? + +*use_custom_url_handler* = _boolean_:: +Default value: *False* + +If set to True, URL handling will be given over entirely to the program +specified by 'custom_url_handler'. + +*custom_url_handler* = _string_:: +Path to a program which accepts a URI as an argument and does something +relevant with it. This option is ignored unless 'use_custom_url_handler' +is set to True. + +*case_sensitive* = _boolean_:: +Default value: *True* + +TODO + +*invert_search* = _boolean_:: +Default value: *False* + +TODO + +*enabled_plugins* = _list of strings_:: +Default value: *['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler']* + +A list of plugins which should be loaded by default. All other plugin +classes will be ignored. + +== profiles +These are the options Terminator currently supports in the *profiles* +section. Each profile should be its own subsection with a header in the +format *+[[name]]+*. From 3f30aa58f76ad075cec624450eee3ce103c0c332 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 31 Mar 2023 17:14:27 +0200 Subject: [PATCH 066/101] Remove settings 'hide_tabbar' and 'disable_real_transparency' 'disable_real_transparency' is already completely unused, 'hide_tabbar' was replaced by 'tab_position' = 'hidden' and marked as deprecated in 2010. --- terminatorlib/config.py | 2 -- terminatorlib/notebook.py | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 0d2390243..fbca71afd 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -92,7 +92,6 @@ 'tab_position' : 'top', 'broadcast_default' : 'group', 'close_button_on_tab' : True, - 'hide_tabbar' : False, 'scroll_tabbar' : False, 'homogeneous_tabbar' : True, 'hide_from_taskbar' : False, @@ -101,7 +100,6 @@ 'sticky' : False, 'use_custom_url_handler': False, 'custom_url_handler' : '', - 'disable_real_transparency' : False, 'inactive_color_offset': 0.8, 'inactive_bg_color_offset': 1.0, 'enabled_plugins' : ['LaunchpadBugURLHandler', diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index f43b88f45..dc0ff555c 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -61,7 +61,7 @@ def configure(self): #self.connect('page-reordered', self.on_page_reordered) self.set_scrollable(self.config['scroll_tabbar']) - if self.config['tab_position'] == 'hidden' or self.config['hide_tabbar']: + if self.config['tab_position'] == 'hidden': self.set_show_tabs(False) else: self.set_show_tabs(True) From aadb6ebaf945ff317cb52fe1e7520a3433af9cc6 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 1 Apr 2023 19:20:18 +0200 Subject: [PATCH 067/101] terminator_config.adoc: add text for the 'FILE FORMAT' section + add a descriptions to some of the new settings --- doc/terminator_config.adoc | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index 70ba3fd80..7392980ec 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -24,7 +24,23 @@ may be overridden with *$XDG_CONFIG_HOME* (in which case it will be == FILE FORMAT This is what a Terminator config file should look like: -TODO +---- +# This is a comment +[global_config] + focus = system + +[keybindings] + full_screen = F11 + +[profiles] + [[default]] + font = Fixed 10 + background_color = "#000000" # A comment + foreground_color = "#FFFFFF" # Note that hex colour values must be quoted + scrollback_lines = '500' #More comment. Single quotes are valid too + cursor_blink = True + custom_command = "echo \"foo#bar\"" #Final comment - this will work as expected. +---- == global_config These are the options Terminator currently supports in the @@ -44,7 +60,7 @@ Control how the Terminator window opens. *always_on_top* = _boolean_:: Default value: *False* + -TODO +If set to True, the window will always stay on top of other windows. *sticky* = _boolean_:: Default value: *False* + @@ -60,12 +76,12 @@ TODO *geometry_hinting* = _boolean_:: Default value: *False* + -If True the window will resize in step with font sizes, if False it will -follow pixels. +If set to True, the window will resize in step with font sizes. *suppress_multiple_term_dialog* = _boolean_:: Default value: *False* + -TODO +Specify whether or not Terminator will ask for confirmation when closing +multiple terminals. // --- Window appearance --- @@ -84,7 +100,7 @@ If this is set to 'hidden', the tab bar will not be shown. Hiding the tab is not recommended, as it can be very confusing. *close_button_on_tab* = _boolean_:: -Default value: : *True* + +Default value: *True* + If set to True, tabs will have a close button on them. // what is this??? @@ -118,7 +134,8 @@ peer terminal. If set to False, they will always use the default profile. *link_single_click* = _boolean_:: Default value: *False* + -TODO +If set to True, clicking a link will open it even if *Ctrl* is not +pressed. // --- Copy & Paste behavior --- @@ -133,7 +150,7 @@ TODO *disable_mouse_paste* = _boolean_:: Default value: *False* + -TODO +If set to True, mouse pasting will be disabled. *smart_copy* = _boolean_:: Default value: *True* + From a9c5e1836538d074f4365c67388e292a92ca34f8 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 1 Apr 2023 21:44:28 +0200 Subject: [PATCH 068/101] Remove more unused settings and update the docs accordingly Removed settings: scroll_background, focus_on_close, cycle_term_tab, ignore_hosts. --- doc/terminator.1 | 8 ++------ doc/terminator.adoc | 6 +----- terminatorlib/config.py | 4 ---- terminatorlib/prefseditor.py | 5 ----- 4 files changed, 3 insertions(+), 20 deletions(-) diff --git a/doc/terminator.1 b/doc/terminator.1 index 4d3591fe5..a224b5307 100644 --- a/doc/terminator.1 +++ b/doc/terminator.1 @@ -2,12 +2,12 @@ .\" Title: terminator .\" Author: [see the "AUTHOR(S)" section] .\" Generator: Asciidoctor 2.0.18 -.\" Date: 2023-03-30 +.\" Date: 2023-04-01 .\" Manual: Manual for Terminator .\" Source: Terminator .\" Language: English .\" -.TH "TERMINATOR" "1" "2023-03-30" "Terminator" "Manual for Terminator" +.TH "TERMINATOR" "1" "2023-04-01" "Terminator" "Manual for Terminator" .ie \n(.g .ds Aq \(aq .el .ds Aq ' .ss \n[.ss] 0 @@ -264,16 +264,12 @@ Move to previous tab. .RS 4 Move to the \fIn\fPext terminal within the same tab. .br -If \fBcycle_term_tab\fP is \fBFalse\fP, cycle within the same tab will be -disabled. .RE .sp \fBCtrl+Shift+P\fP or \fBCtrl+Shift+Tab\fP .RS 4 Move to the \fIp\fPrevious terminal within the same tab. .br -If \fBcycle_term_tab\fP is \fBFalse\fP, cycle within the same tab will be -disabled. .RE .SS "Organisation" .sp diff --git a/doc/terminator.adoc b/doc/terminator.adoc index 806c36491..92408f131 100644 --- a/doc/terminator.adoc +++ b/doc/terminator.adoc @@ -2,7 +2,7 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-03-30 +:revdate: 2023-04-01 :docdate: {revdate} == NAME @@ -167,13 +167,9 @@ Move to previous tab. *Ctrl+Shift+N* or *Ctrl+Tab*:: Move to the __n__ext terminal within the same tab. + -If *cycle_term_tab* is *False*, cycle within the same tab will be -disabled. *Ctrl+Shift+P* or *Ctrl+Shift+Tab*:: Move to the __p__revious terminal within the same tab. + -If *cycle_term_tab* is *False*, cycle within the same tab will be -disabled. === Organisation The following items relate to arranging and resizing terminals. diff --git a/terminatorlib/config.py b/terminatorlib/config.py index fbca71afd..42780afea 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -232,7 +232,6 @@ 'foreground_color' : '#aaaaaa', 'show_titlebar' : True, 'scrollbar_position' : "right", - 'scroll_background' : True, 'scroll_on_keystroke' : True, 'scroll_on_output' : False, 'scrollback_lines' : 500, @@ -252,14 +251,11 @@ 'bold_is_bright' : False, 'cell_height' : 1.0, 'cell_width' : 1.0, - 'focus_on_close' : 'auto', 'force_no_bell' : False, - 'cycle_term_tab' : True, 'copy_on_selection' : False, 'split_to_group' : False, 'autoclean_groups' : True, 'http_proxy' : '', - 'ignore_hosts' : ['localhost','127.0.0.0/8','*.local'], # Titlebar 'title_hide_sizetext' : False, 'title_transmit_fg_color' : '#ffffff', diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index f805c8c6d..ddf49694c 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -958,11 +958,6 @@ def on_login_shell_checkbutton_toggled(self, widget): self.config['login_shell'] = widget.get_active() self.config.save() - def on_scroll_background_checkbutton_toggled(self, widget): - """Scroll background setting changed""" - self.config['scroll_background'] = widget.get_active() - self.config.save() - def on_scroll_on_keystroke_checkbutton_toggled(self, widget): """Scroll on keystrong setting changed""" self.config['scroll_on_keystroke'] = widget.get_active() From 0570307ecb9fcd3b60e5f1ea58268ffeb4d26f2b Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sun, 2 Apr 2023 17:26:24 +0200 Subject: [PATCH 069/101] Remove unused 'color_scheme' setting The color scheme in use is determined by checking the 'foreground_color' and 'background_color' settings. --- terminatorlib/config.py | 1 - 1 file changed, 1 deletion(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 42780afea..415533f78 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -220,7 +220,6 @@ 'background_image_align_vert' : 'middle', 'backspace_binding' : 'ascii-del', 'delete_binding' : 'escape-sequence', - 'color_scheme' : 'grey_on_black', 'cursor_blink' : True, 'cursor_shape' : 'block', 'cursor_fg_color' : '', From 468ef23c79e963598a89cbd23c9c3901275f09f0 Mon Sep 17 00:00:00 2001 From: Ruslan Kashinin Date: Mon, 3 Apr 2023 01:17:02 +0200 Subject: [PATCH 070/101] Fix for issue #676: title field not seem to be working with JSON profile --- terminatorlib/configjson.py | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/terminatorlib/configjson.py b/terminatorlib/configjson.py index 48c6ab5a7..e011ea2f4 100644 --- a/terminatorlib/configjson.py +++ b/terminatorlib/configjson.py @@ -54,15 +54,24 @@ def build_multi_tab_layout(self, layoutjson, vertical): def build_terminal_layout(self, layoutjson, children, parent, order): dbg ('Building a terminal from json: %s' % layoutjson) - + + def from_json(layout_name, json_name=None): + if json_name is None: + json_name = layout_name + + if json_name in layoutjson: + children[parent + "." + str(order)].__setitem__(layout_name, layoutjson[json_name]) + children[parent + "." + str(order)] = { 'type': 'Terminal', 'order': order, 'parent': parent, - 'profile': self.profile_to_use, - 'command': layoutjson['command'] + 'profile': self.profile_to_use } - + + from_json('command') + from_json('title') + def build_container_layout(self, layoutjson, children, parent, order, vertical): if len(layoutjson) == 1: layoutjson = layoutjson[0] From 9b93abb8fe448cb6f20357f837d85a61480d1fca Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Tue, 4 Apr 2023 00:55:50 +0200 Subject: [PATCH 071/101] terminator_config: add profile settings --- doc/gen_manpages.sh | 4 + doc/terminator_config.adoc | 347 +++++++++++++++++++++++++++++++++++-- 2 files changed, 333 insertions(+), 18 deletions(-) create mode 100755 doc/gen_manpages.sh diff --git a/doc/gen_manpages.sh b/doc/gen_manpages.sh new file mode 100755 index 000000000..49c6df1e7 --- /dev/null +++ b/doc/gen_manpages.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +asciidoctor -b manpage terminator.adoc +asciidoctor -b manpage terminator_config.adoc diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index 7392980ec..bcd9c1dae 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -44,7 +44,7 @@ This is what a Terminator config file should look like: == global_config These are the options Terminator currently supports in the -*global_config* section: +*global_config* section. === Window Behavior & Appearance @@ -80,15 +80,14 @@ If set to True, the window will resize in step with font sizes. *suppress_multiple_term_dialog* = _boolean_:: Default value: *False* + -Specify whether or not Terminator will ask for confirmation when closing +If set to True, Terminator will ask for confirmation when closing multiple terminals. // --- Window appearance --- *borderless* = _boolean_:: Default value: *False* + -Control whether the Terminator window will be started without window -borders. +If set to True, the window will be started without window borders. === Tab Behavior & Appearance @@ -96,8 +95,8 @@ borders. Default value: *top* + Specify where tabs are placed. Can be any of: 'top', 'left', 'right', 'bottom', 'hidden'. -If this is set to 'hidden', the tab bar will not be shown. Hiding the -tab is not recommended, as it can be very confusing. +If set to 'hidden', the tab bar will not be shown. Hiding the tab is not +recommended, as it can be very confusing. *close_button_on_tab* = _boolean_:: Default value: *True* + @@ -122,14 +121,14 @@ TODO *focus* = _string_:: Default value: *click* + -Control how focus is given to terminals. +Specify how focus is given to terminals. 'click' means the focus only moves to a terminal after you click in it. 'sloppy' means the focus will follow the mouse pointer. 'system' means the focus will match that used by a GNOME window manager. *always_split_with_profile* = _boolean_:: Default value: *False* + -Control whether splits/tabs will continue to use the profile of their +Specify whether splits/tabs will continue to use the profile of their peer terminal. If set to False, they will always use the default profile. *link_single_click* = _boolean_:: @@ -168,7 +167,7 @@ TODO *handle_size* = _integer_:: Default value: *1* + -Control the width of the separator between terminals. +Specify the width of the separator between terminals. Anything outside the range 0-20 (inclusive) will be ignored and use your default theme value. @@ -192,13 +191,14 @@ TODO *title_at_bottom* = _boolean_:: Default value: *False* + -TODO +If set to True, the terminal's titlebar will be drawn at the bottom +instead of the top. === Miscellaneous *dbus* = _boolean_:: Default value: *True* + -Control whether or not Terminator will load its DBus server. +Specify whether Terminator will load its DBus server. When this server is loaded, running Terminator multiple times will cause the first Terminator process to open additional windows. If this configuration item is set to False, or the python dbus module is @@ -211,20 +211,18 @@ TODO *broadcast_default* = _string_:: Default value: *group* + -Specify default broadcast behavior. +Specify the default broadcast behavior. Can be any of: 'all', 'group', 'off'. -// try_posix_regexp ??? - *use_custom_url_handler* = _boolean_:: Default value: *False* + If set to True, URL handling will be given over entirely to the program specified by 'custom_url_handler'. *custom_url_handler* = _string_:: -Path to a program which accepts a URI as an argument and does something -relevant with it. This option is ignored unless 'use_custom_url_handler' -is set to True. +Specify the path to a program which accepts a URI as an argument and +does something relevant with it. +This option is ignored unless *use_custom_url_handler* is set to True. *case_sensitive* = _boolean_:: Default value: *True* + @@ -236,10 +234,323 @@ TODO *enabled_plugins* = _list of strings_:: Default value: *['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler']* + -A list of plugins which should be loaded by default. All other plugin +Specify which plugins will be loaded by default. All other plugin classes will be ignored. +== keybindings +These are the options Terminator currently supports in the *keybindings* +section. + +TODO + == profiles These are the options Terminator currently supports in the *profiles* section. Each profile should be its own subsection with a header in the format *+[[name]]+*. + +=== General + +*allow_bold* = _boolean_:: +Default value: *True* + +If set to True, text in the terminal can displayed in bold. + +*copy_on_selection* = _boolean_:: +Default value: *False* + +TODO + +*disable_mousewheel_zoom* = _boolean_:: +Default value: *False* + +If set to True, Ctrl+mouse_wheel will not zoom or unzoom the terminal. + +*word_chars* = _string_:: +Default value: **-,./?%&#:_** + +TODO + +*cell_width* = _float_:: +Default value: *1.0* + +TODO + +*cell_height* = _float_:: +Default value: *1.0* + +TODO + +*mouse_autohide* = _boolean_:: +Default value: *True* + +If set to True, the mouse pointer will be hidden when typing. + +*term* = _string_:: +Default value: *xterm-256color* + +TODO + +*colorterm* = _string_:: +Default value: *truecolor* + +TODO + +*split_to_group* = _boolean_:: +Default value: *False* + +TODO + +*autoclean_groups* = _boolean_:: +Default value: *True* + +TODO + +// --- Font --- + +*use_system_font* = _boolean_:: +Default value: *True* + +If set to True, the system default font will be used for text in the +terminal. Otherwise, the value of *font* will be used. + +*font* = _string_:: +Default value: *Mono 10* + +Specify which font to use for text in the terminal. +This option is ignored unless *use_system_font* is set to False. + +// --- Cursor --- + +*cursor_blink* = _boolean_:: +Default value: *True* + +If set to True, the cursor will blink when not typing. + +*cursor_shape* = _string_:: +Default value: *block* + +Specify the shape of the cursor. +Can be any of: 'block', 'underline', 'ibeam'. + +*cursor_color_default* = _boolean_:: +Default value: *True* + +TODO + +*cursor_fg_color* = _color string_:: +Specify the foreground color to use for the cursor. +This option is ignored unless *cursor_color_default* is set to False. + +*cursor_bg_color* = _color string_:: +Specify the background color to use for the cursor. +This option is ignored unless *cursor_color_default* is set to False. + +// --- Bell --- + +*audible_bell* = _boolean_:: +Default value: *False* + +If set to True, a sound will be played when an application writes the +escape sequence for the terminal bell. + +*visible_bell* = _boolean_:: +Default value: *False* + +If set to True, the terminal will flash when an application writes the +escape sequence for the terminal bell. + +*urgent_bell* = _boolean_:: +Default value: *False* + +TODO + +*icon_bell* = _boolean_:: +Default value: *True* + +If set to True, a small icon will be shown on the terminal titlebar when +an application writes the escape sequence for the terminal bell. + +*force_no_bell* = _boolean_:: +Default value: *False* + +If set to True, the terminal bell will be completely disabled. + +=== Command + +*login_shell* = _boolean_:: +Default value: *False* + +TODO + +*use_custom_command* = _boolean_:: +Default value: *False* + +If set to True, the value of *custom_command* will be used instead of +the default shell. + +*custom_command* = _string_:: +Specify the command to execute instead of the default shell. +This option is ignored unless *use_custom_command* is set to True. + +*exit_action* = _string_:: +Default value: *close* + +Specify the action to perform when the terminal is closed. +'close' means the terminal will be removed. +'restart' means the shell (or the command specified in *custom_command*) +will be restarted. +'hold' means the terminal will be kept open, even if the process in it +has terminated. + +=== Colors + +*use_theme_colors* = _boolean_:: +Default value: *False* + +If set to True, the theme's foreground and background colors will be +used for the terminal. Otherwise, the values of *foreground_color* and +*background_color* will be used. + +*foreground_color* = _color string_:: +Default value: *#AAAAAA* + +Specify the foreground color to use for the terminal. +This option is ignored unless *use_theme_colors* is set to False. + +*background_color* = _color string_:: +Default value: *#000000* + +Specify the background color to use for the terminal. +This option is ignored unless *use_theme_colors* is set to False. + +*palette* = TODO:: +TODO + +*bold_is_bright* = _boolean_:: +Default value: *False* + +If set to True, bold text will have brighter colors. + +=== Background + +*background_darkness* = _float_:: +Default value: *0.5* + +TODO + +*background_type* = _string_:: +Default value: *solid* + +Specify what type of background the terminal will have. +'solid' means the background will be a solid (opaque) color. +'transparent' means the background will be a transparent color, with its +transparency being the value of *background_darkness*. +'image' means the background will be an image, whose path is the value +of *background_image*; the background color will be drawn on top of it, +with its transparenty being the value of *background_darkness*. + +*background_image* = _path string_:: +Specify the path to an image that will be used as background. +This option is ignored unless *background_type* is set to 'image'. + +*background_image_mode* = _string_:: +Default value: *stretch_and_fill* + +Specify how the background image will be drawn. +'stretch_and_fill' means the image will fill the terminal entirely, +without necessarily maintaining aspect ratio. +'scale_and_fit' means the image will fit inside the terminal, eventually +leaving blank bars, while maintaining aspect ratio. +'scale_and_crop' means the image will fill the terminal entirely, +eventually getting cropped, while maintaining aspect ratio. +'tiling' means the image will be repeated as to fill the terminal. +This option is ignored unless *background_type* is set to 'image'. + +*background_image_align_horiz* = _string_:: +Default value: *center* + +Specify the horizontal alignment of the background image. +Can be any of: 'left', 'center', 'right'. +This option is ignored unless *background_type* is set to 'image'. + +*background_image_align_vert* = _string_:: +Default value: *middle* + +Specify the vertical alignment of the background image. +Can be any of: 'top', 'middle', 'bottom'. +This option is ignored unless *background_type* is set to 'image'. + +=== Scrolling + +*scrollbar_position* = _string_:: +Default value: *right* + +Specify where the terminal scrollbar is put. +Can be any of: 'left', 'right', 'hidden'. + +*scroll_on_output* = _boolean_:: +Default value: *False* + +If set to True, the terminall will scroll to the bottom when an +application writes text to it. + +*scroll_on_keystroke* = _boolean_:: +Default value: *True* + +If set to True, the terminal will scroll to the bottom when typing. + +*scrollback_infinite* = _boolean_:: +Default value: *False* + +If set to True, the terminal will keep the entire scrollback history. + +*scrollback_lines* = _integer_:: +Default value: *500* + +Specify how many lines of scrollback history will be kept by the +terminal. Lines that don't fit in the scrollback history will be +discarted. Note that setting large values can slow down rewrapping and +resizing. +This option is ignored unless *scrollback_infinite* is set to False. + +=== Compatibility + +*backspace_binding* = _string_:: +Default value: *ascii-del* + +Specify what code will be generated by the backspace key. +The value can be: +'ascii-del' for the ASCII DEL character; +'control-h' for the ASCII BS character (Ctrl+H); +'escape-sequence' for the escape sequence typically bound to backspace +or delete; +'automatic' for TODO. + +*delete_binding* = _string_:: +Default value: *escape-sequence* + +Specify what code will be generated by the delete key. +The value can be: +'ascii-del' for the ASCII DEL character; +'control-h' for the ASCII BS character (Ctrl+H); +'escape-sequence' for the escape sequence typically bound to backspace +or delete; +'automatic' for TODO. + +=== Titlebar + +*show_titlebar* = _boolean_:: +Default value: *True* + +If set to True, the terminal will have a titlebar showing the current +title of that terminal. + +*title_hide_sizetext* = _boolean_:: +Default value: *False* + +If set to True, the size of the terminal will not be written on its +titlebar. + +*title_use_system_font* = _boolean_:: +Default value: *True* + +If set to True, the system default font will be used for text in the +terminal's titlebar. Otherwise, the value of *title_font* will be used. + +*title_font* = _string_:: +Default value: *Sans 9* + +Specify which font to use for text in the terminal's titlebar. +This option is ignored unless *title_use_system_font* is set to False. + +// --- Titlebar colors --- + +*title_transmit_fg_color* = _color string_:: +Default value: *#ffffff* + +Specify the foreground color to use for the terminal's titlebar in case +the terminal is focused. + +*title_transmit_bg_color* = _color string_:: +Default value: *#c80003* + +Specify the background color to use for the terminal's titlebar in case +the terminal is focused. + +*title_inactive_fg_color* = _color string_:: +Default value: *#000000* + +Specify the foreground color to use for the terminal's titlebar in case +the terminal is unfocused. + +*title_inactive_bg_color* = _color string_:: +Default value: *#c0bebf* + +Specify the background color to use for the terminal's titlebar in case +the terminal is unfocused. + +*title_receive_fg_color* = _color string_:: +Default value: *#ffffff* + +Specify the foreground color to use for the terminal's titlebar in case +the terminal is in a group and is receiving input while unfocused. + +*title_receive_bg_color* = _color string_:: +Default value: *#0076c9* + +Specify the background color to use for the terminal's titlebar in case +the terminal is in a group and is receiving input while unfocused. + +== SEE ALSO +*terminator*(1), http://www.voidspace.org.uk/python/configobj.html +// this link might be dead From beae56f2b8b0d3233c221b1bbfe137efd23b8873 Mon Sep 17 00:00:00 2001 From: Thibault Brocheton <7646137+Thibault-Brocheton@users.noreply.github.com> Date: Tue, 4 Apr 2023 11:01:51 +0200 Subject: [PATCH 072/101] fix: typo in french translation dans = in sans = without --- po/fr.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/po/fr.po b/po/fr.po index 7c46fc355..46c970ba0 100644 --- a/po/fr.po +++ b/po/fr.po @@ -1601,7 +1601,7 @@ msgstr "Supprimer le groupe %s" #: ../terminatorlib/terminal.py:512 msgid "G_roup all in window" -msgstr "Tout g_rouper sans une fenêtre" +msgstr "Tout g_rouper dans une fenêtre" #: ../terminatorlib/terminal.py:517 msgid "Ungro_up all in window" From 9a63671fe8fa255783e32200296b50fa0c70e364 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 7 Apr 2023 12:43:31 +0200 Subject: [PATCH 073/101] terminator_config: move 'default value' to the end of description --- doc/terminator_config.adoc | 337 ++++++++++++++++++------------------- 1 file changed, 164 insertions(+), 173 deletions(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index bcd9c1dae..db6b42a25 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -2,12 +2,11 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-03-31 +:revdate: 2023-04-03 :docdate: {revdate} == NAME -// ~/.config/terminator/config - the config file for Terminator terminal emulator -config - TODO +terminator_config - the config file for Terminator terminal emulator == DESCRIPTION This file contains the configuration for *terminator*(1). @@ -51,173 +50,173 @@ These are the options Terminator currently supports in the // --- Window behavior --- *window_state* = _string_:: -Default value: *normal* + Control how the Terminator window opens. 'normal' means it opens normally. 'maximise' means it opens in a maximised state. 'fullscreen' means it opens in a fullscreen state. -'hidden' means it stays hidden. +'hidden' means it stays hidden. + +Default value: *normal* *always_on_top* = _boolean_:: -Default value: *False* + -If set to True, the window will always stay on top of other windows. +If set to True, the window will always stay on top of other windows. + +Default value: *False* *sticky* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *hide_on_lose_focus* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *hide_from_taskbar* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *geometry_hinting* = _boolean_:: -Default value: *False* + -If set to True, the window will resize in step with font sizes. +If set to True, the window will resize in step with font sizes. + +Default value: *False* *suppress_multiple_term_dialog* = _boolean_:: -Default value: *False* + If set to True, Terminator will ask for confirmation when closing -multiple terminals. +multiple terminals. + +Default value: *False* // --- Window appearance --- *borderless* = _boolean_:: -Default value: *False* + -If set to True, the window will be started without window borders. +If set to True, the window will be started without window borders. + +Default value: *False* === Tab Behavior & Appearance *tab_position* = _string_:: -Default value: *top* + Specify where tabs are placed. Can be any of: 'top', 'left', 'right', 'bottom', 'hidden'. If set to 'hidden', the tab bar will not be shown. Hiding the tab is not -recommended, as it can be very confusing. +recommended, as it can be very confusing. + +Default value: *top* *close_button_on_tab* = _boolean_:: -Default value: *True* + -If set to True, tabs will have a close button on them. +If set to True, tabs will have a close button on them. + +Default value: *True* // what is this??? *scroll_tabbar* = _boolean_:: -Default value: *False* + If set to True, the tab bar will not fill the width of the window. The titlebars of the tabs will only take as much space as is necessary for the text they contain. Except, that is, if the tabs no longer fit the width of the window - in that case scroll buttons will appear to -move through the tabs. +move through the tabs. + +Default value: *False* *homogeneous_tabbar* = _boolean_:: -Default value: *True* + -TODO +TODO + +Default value: *True* === Terminal Behavior & Appearance // --- Terminal behavior --- *focus* = _string_:: -Default value: *click* + Specify how focus is given to terminals. 'click' means the focus only moves to a terminal after you click in it. 'sloppy' means the focus will follow the mouse pointer. -'system' means the focus will match that used by a GNOME window manager. +'system' means the focus will match that used by a GNOME window manager. + +Default value: *click* *always_split_with_profile* = _boolean_:: -Default value: *False* + Specify whether splits/tabs will continue to use the profile of their -peer terminal. If set to False, they will always use the default profile. +peer terminal. If set to False, they will always use the default profile. + +Default value: *False* *link_single_click* = _boolean_:: -Default value: *False* + If set to True, clicking a link will open it even if *Ctrl* is not -pressed. +pressed. + +Default value: *False* // --- Copy & Paste behavior --- *putty_paste_style* = _boolean_:: -Default value: *False* + If set to True, right-click will paste the Primary selection, -while middle-click will popup the context menu. +while middle-click will popup the context menu. + +Default value: *False* *putty_paste_style_source_clipboard* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *disable_mouse_paste* = _boolean_:: -Default value: *False* + -If set to True, mouse pasting will be disabled. +If set to True, mouse pasting will be disabled. + +Default value: *False* *smart_copy* = _boolean_:: -Default value: *True* + If set to True, and there is no selection, the shortcut is allowed to pass through. This is useful for overloading Ctrl-C to copy a selection, or send the SIGINT to the current process if there is no selection. If False, the shortcut does not pass through at all, and the SIGINT does -not get sent. +not get sent. + +Default value: *True* *clear_select_on_copy* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* // --- Terminal appearance --- *handle_size* = _integer_:: -Default value: *1* + Specify the width of the separator between terminals. Anything outside the range 0-20 (inclusive) will be ignored and use your -default theme value. +default theme value. + +Default value: *1* *inactive_color_offset* = _float_:: -Default value: *0.8* + Specify how much to reduce the color values of fonts in terminals that -do not have focus. +do not have focus. + +Default value: *0.8* *inactive_bg_color_offset* = _float_:: -Default value: *1.0* + Specify how much to reduce the color values of the background in -terminals that do not have focus. +terminals that do not have focus. + +Default value: *1.0* *cell_width* = _float_:: -Default value: *1.0* + -TODO +TODO + +Default value: *1.0* *cell_height* = _float_:: -Default value: *1.0* + -TODO +TODO + +Default value: *1.0* *title_at_bottom* = _boolean_:: -Default value: *False* + If set to True, the terminal's titlebar will be drawn at the bottom -instead of the top. +instead of the top. + +Default value: *False* === Miscellaneous *dbus* = _boolean_:: -Default value: *True* + Specify whether Terminator will load its DBus server. When this server is loaded, running Terminator multiple times will cause the first Terminator process to open additional windows. If this configuration item is set to False, or the python dbus module is unavailable, running Terminator multiple times will run a separate -Terminator process for each invocation. +Terminator process for each invocation. + +Default value: *True* *extra_styling* = _boolean_:: -Default value: *True* + -TODO +TODO + +Default value: *True* *broadcast_default* = _string_:: -Default value: *group* + Specify the default broadcast behavior. -Can be any of: 'all', 'group', 'off'. +Can be any of: 'all', 'group', 'off'. + +Default value: *group* *use_custom_url_handler* = _boolean_:: -Default value: *False* + If set to True, URL handling will be given over entirely to the program -specified by 'custom_url_handler'. +specified by 'custom_url_handler'. + +Default value: *False* *custom_url_handler* = _string_:: Specify the path to a program which accepts a URI as an argument and @@ -225,17 +224,17 @@ does something relevant with it. This option is ignored unless *use_custom_url_handler* is set to True. *case_sensitive* = _boolean_:: -Default value: *True* + -TODO +TODO + +Default value: *True* *invert_search* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *enabled_plugins* = _list of strings_:: -Default value: *['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler']* + Specify which plugins will be loaded by default. All other plugin -classes will be ignored. +classes will be ignored. + +Default value: *['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler']* == keybindings These are the options Terminator currently supports in the *keybindings* @@ -251,75 +250,67 @@ format *+[[name]]+*. === General *allow_bold* = _boolean_:: -Default value: *True* + -If set to True, text in the terminal can displayed in bold. +If set to True, text in the terminal can displayed in bold. + +Default value: *True* *copy_on_selection* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *disable_mousewheel_zoom* = _boolean_:: -Default value: *False* + -If set to True, Ctrl+mouse_wheel will not zoom or unzoom the terminal. +If set to True, Ctrl+mouse_wheel will not zoom or unzoom the terminal. + +Default value: *False* *word_chars* = _string_:: -Default value: **-,./?%&#:_** + -TODO - -*cell_width* = _float_:: -Default value: *1.0* + -TODO - -*cell_height* = _float_:: -Default value: *1.0* + -TODO +TODO + +Default value: **-,./?%&#:_** *mouse_autohide* = _boolean_:: -Default value: *True* + -If set to True, the mouse pointer will be hidden when typing. +If set to True, the mouse pointer will be hidden when typing. + +Default value: *True* *term* = _string_:: -Default value: *xterm-256color* + -TODO +TODO + +Default value: *xterm-256color* *colorterm* = _string_:: -Default value: *truecolor* + -TODO +TODO + +Default value: *truecolor* *split_to_group* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *autoclean_groups* = _boolean_:: -Default value: *True* + -TODO +TODO + +Default value: *True* // --- Font --- *use_system_font* = _boolean_:: -Default value: *True* + If set to True, the system default font will be used for text in the -terminal. Otherwise, the value of *font* will be used. +terminal. Otherwise, the value of *font* will be used. + +Default value: *True* *font* = _string_:: -Default value: *Mono 10* + Specify which font to use for text in the terminal. -This option is ignored unless *use_system_font* is set to False. +This option is ignored unless *use_system_font* is set to False. + +Default value: *Mono 10* // --- Cursor --- *cursor_blink* = _boolean_:: -Default value: *True* + -If set to True, the cursor will blink when not typing. +If set to True, the cursor will blink when not typing. + +Default value: *True* *cursor_shape* = _string_:: -Default value: *block* + Specify the shape of the cursor. -Can be any of: 'block', 'underline', 'ibeam'. +Can be any of: 'block', 'underline', 'ibeam'. + +Default value: *block* *cursor_color_default* = _boolean_:: -Default value: *True* + -TODO +TODO + +Default value: *True* *cursor_fg_color* = _color string_:: Specify the foreground color to use for the cursor. @@ -332,99 +323,98 @@ This option is ignored unless *cursor_color_default* is set to False. // --- Bell --- *audible_bell* = _boolean_:: -Default value: *False* + If set to True, a sound will be played when an application writes the -escape sequence for the terminal bell. +escape sequence for the terminal bell. + +Default value: *False* *visible_bell* = _boolean_:: -Default value: *False* + If set to True, the terminal will flash when an application writes the -escape sequence for the terminal bell. +escape sequence for the terminal bell. + +Default value: *False* *urgent_bell* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *icon_bell* = _boolean_:: -Default value: *True* + If set to True, a small icon will be shown on the terminal titlebar when -an application writes the escape sequence for the terminal bell. +an application writes the escape sequence for the terminal bell. + +Default value: *True* *force_no_bell* = _boolean_:: -Default value: *False* + -If set to True, the terminal bell will be completely disabled. +If set to True, the terminal bell will be completely disabled. + +Default value: *False* === Command *login_shell* = _boolean_:: -Default value: *False* + -TODO +TODO + +Default value: *False* *use_custom_command* = _boolean_:: -Default value: *False* + If set to True, the value of *custom_command* will be used instead of -the default shell. +the default shell. + +Default value: *False* *custom_command* = _string_:: Specify the command to execute instead of the default shell. This option is ignored unless *use_custom_command* is set to True. *exit_action* = _string_:: -Default value: *close* + Specify the action to perform when the terminal is closed. 'close' means the terminal will be removed. 'restart' means the shell (or the command specified in *custom_command*) will be restarted. 'hold' means the terminal will be kept open, even if the process in it -has terminated. +has terminated. + +Default value: *close* === Colors *use_theme_colors* = _boolean_:: -Default value: *False* + If set to True, the theme's foreground and background colors will be used for the terminal. Otherwise, the values of *foreground_color* and -*background_color* will be used. +*background_color* will be used. + +Default value: *False* *foreground_color* = _color string_:: -Default value: *#AAAAAA* + Specify the foreground color to use for the terminal. -This option is ignored unless *use_theme_colors* is set to False. +This option is ignored unless *use_theme_colors* is set to False. + +Default value: *#AAAAAA* *background_color* = _color string_:: -Default value: *#000000* + Specify the background color to use for the terminal. -This option is ignored unless *use_theme_colors* is set to False. +This option is ignored unless *use_theme_colors* is set to False. + +Default value: *#000000* *palette* = TODO:: TODO *bold_is_bright* = _boolean_:: -Default value: *False* + -If set to True, bold text will have brighter colors. +If set to True, bold text will have brighter colors. + +Default value: *False* === Background *background_darkness* = _float_:: -Default value: *0.5* + -TODO +TODO + +Default value: *0.5* *background_type* = _string_:: -Default value: *solid* + Specify what type of background the terminal will have. 'solid' means the background will be a solid (opaque) color. 'transparent' means the background will be a transparent color, with its transparency being the value of *background_darkness*. 'image' means the background will be an image, whose path is the value of *background_image*; the background color will be drawn on top of it, -with its transparenty being the value of *background_darkness*. +with its transparenty being the value of *background_darkness*. + +Default value: *solid* *background_image* = _path string_:: Specify the path to an image that will be used as background. This option is ignored unless *background_type* is set to 'image'. *background_image_mode* = _string_:: -Default value: *stretch_and_fill* + Specify how the background image will be drawn. 'stretch_and_fill' means the image will fill the terminal entirely, without necessarily maintaining aspect ratio. @@ -433,123 +423,124 @@ leaving blank bars, while maintaining aspect ratio. 'scale_and_crop' means the image will fill the terminal entirely, eventually getting cropped, while maintaining aspect ratio. 'tiling' means the image will be repeated as to fill the terminal. -This option is ignored unless *background_type* is set to 'image'. +This option is ignored unless *background_type* is set to 'image'. + +Default value: *stretch_and_fill* *background_image_align_horiz* = _string_:: -Default value: *center* + Specify the horizontal alignment of the background image. Can be any of: 'left', 'center', 'right'. -This option is ignored unless *background_type* is set to 'image'. +This option is ignored unless *background_type* is set to 'image'. + +Default value: *center* *background_image_align_vert* = _string_:: -Default value: *middle* + Specify the vertical alignment of the background image. Can be any of: 'top', 'middle', 'bottom'. -This option is ignored unless *background_type* is set to 'image'. +This option is ignored unless *background_type* is set to 'image'. + +Default value: *middle* === Scrolling *scrollbar_position* = _string_:: -Default value: *right* + Specify where the terminal scrollbar is put. -Can be any of: 'left', 'right', 'hidden'. +Can be any of: 'left', 'right', 'hidden'. + +Default value: *right* *scroll_on_output* = _boolean_:: -Default value: *False* + If set to True, the terminall will scroll to the bottom when an -application writes text to it. +application writes text to it. + +Default value: *False* *scroll_on_keystroke* = _boolean_:: -Default value: *True* + -If set to True, the terminal will scroll to the bottom when typing. +If set to True, the terminal will scroll to the bottom when typing. + +Default value: *True* *scrollback_infinite* = _boolean_:: -Default value: *False* + -If set to True, the terminal will keep the entire scrollback history. +If set to True, the terminal will keep the entire scrollback history. + +Default value: *False* *scrollback_lines* = _integer_:: -Default value: *500* + Specify how many lines of scrollback history will be kept by the terminal. Lines that don't fit in the scrollback history will be discarted. Note that setting large values can slow down rewrapping and resizing. -This option is ignored unless *scrollback_infinite* is set to False. +This option is ignored unless *scrollback_infinite* is set to False. + +Default value: *500* === Compatibility *backspace_binding* = _string_:: -Default value: *ascii-del* + Specify what code will be generated by the backspace key. The value can be: 'ascii-del' for the ASCII DEL character; 'control-h' for the ASCII BS character (Ctrl+H); 'escape-sequence' for the escape sequence typically bound to backspace or delete; -'automatic' for TODO. +'automatic' for TODO. + +Default value: *ascii-del* *delete_binding* = _string_:: -Default value: *escape-sequence* + Specify what code will be generated by the delete key. The value can be: 'ascii-del' for the ASCII DEL character; 'control-h' for the ASCII BS character (Ctrl+H); 'escape-sequence' for the escape sequence typically bound to backspace or delete; -'automatic' for TODO. +'automatic' for TODO. + +Default value: *escape-sequence* === Titlebar *show_titlebar* = _boolean_:: -Default value: *True* + If set to True, the terminal will have a titlebar showing the current -title of that terminal. +title of that terminal. + +Default value: *True* *title_hide_sizetext* = _boolean_:: -Default value: *False* + If set to True, the size of the terminal will not be written on its -titlebar. +titlebar. + +Default value: *False* *title_use_system_font* = _boolean_:: -Default value: *True* + If set to True, the system default font will be used for text in the -terminal's titlebar. Otherwise, the value of *title_font* will be used. +terminal's titlebar. Otherwise, the value of *title_font* will be used. + +Default value: *True* *title_font* = _string_:: -Default value: *Sans 9* + Specify which font to use for text in the terminal's titlebar. -This option is ignored unless *title_use_system_font* is set to False. +This option is ignored unless *title_use_system_font* is set to False. + +Default value: *Sans 9* // --- Titlebar colors --- *title_transmit_fg_color* = _color string_:: -Default value: *#ffffff* + Specify the foreground color to use for the terminal's titlebar in case -the terminal is focused. +the terminal is focused. + +Default value: *#ffffff* *title_transmit_bg_color* = _color string_:: -Default value: *#c80003* + Specify the background color to use for the terminal's titlebar in case -the terminal is focused. +the terminal is focused. + +Default value: *#c80003* *title_inactive_fg_color* = _color string_:: -Default value: *#000000* + Specify the foreground color to use for the terminal's titlebar in case -the terminal is unfocused. +the terminal is unfocused. + +Default value: *#000000* *title_inactive_bg_color* = _color string_:: -Default value: *#c0bebf* + Specify the background color to use for the terminal's titlebar in case -the terminal is unfocused. +the terminal is unfocused. + +Default value: *#c0bebf* *title_receive_fg_color* = _color string_:: -Default value: *#ffffff* + Specify the foreground color to use for the terminal's titlebar in case -the terminal is in a group and is receiving input while unfocused. +the terminal is in a group and is receiving input while unfocused. + +Default value: *#ffffff* *title_receive_bg_color* = _color string_:: -Default value: *#0076c9* + Specify the background color to use for the terminal's titlebar in case -the terminal is in a group and is receiving input while unfocused. +the terminal is in a group and is receiving input while unfocused. + +Default value: *#0076c9* == SEE ALSO *terminator*(1), http://www.voidspace.org.uk/python/configobj.html From 3a710cd6d61e61638bab61d81e61ea58ebf11b3d Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 7 Apr 2023 15:44:30 +0200 Subject: [PATCH 074/101] terminator_config: add keybindings --- doc/terminator_config.adoc | 312 ++++++++++++++++++++++++++++++++++++- 1 file changed, 311 insertions(+), 1 deletion(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index db6b42a25..2f29fe6f8 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -2,7 +2,7 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-04-03 +:revdate: 2023-04-07 :docdate: {revdate} == NAME @@ -41,6 +41,8 @@ This is what a Terminator config file should look like: custom_command = "echo \"foo#bar\"" #Final comment - this will work as expected. ---- +// ================================================================== \\ + == global_config These are the options Terminator currently supports in the *global_config* section. @@ -236,12 +238,315 @@ Specify which plugins will be loaded by default. All other plugin classes will be ignored. + Default value: *['LaunchpadBugURLHandler', 'LaunchpadCodeURLHandler', 'APTURLHandler']* +// ================================================================== \\ + == keybindings These are the options Terminator currently supports in the *keybindings* section. +=== Creation & Destruction + +*split_horiz*:: +Split the current terminal horizontally. + +Default value: *O* + +*split_vert*:: +Split the current terminal vertically. + +Default value: *E* + +*split_auto*:: +Split the current terminal automatically, along the longer side. + +Default value: *A* + +*new_tab*:: +Open a new tab. + +Default value: *T* + +*new_window*:: +Open a new window as part of the existing process. + +Default value: *I* + +*new_terminator*:: +Spawn a new Terminator process. + +Default value: *I* + +*layout_launcher*:: +Open the layout launcher. + +Default value: *L* + +*close_term*:: +Close the current terminal. + +Default value: *W* + +*close_window*:: +Close the current window. + +Default value: *Q* + +=== Navigation + +*cycle_next*:: +Focus the next terminal. This is an alias for *go_next*. + +Default value: *Tab* + +*cycle_prev*:: +Focus the previous terminal. This is an alias for *go_prev*. + +Default value: *Tab* + +*go_next*:: +Focus the next terminal. + +Default value: *N* + +*go_prev*:: +Focus the previous terminal. + +Default value: *P* + +*go_up*:: +Focus the terminal above the current one. + +Default value: *Up* + +*go_down*:: +Focus the terminal below the current one. + +Default value: *Down* + +*go_left*:: +Focus the terminal to the left of the current one. + +Default value: *Left* + +*go_right*:: +Focus the terminal to the right of the current one. + +Default value: *Right* + +// --- Scroll --- + +*page_up*:: +Scroll the terminal up one page. + +*page_down*:: +Scroll the terminal down one page. + +*page_up_half*:: +Scroll the terminal up half a page. + +*page_down_half*:: +Scroll the terminal down half a page. + +*line_up*:: +Scroll the terminal up one line. + +*line_down*:: +Scroll the terminal down one line. + +// --- Tab --- + +*next_tab*:: +Move to the next tab. + +Default value: *Page_Down* + +*prev_tab*:: +Move to the previous tab. + +Default value: *Page_Up* + +*switch_to_tab_1*, *switch_to_tab_2*, ... *switch_to_tab_10*:: +Move to the **N**th tab. +TODO note on switch_to_tab_1? + +=== Organisation + +*resize_up*:: +Move the parent dragbar up. + +Default value: *Up* + +*resize_down*:: +Move the parent dragbar down. + +Default value: *Down* + +*resize_left*:: +Move the parent dragbar left. + +Default value: *Left* + +*resize_right*:: +Move the parent dragbar right. + +Default value: *Right* + +*rotate_cw*:: +Rotate terminals clockwise. + +Default value: *R* + +*rotate_ccw*:: +Rotate terminals counter+clockwise. + +Default value: *R* + +*move_tab_right*:: +Move the current tab to the right by swapping position with the next +tab. + +Default value: *Page_Down* + +*move_tab_left*:: +Move the current tab to the left by swapping position with the previous +tab. + +Default value: *Page_Up* + +=== Focus + +*full_screen*:: +Toggle window to fullscreen. + +Default value: *F11* + +*toggle_zoom*:: +Toggle maximisation of the current terminal. + +Default value: *X* + +*scaled_zoom*:: +Toggle maximisation of the current terminal and scale the font when +maximised. + +Default value: *Z* + +*hide_window*:: +TODO + +Default value: *A* + +=== Grouping & Broadcasting + +*create_group*:: +Create a new group. + +// --- Grouping: All --- + +*group_all*:: +Group all terminals together. + +Default value: *G* + +*ungroup_all*:: +Ungroup all terminals. + +*group_all_toggle*:: +Toggle grouping of all terminals. + +// --- Grouping: Window --- + +*group_win*:: +Group all terminals in the current window together. + +*ungroup_win*:: +Ungroup all terminals in the current window. + +Default value: *W* + +*group_win_toggle*:: +Toggle grouping of all terminals in the current window. + +// --- Grouping: Tab --- + +*group_tab*:: +Group all terminals in the current tab together. + +Default value: *T* + +*ungroup_tab*:: +Ungroup all terminals in the current tab. + +Default value: *T* + +*group_tab_toggle*:: +Toggle grouping of all terminals in the current tab. + +// Broadcasting + +*broadcast_off*:: +Turn broadcasting off. + +*broadcast_group*:: +Broadcast to all terminals in the same group as the current terminal. + +*broadcast_all*:: +Broadcast to all terminals. + +=== Miscellaneous + +*help*:: +Open the full HTML manual in the browser. + +Default value: *F1* + +*preferences*:: +Open the Preferences window. + +*preferences_keybindings*:: +Open the Preferences window and show the Keybindings tab. + +Default value: *K* + +*copy*:: +Copy the selected text to the clipboard. + +Default value: *C* + +*paste*:: +Paste the current contents of the clipboard. + +Default value: *V* + +*paste_selection*:: TODO +*toggle_scrollbar*:: +Toggle the scrollbar. + +Default value: *S* + +*search*:: +Search for text in the terminal scrollback history. + +Default value: *F* + +*reset*:: +Reset the terminal state. + +Default value: *R* + +*reset_clear*:: +Reset the terminal state and clear the terminal window. + +Default value: *G* + +*zoom_in*:: +Increase the font size by one unit. + +Default value: *plus* + +*zoom_out*:: +Decrease the font size by one unit. + +Default value: *minus* + +*zoom_normal*:: +Restore the original font size. + +Default value: *0* + +*zoom_in_all*:: +Increase the font size by one unit for all terminals. + +*zoom_out_all*:: +Decrease the font size by one unit for all terminals. + +*zoom_normal_all*:: +Restore the original font size for all terminals. + +*edit_window_title*:: +Rename the current window. + +Default value: *W* + +*edit_tab_title*:: +Rename the current tab. + +Default value: *A* + +*edit_terminal_title*:: +Rename the current terminal. + +Default value: *X* + +*insert_number*:: +Insert the current terminal's number, i.e. 1 to 12. + +Default value: *1* + +*insert_padded*:: +Insert the current terminal's number, but zero padded, i.e. 01 to 12. + +Default value: *0* + +*next_profile*:: +Switch to the next profile. + +*previous_profile*:: +Switch to the previous profile. + +// ================================================================== \\ + == profiles These are the options Terminator currently supports in the *profiles* section. Each profile should be its own subsection with a header in the @@ -542,6 +847,11 @@ Specify the background color to use for the terminal's titlebar in case the terminal is in a group and is receiving input while unfocused. + Default value: *#0076c9* +// ================================================================== \\ + +TODO layouts section? +TODO plugins section? + == SEE ALSO *terminator*(1), http://www.voidspace.org.uk/python/configobj.html // this link might be dead From b0cb125287964841fb753e32a1ea68729ac91e42 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 7 Apr 2023 22:15:50 +0200 Subject: [PATCH 075/101] terminator_config: add description to some settings --- doc/terminator_config.adoc | 40 ++++++++++++++++++++++---------------- 1 file changed, 23 insertions(+), 17 deletions(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index 2f29fe6f8..5842d9588 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -64,7 +64,7 @@ If set to True, the window will always stay on top of other windows. + Default value: *False* *sticky* = _boolean_:: -TODO + +If set to True, the window will be visible on all workspaces. + Default value: *False* *hide_on_lose_focus* = _boolean_:: @@ -112,10 +112,6 @@ the width of the window - in that case scroll buttons will appear to move through the tabs. + Default value: *False* -*homogeneous_tabbar* = _boolean_:: -TODO + -Default value: *True* - === Terminal Behavior & Appearance // --- Terminal behavior --- @@ -140,12 +136,15 @@ Default value: *False* // --- Copy & Paste behavior --- *putty_paste_style* = _boolean_:: -If set to True, right-click will paste the Primary selection, -while middle-click will popup the context menu. + +If set to True, right-click will paste text, while middle-click will +popup the context menu. The source for the pasted text depends on the +value of *putty_paste_style_source_clipboard*. + Default value: *False* *putty_paste_style_source_clipboard* = _boolean_:: -TODO + +If set to True, the Clipboard will be used as source for pasting in +PuTTY style. Otherwise, the Primary Selection will be used. + +This option is ignored unless *putty_paste_style* is set to True. + Default value: *False* *disable_mouse_paste* = _boolean_:: @@ -183,11 +182,11 @@ terminals that do not have focus. + Default value: *1.0* *cell_width* = _float_:: -TODO + +Specify the horizontal scale of character cells in the terminal. + Default value: *1.0* *cell_height* = _float_:: -TODO + +Specify the vertical scale of character cells in the terminal. + Default value: *1.0* *title_at_bottom* = _boolean_:: @@ -402,7 +401,7 @@ maximised. + Default value: *Z* *hide_window*:: -TODO + +Hide/Show all Terminator windows. + Default value: *A* === Grouping & Broadcasting @@ -575,19 +574,22 @@ If set to True, the mouse pointer will be hidden when typing. + Default value: *True* *term* = _string_:: -TODO + +Specify the value Terminator will assign to the 'TERM' environment +variable. + Default value: *xterm-256color* *colorterm* = _string_:: -TODO + +Specify the value Terminator will assign to the 'COLORTERM' environment +variable. + Default value: *truecolor* *split_to_group* = _boolean_:: -TODO + +If set to True, the terminal created by splitting will be inserted in +the current terminal's group. + Default value: *False* *autoclean_groups* = _boolean_:: -TODO + +If set to True, empty groups will be removed. + Default value: *True* // --- Font --- @@ -702,9 +704,13 @@ Default value: *False* === Background *background_darkness* = _float_:: -TODO + +Specify the transparency of the background color. +The value must be between 0.0 and 1.0. +This option is ignored unless *background_type* is set to 'transparent' +or 'image'. + Default value: *0.5* +// TODO background_type needs improvements *background_type* = _string_:: Specify what type of background the terminal will have. 'solid' means the background will be a solid (opaque) color. @@ -712,7 +718,7 @@ Specify what type of background the terminal will have. transparency being the value of *background_darkness*. 'image' means the background will be an image, whose path is the value of *background_image*; the background color will be drawn on top of it, -with its transparenty being the value of *background_darkness*. + +with its transparency being the value of *background_darkness*. + Default value: *solid* *background_image* = _path string_:: From e2a88a28554138f7044052db00b096819dbed58d Mon Sep 17 00:00:00 2001 From: Ruslan Kashinin Date: Sun, 9 Apr 2023 18:01:41 +0200 Subject: [PATCH 076/101] Fix for issue #676: title field not seem to be working with JSON profile --- terminatorlib/configjson.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/configjson.py b/terminatorlib/configjson.py index e011ea2f4..81cbcfa26 100644 --- a/terminatorlib/configjson.py +++ b/terminatorlib/configjson.py @@ -60,7 +60,7 @@ def from_json(layout_name, json_name=None): json_name = layout_name if json_name in layoutjson: - children[parent + "." + str(order)].__setitem__(layout_name, layoutjson[json_name]) + children[parent + "." + str(order)][layout_name] = layoutjson[json_name] children[parent + "." + str(order)] = { 'type': 'Terminal', From ed5f1c9b0a85f5003d2ad538514f986e56926988 Mon Sep 17 00:00:00 2001 From: nautics889 Date: Tue, 11 Apr 2023 22:51:57 +0300 Subject: [PATCH 077/101] fix: Minor fixes in terminatorlib/configjson.py Remove unused import of 'sys' module; Fix typo in log message; Removed unused variable in `get_layout()` method. --- terminatorlib/configjson.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/terminatorlib/configjson.py b/terminatorlib/configjson.py index 48c6ab5a7..1755cab07 100644 --- a/terminatorlib/configjson.py +++ b/terminatorlib/configjson.py @@ -1,6 +1,5 @@ from .util import dbg, err from os import path -import sys import json import copy from .config import Config @@ -8,6 +7,7 @@ JSON_PROFILE_NAME = "__internal_json_profile__" JSON_LAYOUT_NAME = "__internal_json_layout__" + class ConfigJson(object): profile_to_use = 'default' @@ -73,7 +73,7 @@ def build_container_layout(self, layoutjson, children, parent, order, vertical): self.build_terminal_layout(layoutjson, children, parent, order) return - dbg ('Building %s layout from json: %s' % ("vertical" if vertical else "horizental", layoutjson)) + dbg ('Building %s layout from json: %s' % ("vertical" if vertical else "horizontal", layoutjson)) counter = 0 actualparent = parent @@ -105,9 +105,7 @@ def get_layout(self, layoutjson): if "vertical" in layoutjson: vertical = layoutjson["vertical"] del layoutjson["vertical"] - - result = None - + if len(layoutjson) == 1: firstitem = next(iter(layoutjson.values())) result = self.build_single_tab_layout(firstitem, vertical) From fec901d09e198a369913e681bcee8eb49998d6cc Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Fri, 21 Apr 2023 16:16:21 +0200 Subject: [PATCH 078/101] terminator_config: add layouts and plugins sections + add description to some settings --- doc/terminator_config.adoc | 80 +++++++++++++++++++++++++++++++------- 1 file changed, 66 insertions(+), 14 deletions(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index 5842d9588..3fef4b234 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -2,7 +2,7 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-04-07 +:revdate: 2023-04-21 :docdate: {revdate} == NAME @@ -39,6 +39,17 @@ This is what a Terminator config file should look like: scrollback_lines = '500' #More comment. Single quotes are valid too cursor_blink = True custom_command = "echo \"foo#bar\"" #Final comment - this will work as expected. + +[layouts] + [[default]] + [[[window0]]] + type = Window + parent = "" + [[[child1]]] + type = Terminal + parent = window0 + +[plugins] ---- // ================================================================== \\ @@ -68,11 +79,11 @@ If set to True, the window will be visible on all workspaces. + Default value: *False* *hide_on_lose_focus* = _boolean_:: -TODO + +If set to True, the window will be hidden when focus is lost. + Default value: *False* *hide_from_taskbar* = _boolean_:: -TODO + +If set to True, the window will be hidden from the taskbar. + Default value: *False* *geometry_hinting* = _boolean_:: @@ -225,11 +236,13 @@ does something relevant with it. This option is ignored unless *use_custom_url_handler* is set to True. *case_sensitive* = _boolean_:: -TODO + +If set to True, uppercase and lowercase characters will be considered +different when searching text in the terminal. + Default value: *True* *invert_search* = _boolean_:: -TODO + +If set to True, the search direction will be inverted (bottom to top) +when searching text in the terminal. + Default value: *False* *enabled_plugins* = _list of strings_:: @@ -347,7 +360,8 @@ Default value: *Page_Up* *switch_to_tab_1*, *switch_to_tab_2*, ... *switch_to_tab_10*:: Move to the **N**th tab. -TODO note on switch_to_tab_1? +Note that *1* may be provided as *!* or similar, +depending on the keyboard layout. === Organisation @@ -549,7 +563,7 @@ Switch to the previous profile. == profiles These are the options Terminator currently supports in the *profiles* section. Each profile should be its own subsection with a header in the -format *+[[name]]+*. +format *\[[name]]*. === General @@ -640,7 +654,8 @@ escape sequence for the terminal bell. + Default value: *False* *urgent_bell* = _boolean_:: -TODO + +If set to True, the window's urgency hint will be set when an +application writes the escape sequence for the terminal bell. + Default value: *False* *icon_bell* = _boolean_:: @@ -694,8 +709,11 @@ Specify the background color to use for the terminal. This option is ignored unless *use_theme_colors* is set to False. + Default value: *#000000* -*palette* = TODO:: -TODO +*palette* = _string list of colors_:: +Specify the 16-color palette to use for the terminal. +The value must be a string containing a colon-separated list of colors +in hex format. + +For example, "#000000:#cd0000:#00cd00: ... ". *bold_is_bright* = _boolean_:: If set to True, bold text will have brighter colors. + @@ -786,7 +804,8 @@ The value can be: 'control-h' for the ASCII BS character (Ctrl+H); 'escape-sequence' for the escape sequence typically bound to backspace or delete; -'automatic' for TODO. + +'automatic' for letting the terminal automatically decide the character +sequence to use. + Default value: *ascii-del* *delete_binding* = _string_:: @@ -796,7 +815,8 @@ The value can be: 'control-h' for the ASCII BS character (Ctrl+H); 'escape-sequence' for the escape sequence typically bound to backspace or delete; -'automatic' for TODO. + +'automatic' for letting the terminal automatically decide the character +sequence to use. + Default value: *escape-sequence* === Titlebar @@ -855,8 +875,40 @@ Default value: *#0076c9* // ================================================================== \\ -TODO layouts section? -TODO plugins section? +== layouts +The *layouts* section contains all the saved layouts. Each layout should +be its own subsection with a header in the format *\[[name]]*. + +Each object in a layout is a named sub-sub-section with various +properties. + +*type* = _string_:: +Can be any of: 'Window', 'Notebook', 'HPaned', 'VPaned', 'Terminal'. + +*parent* = _string_:: +Specify which object is the parent of the component being defined. +All objects, except those of type Window, must specify a parent. + +This is an example of a *layouts* section containing only the layout +named "default". + +---- +[layouts] + [[default]] + [[[window0]]] + type = Window + parent = "" + [[[child1]]] + type = Terminal + parent = window0 +---- + +// ================================================================== \\ + +== plugins +Terminator plugins can add their own configuration to the config file, +and it will appear as a subsection. Please refer to the documentation of +individual plugins for more information. == SEE ALSO *terminator*(1), http://www.voidspace.org.uk/python/configobj.html From 20ddb134905d3849fcde93bd1d043ff626e1d4d4 Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 22 Apr 2023 14:41:19 +0200 Subject: [PATCH 079/101] terminator_config: add description to all remaining settings + reword some descriptions + fix the link to ConfigObj's documentation --- doc/terminator_config.adoc | 86 ++++++++++++++++++++++---------------- 1 file changed, 49 insertions(+), 37 deletions(-) diff --git a/doc/terminator_config.adoc b/doc/terminator_config.adoc index 3fef4b234..bcca88ffc 100644 --- a/doc/terminator_config.adoc +++ b/doc/terminator_config.adoc @@ -2,7 +2,7 @@ :doctype: manpage :manmanual: Manual for Terminator :mansource: Terminator -:revdate: 2023-04-21 +:revdate: 2023-04-22 :docdate: {revdate} == NAME @@ -64,10 +64,10 @@ These are the options Terminator currently supports in the *window_state* = _string_:: Control how the Terminator window opens. -'normal' means it opens normally. -'maximise' means it opens in a maximised state. -'fullscreen' means it opens in a fullscreen state. -'hidden' means it stays hidden. + +'normal' to open normally. +'maximise' to open in a maximised state. +'fullscreen' to open in a fullscreen state. +'hidden' to stay hidden. + Default value: *normal* *always_on_top* = _boolean_:: @@ -171,15 +171,16 @@ not get sent. + Default value: *True* *clear_select_on_copy* = _boolean_:: -TODO + +If set to True, text selection will be cleared after copying using the +*copy* keybinding. + Default value: *False* // --- Terminal appearance --- *handle_size* = _integer_:: Specify the width of the separator between terminals. -Anything outside the range 0-20 (inclusive) will be ignored and use your -default theme value. + +Anything outside the range 0-20 (inclusive) will be ignored and the +default theme value will be used instead. + Default value: *1* *inactive_color_offset* = _float_:: @@ -217,7 +218,8 @@ Terminator process for each invocation. + Default value: *True* *extra_styling* = _boolean_:: -TODO + +If set to True, Terminator may load an additional CSS styling file, +depending on the theme. + Default value: *True* *broadcast_default* = _string_:: @@ -485,15 +487,15 @@ Open the Preferences window and show the Keybindings tab. + Default value: *K* *copy*:: -Copy the selected text to the clipboard. + +Copy the selected text to the Clipboard. + Default value: *C* *paste*:: -Paste the current contents of the clipboard. + +Paste the current contents of the Clipboard. + Default value: *V* *paste_selection*:: -TODO +Paste the current contents of the Primary Selection. *toggle_scrollbar*:: Toggle the scrollbar. + @@ -572,7 +574,8 @@ If set to True, text in the terminal can displayed in bold. + Default value: *True* *copy_on_selection* = _boolean_:: -TODO + +If set to True, text selections will be automatically copied to the +Clipboard, in addition to being copied to the Primary Selection. + Default value: *False* *disable_mousewheel_zoom* = _boolean_:: @@ -580,7 +583,12 @@ If set to True, Ctrl+mouse_wheel will not zoom or unzoom the terminal. + Default value: *False* *word_chars* = _string_:: -TODO + +Specify the characters that will be considered part of a single word +when selecting text by word. +Hyphen and alphanumerics do not need to be specified. +Ranges can be given, e.g. "A-Z". + +For example, if *word_chars* = "," then "foo,bar" is considered a single +word. + Default value: **-,./?%&#:_** *mouse_autohide* = _boolean_:: @@ -630,7 +638,9 @@ Can be any of: 'block', 'underline', 'ibeam'. + Default value: *block* *cursor_color_default* = _boolean_:: -TODO + +If set to True, the background and foreground colors of the terminal +will be used as foreground and background colors for the cursor, +respectively. + Default value: *True* *cursor_fg_color* = _color string_:: @@ -670,7 +680,9 @@ Default value: *False* === Command *login_shell* = _boolean_:: -TODO + +If set to True, the terminal will run the default shell (or the command +specified by *custom_command*) as a login shell. +This means the first argument passed to the shell/command will be '-l'. + Default value: *False* *use_custom_command* = _boolean_:: @@ -684,11 +696,11 @@ This option is ignored unless *use_custom_command* is set to True. *exit_action* = _string_:: Specify the action to perform when the terminal is closed. -'close' means the terminal will be removed. -'restart' means the shell (or the command specified in *custom_command*) -will be restarted. -'hold' means the terminal will be kept open, even if the process in it -has terminated. + +'close' to remove the terminal. +'restart' to restart the shell (or the command specified by +*custom_command*). +'hold' to keep the terminal open, even if the process in it has +terminated. + Default value: *close* === Colors @@ -728,15 +740,16 @@ This option is ignored unless *background_type* is set to 'transparent' or 'image'. + Default value: *0.5* -// TODO background_type needs improvements *background_type* = _string_:: Specify what type of background the terminal will have. -'solid' means the background will be a solid (opaque) color. -'transparent' means the background will be a transparent color, with its -transparency being the value of *background_darkness*. -'image' means the background will be an image, whose path is the value -of *background_image*; the background color will be drawn on top of it, -with its transparency being the value of *background_darkness*. + +'solid' for a solid (opaque) background. +'transparent' for a transparent background. +'image' for a background image. + +If this is set to 'transparent', the transparency of the background will +be the value of *background_darkness*. +If this is set to 'image', the image specified by *background_image* +will be the background; the background color will then be drawn on top +of it, with a transparency specified by *background_darkness*. + Default value: *solid* *background_image* = _path string_:: @@ -745,13 +758,13 @@ This option is ignored unless *background_type* is set to 'image'. *background_image_mode* = _string_:: Specify how the background image will be drawn. -'stretch_and_fill' means the image will fill the terminal entirely, -without necessarily maintaining aspect ratio. -'scale_and_fit' means the image will fit inside the terminal, eventually -leaving blank bars, while maintaining aspect ratio. -'scale_and_crop' means the image will fill the terminal entirely, -eventually getting cropped, while maintaining aspect ratio. -'tiling' means the image will be repeated as to fill the terminal. +'stretch_and_fill' to fill the terminal entirely, without necessarily +maintaining aspect ratio. +'scale_and_fit' to fit the image inside the terminal, eventually leaving +blank bars, while maintaining aspect ratio. +'scale_and_crop' to fill the terminal entirely, eventually cropping the +image, while maintaining aspect ratio. +'tiling' to repeat the image as to fill the terminal. This option is ignored unless *background_type* is set to 'image'. + Default value: *stretch_and_fill* @@ -911,5 +924,4 @@ and it will appear as a subsection. Please refer to the documentation of individual plugins for more information. == SEE ALSO -*terminator*(1), http://www.voidspace.org.uk/python/configobj.html -// this link might be dead +*terminator*(1), https://configobj.readthedocs.io/ From f68f288c331af0996a98066cb874c9f84a352d5d Mon Sep 17 00:00:00 2001 From: Vulcalien Date: Sat, 22 Apr 2023 14:50:45 +0200 Subject: [PATCH 080/101] Update terminator_config.5 This file is now compiled from 'terminator_config.adoc' --- doc/terminator_config.5 | 1842 ++++++++++++++++++++++++++++----------- 1 file changed, 1337 insertions(+), 505 deletions(-) diff --git a/doc/terminator_config.5 b/doc/terminator_config.5 index 8a9b2b4ed..04b1e084e 100644 --- a/doc/terminator_config.5 +++ b/doc/terminator_config.5 @@ -1,528 +1,1360 @@ -.TH "TERMINATOR_CONFIG" "5" "Feb 22, 2008" "Nicolas Valcarcel " "" +'\" t +.\" Title: terminator_config +.\" Author: [see the "AUTHOR(S)" section] +.\" Generator: Asciidoctor 2.0.18 +.\" Date: 2023-04-22 +.\" Manual: Manual for Terminator +.\" Source: Terminator +.\" Language: English +.\" +.TH "TERMINATOR_CONFIG" "5" "2023-04-22" "Terminator" "Manual for Terminator" +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.ss \n[.ss] 0 +.nh +.ad l +.de URL +\fI\\$2\fP <\\$1>\\$3 +.. +.als MTO URL +.if \n[.g] \{\ +. mso www.tmac +. am URL +. ad l +. . +. am MTO +. ad l +. . +. LINKSTYLE blue R < > +.\} .SH "NAME" -~/.config/terminator/config \- the config file for Terminator terminal emulator. +terminator_config \- the config file for Terminator terminal emulator .SH "DESCRIPTION" -This manual page documents briefly the -.B Terminator -config file. Terminator manages its configuration file via the ConfigObj library to combine flexibility with clear, human editable files. As of version 0.90, Terminator offers a full GUI preferences editor which automatically saves its config file so you don't need to write a config file by hand. -.PP +.sp +This file contains the configuration for \fBterminator\fP(1). +Terminator manages its configuration file via the ConfigObj library to +combine flexibility with clear, human editable files. +.br +Terminator offers a full GUI preferences editor which automatically +saves its config file so you don\(cqt need to write a config file by hand. .SH "FILE LOCATION" -Normally the config file will be ~/.config/terminator/config, but it may be overridden with $XDG_CONFIG_HOME (in which case it will be $XDG_CONFIG_HOME/terminator/config) +.sp +Normally the config file will be \fB~/.config/terminator/config\fP, but it +may be overridden with \fB$XDG_CONFIG_HOME\fP (in which case it will be +\fB$XDG_CONFIG_HOME/terminator/config\fP). .SH "FILE FORMAT" +.sp This is what a Terminator config file should look like: +.sp +.if n .RS 4 +.nf +.fam C +# This is a comment +[global_config] + focus = system - # This is a comment - [global_config] - focus = system +[keybindings] + full_screen = F11 - [keybindings] - full_screen = F11 - - [profiles] - [[default]] - font = Fixed 10 - background_color = "#000000" # A comment - foreground_color = "#FFFFFF" # Note that hex colour values must be quoted - scrollback_lines = '500' #More comment. Single quotes are valid too - cursor_blink = True - custom_command = "echo \\"foo#bar\\"" #Final comment - this will work as expected. +[profiles] + [[default]] + font = Fixed 10 + background_color = "#000000" # A comment + foreground_color = "#FFFFFF" # Note that hex colour values must be quoted + scrollback_lines = \*(Aq500\*(Aq #More comment. Single quotes are valid too + cursor_blink = True + custom_command = "echo \(rs"foo#bar\(rs"" #Final comment \- this will work as expected. -Below are the individual sections that can exist in the config file: +[layouts] + [[default]] + [[[window0]]] + type = Window + parent = "" + [[[child1]]] + type = Terminal + parent = window0 -.SH "global_config" -These are the options Terminator currently supports in the global_config section: -.TP -.B dbus -Control whether or not Terminator will load its DBus server. When this server is loaded, running Terminator multiple times will cause the first Terminator process to open additional windows. If this configuration item is set to False, or the python dbus module is unavailable, running Terminator multiple times will run a separate Terminator process for each invocation. -Default value: \fBTrue\fR -.TP -.B focus -Control how focus is given to terminals. 'click' means the focus only moves to a terminal after you click in it. 'sloppy' means the focus will follow the mouse pointer. 'system' means the focus will match that used by a GNOME window manager. -Default value: \fBclick\fR -.TP -.B handle_size -Controls the width of the separator between terminals. Anything outside the range 0-20 (inclusive) will be ignored and use your default theme value. -Default value: \fB-1\fR -.TP -.B geometry_hinting -If True the window will resize in step with font sizes, if False it will follow pixels -Default value: \fBFalse\fR -.TP -.B window_state -When set to 'normal' the Terminator window opens normally. 'maximise' opens the window in a maximised state, 'fullscreen' in a fullscreen state and 'hidden' will make it not shown by default. -Default value: \fBnormal\fR -.TP -.B borderless \fR(boolean) -Controls whether the Terminator window will be started without window borders -Default value: \fBFalse\fR -.TP -.B tab_position -Defines where tabs are placed. Can be any of: top, left, right, bottom. -If this is set to "hidden", the tab bar will not be shown. Note that hiding the tab bar is very confusing and not recommended. -Default value: \fBtop\fR -.TP -.B broadcast_default -Defines default broadcast behavior. Can be any of: all, group, off. -Default value: \fBgroup\fR -.TP -.B close_button_on_tab \fR(boolean) +[plugins] +.fam +.fi +.if n .RE +.SH "GLOBAL_CONFIG" +.sp +These are the options Terminator currently supports in the +\fBglobal_config\fP section. +.SS "Window Behavior & Appearance" +.sp +\fBwindow_state\fP = \fIstring\fP +.RS 4 +Control how the Terminator window opens. +\*(Aqnormal\*(Aq to open normally. +\*(Aqmaximise\*(Aq to open in a maximised state. +\*(Aqfullscreen\*(Aq to open in a fullscreen state. +\*(Aqhidden\*(Aq to stay hidden. +.br +Default value: \fBnormal\fP +.RE +.sp +\fBalways_on_top\fP = \fIboolean\fP +.RS 4 +If set to True, the window will always stay on top of other windows. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBsticky\fP = \fIboolean\fP +.RS 4 +If set to True, the window will be visible on all workspaces. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBhide_on_lose_focus\fP = \fIboolean\fP +.RS 4 +If set to True, the window will be hidden when focus is lost. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBhide_from_taskbar\fP = \fIboolean\fP +.RS 4 +If set to True, the window will be hidden from the taskbar. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBgeometry_hinting\fP = \fIboolean\fP +.RS 4 +If set to True, the window will resize in step with font sizes. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBsuppress_multiple_term_dialog\fP = \fIboolean\fP +.RS 4 +If set to True, Terminator will ask for confirmation when closing +multiple terminals. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBborderless\fP = \fIboolean\fP +.RS 4 +If set to True, the window will be started without window borders. +.br +Default value: \fBFalse\fP +.RE +.SS "Tab Behavior & Appearance" +.sp +\fBtab_position\fP = \fIstring\fP +.RS 4 +Specify where tabs are placed. +Can be any of: \*(Aqtop\*(Aq, \*(Aqleft\*(Aq, \*(Aqright\*(Aq, \*(Aqbottom\*(Aq, \*(Aqhidden\*(Aq. +If set to \*(Aqhidden\*(Aq, the tab bar will not be shown. Hiding the tab is not +recommended, as it can be very confusing. +.br +Default value: \fBtop\fP +.RE +.sp +\fBclose_button_on_tab\fP = \fIboolean\fP +.RS 4 If set to True, tabs will have a close button on them. -Default value: \fBTrue\fR -.TP -.B hide_tabbar \fR(boolean) -If set to True, the tab bar will be hidden. This means there will be no visual indication of either how many tabs there are, or which one you are on. Be warned that this can be very confusing and hard to use. -.B NOTE: THIS OPTION IS DEPRECATED, USE tab_position INSTEAD -Default value: \fBFalse\fR -.TP -.B scroll_tabbar \fR(boolean) -If set to True, the tab bar will not fill the width of the window. The titlebars of the tabs will only take as much space as is necessary for the text they contain. Except, that is, if the tabs no longer fit the width of the window - in that case scroll buttons will appear to move through the tabs. -Default value: \fBFalse\fR -.TP -.B try_posix_regexp \fR(boolean) -If set to True, URL matching regexps will try to use POSIX style first, and fall back on GNU style on failure. If you are on Linux but URL matches don't work, try setting this to True. If you are not on Linux, but you get VTE warnings on startup saying "Error compiling regular expression", set this to False to silence them (they are otherwise harmless). -Default value: \fBFalse\fR on Linux, \fBTrue\fR otherwise. -.TP -.B use_custom_url_handler \fR(boolean) -If set to True, URL handling will be given over entirely to the program specified by 'custom_url_handler'. -Default value: \fBFalse\fR -.TP -.B custom_url_handler \fR(string) -Path to a program which accepts a URI as an argument and does something relevant with it. This option is ignored unless 'use_custom_url_handler' is set to True. -Default value: unset -.TP -.B disable_real_transparency \fR(string) -If this is set to True, Terminator will never try to use 'real' transparency if your windowing environment supports it. Instead it will use 'fake' transparency where a background image is shown, but other windows are not. -Default value: False -.TP -.B title_transmit_fg_color -Sets the colour of the text shown in the titlebar of the active terminal. -Default value: \fB'#FFFFFF'\fR -.TP -.B title_transmit_bg_color -Sets the colour of the background of the titlebar in the active terminal. -Default value: \fB'#C80003'\fR -.TP -.B title_receive_fg_color -Sets the colour of the text shown in the titlebar of any terminal that \fBwill\fR receive input from the active terminal. -Default value: \fB'#FFFFFF'\fR -.TP -.B title_receive_bg_color -Sets the colour of the background of the titlebar of any terminal that \fBwill\fR receive input from the active terminal. -Default value: \fB'#0076C9'\fR -.TP -.B title_inactive_fg_color -Sets the colour of the text shown in the titlebar of any terminal that will \fBnot\fR receive input from the active terminal. -Default value: \fB'#000000'\fR -.TP -.B title_inactive_bg_color -Sets the colour of the background of the titlebar of any terminal that will \fBnot\fR receive input from the active terminal. -Default value: \fB'#C0BEBF'\fR -.TP -.B title_use_system_font \fR(boolean) -Whether or not to use the GNOME default proportional font for titlebars. -Default value: \fBTrue\fR -.TP -.B title_font \fR(string) -An Pango font name. Examples are "Sans 12" or "Monospace Bold 14". -Default value: \fB"Sans 9"\fR -.TP -.B inactive_color_offset -Controls how much to reduce the colour values of fonts in terminals that do not have focus. It is a simple multiplication -factor. A font colour that was RGB(200,200,200) with an inactive_color_offset of 0.5 would set inactive terminals to -RGB(100,100,100). -.TP -.B always_split_with_profile -Controls whether splits/tabs will continue to use the profile of their peer terminal. If set to False, they will always use -the default profile. -Default value: \fBFalse\fR -.TP -.B putty_paste_style \fR(boolean) -If set to True, right-click will paste the Primary selection, middle-click will popup the context menu. -Default value: \fBFalse\fR -.TP -.B smart_copy \fR(boolean) -If set to True, and there is no selection, the shortcut is allowed to pass through. This is useful for overloading Ctrl-C to copy a selection, or send the SIGINT to the current process if there is no selection. If False the shortcut does not pass through at all, and the SIGINT does not get sent. -Default value: \fBTrue\fR -.TP -.B enabled_plugins -A list of plugins which should be loaded by default. All other plugin classes will be ignored. The default value includes two -plugins related to Launchpad, which are enabled by default to provide continuity with earlier releases where these were the -only substantial plugins available, and all plugins were loaded by default. -Default value: \fB"LaunchpadBugURLHandler, LaunchpadCodeURLHandler"\fR - -.SH keybindings -These are the options Terminator currently supports in the keybindings section: -.TP -.B zoom_in -Make font one unit larger. -Default value: \fBplus\fR -.TP -.B zoom_out -Make font one unit smaller. -Default value: \fBminus\fR -.TP -.B zoom_normal -Return font to pre-configured size. -Default value: \fB0\fR -.TP -.B new_tab -Open a new tab. -Default value: \fBT\fR -.TP -.B cycle_next -Cycle forwards through the tabs. -Default value: \fBTab\fR -.TP -.B cycle_prev -Cycle backwards through the tabs. -Default value: \fBTab\fR -.B go_next -Move cursor focus to the next tab. -Default value: \fBN\fR -.TP -.B go_prev -Move cursor focus to the previous tab. -Default value: \fBP\fR -.TP -.B go_up -Move cursor focus to the terminal above. -Default value: \fBUp\fR -.TP -.B go_down -Move cursor focus to the terminal below. -Default value: \fBDown\fR -.TP -.B go_left -Move cursor focus to the terminal to the left. -Default value: \fBLeft\fR -.TP -.B go_right -Move cursor focus to the terminal to the right. -Default value: \fBRight\fR -.TP -.B rotate_cw -Rotate terminals clockwise. -Default value: \fBR\fR -.TP -.B rotate_ccw -Rotate terminals counter-clockwise. -Default value: \fBR\fR -.TP -.B split_horiz +.br +Default value: \fBTrue\fP +.RE +.sp +\fBscroll_tabbar\fP = \fIboolean\fP +.RS 4 +If set to True, the tab bar will not fill the width of the window. +The titlebars of the tabs will only take as much space as is necessary +for the text they contain. Except, that is, if the tabs no longer fit +the width of the window \- in that case scroll buttons will appear to +move through the tabs. +.br +Default value: \fBFalse\fP +.RE +.SS "Terminal Behavior & Appearance" +.sp +\fBfocus\fP = \fIstring\fP +.RS 4 +Specify how focus is given to terminals. +\*(Aqclick\*(Aq means the focus only moves to a terminal after you click in it. +\*(Aqsloppy\*(Aq means the focus will follow the mouse pointer. +\*(Aqsystem\*(Aq means the focus will match that used by a GNOME window manager. +.br +Default value: \fBclick\fP +.RE +.sp +\fBalways_split_with_profile\fP = \fIboolean\fP +.RS 4 +Specify whether splits/tabs will continue to use the profile of their +peer terminal. If set to False, they will always use the default profile. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBlink_single_click\fP = \fIboolean\fP +.RS 4 +If set to True, clicking a link will open it even if \fBCtrl\fP is not +pressed. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBputty_paste_style\fP = \fIboolean\fP +.RS 4 +If set to True, right\-click will paste text, while middle\-click will +popup the context menu. The source for the pasted text depends on the +value of \fBputty_paste_style_source_clipboard\fP. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBputty_paste_style_source_clipboard\fP = \fIboolean\fP +.RS 4 +If set to True, the Clipboard will be used as source for pasting in +PuTTY style. Otherwise, the Primary Selection will be used. +.br +This option is ignored unless \fBputty_paste_style\fP is set to True. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBdisable_mouse_paste\fP = \fIboolean\fP +.RS 4 +If set to True, mouse pasting will be disabled. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBsmart_copy\fP = \fIboolean\fP +.RS 4 +If set to True, and there is no selection, the shortcut is allowed to +pass through. This is useful for overloading Ctrl\-C to copy a selection, +or send the SIGINT to the current process if there is no selection. +If False, the shortcut does not pass through at all, and the SIGINT does +not get sent. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBclear_select_on_copy\fP = \fIboolean\fP +.RS 4 +If set to True, text selection will be cleared after copying using the +\fBcopy\fP keybinding. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBhandle_size\fP = \fIinteger\fP +.RS 4 +Specify the width of the separator between terminals. +Anything outside the range 0\-20 (inclusive) will be ignored and the +default theme value will be used instead. +.br +Default value: \fB1\fP +.RE +.sp +\fBinactive_color_offset\fP = \fIfloat\fP +.RS 4 +Specify how much to reduce the color values of fonts in terminals that +do not have focus. +.br +Default value: \fB0.8\fP +.RE +.sp +\fBinactive_bg_color_offset\fP = \fIfloat\fP +.RS 4 +Specify how much to reduce the color values of the background in +terminals that do not have focus. +.br +Default value: \fB1.0\fP +.RE +.sp +\fBcell_width\fP = \fIfloat\fP +.RS 4 +Specify the horizontal scale of character cells in the terminal. +.br +Default value: \fB1.0\fP +.RE +.sp +\fBcell_height\fP = \fIfloat\fP +.RS 4 +Specify the vertical scale of character cells in the terminal. +.br +Default value: \fB1.0\fP +.RE +.sp +\fBtitle_at_bottom\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal\(cqs titlebar will be drawn at the bottom +instead of the top. +.br +Default value: \fBFalse\fP +.RE +.SS "Miscellaneous" +.sp +\fBdbus\fP = \fIboolean\fP +.RS 4 +Specify whether Terminator will load its DBus server. +When this server is loaded, running Terminator multiple times will cause +the first Terminator process to open additional windows. +If this configuration item is set to False, or the python dbus module is +unavailable, running Terminator multiple times will run a separate +Terminator process for each invocation. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBextra_styling\fP = \fIboolean\fP +.RS 4 +If set to True, Terminator may load an additional CSS styling file, +depending on the theme. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBbroadcast_default\fP = \fIstring\fP +.RS 4 +Specify the default broadcast behavior. +Can be any of: \*(Aqall\*(Aq, \*(Aqgroup\*(Aq, \*(Aqoff\*(Aq. +.br +Default value: \fBgroup\fP +.RE +.sp +\fBuse_custom_url_handler\fP = \fIboolean\fP +.RS 4 +If set to True, URL handling will be given over entirely to the program +specified by \*(Aqcustom_url_handler\*(Aq. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBcustom_url_handler\fP = \fIstring\fP +.RS 4 +Specify the path to a program which accepts a URI as an argument and +does something relevant with it. +This option is ignored unless \fBuse_custom_url_handler\fP is set to True. +.RE +.sp +\fBcase_sensitive\fP = \fIboolean\fP +.RS 4 +If set to True, uppercase and lowercase characters will be considered +different when searching text in the terminal. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBinvert_search\fP = \fIboolean\fP +.RS 4 +If set to True, the search direction will be inverted (bottom to top) +when searching text in the terminal. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBenabled_plugins\fP = \fIlist of strings\fP +.RS 4 +Specify which plugins will be loaded by default. All other plugin +classes will be ignored. +.br +Default value: \fB[\*(AqLaunchpadBugURLHandler\*(Aq, \*(AqLaunchpadCodeURLHandler\*(Aq, \*(AqAPTURLHandler\*(Aq]\fP +.RE +.SH "KEYBINDINGS" +.sp +These are the options Terminator currently supports in the \fBkeybindings\fP +section. +.SS "Creation & Destruction" +.sp +\fBsplit_horiz\fP +.RS 4 Split the current terminal horizontally. -Default value: \fBO\fR -.TP -.B split_vert +.br +Default value: \fBO\fP +.RE +.sp +\fBsplit_vert\fP +.RS 4 Split the current terminal vertically. -Default value: \fBE\fR -.TP -.B close_term +.br +Default value: \fBE\fP +.RE +.sp +\fBsplit_auto\fP +.RS 4 +Split the current terminal automatically, along the longer side. +.br +Default value: \fBA\fP +.RE +.sp +\fBnew_tab\fP +.RS 4 +Open a new tab. +.br +Default value: \fBT\fP +.RE +.sp +\fBnew_window\fP +.RS 4 +Open a new window as part of the existing process. +.br +Default value: \fBI\fP +.RE +.sp +\fBnew_terminator\fP +.RS 4 +Spawn a new Terminator process. +.br +Default value: \fBI\fP +.RE +.sp +\fBlayout_launcher\fP +.RS 4 +Open the layout launcher. +.br +Default value: \fBL\fP +.RE +.sp +\fBclose_term\fP +.RS 4 Close the current terminal. -Default value: \fBW\fR -.TP -.B copy -Copy the currently selected text to the clipboard. -Default value: \fBC\fR -.TP -.B paste -Paste the current contents of the clipboard. -Default value: \fBV\fR -.TP -.B paste_selection -Paste the current contents of the primary selection. -Default value: \fBUnbound\fR -.TP -.B toggle_scrollbar -Show/Hide the scrollbar. -Default value: \fBS\fR -.TP -.B search -Search for text in the terminal scrollback history. -Default value: \fBF\fR -.TP -.B close_window -Quit Terminator. -Default value: \fBQ\fR -.TP -.B resize_up -Move the parent dragbar upwards. -Default value: \fBUp\fR -.TP -.B resize_down -Move the parent dragbar downwards. -Default value: \fBDown\fR -.TP -.B resize_left -Move the parent dragbar left. -Default value: \fBLeft\fR -.TP -.B resize_right -Move the parent dragbar right. -Default value: \fBRight\fR -.TP -.B move_tab_right -Swap the current tab with the one to its right. -Default value: \fBPage_Down\fR -.TP -.B move_tab_left -Swap the current tab with the one to its left. -Default value: \fBPage_Up\fR -.TP -.B toggle_zoom -Zoom/Unzoom the current terminal to fill the window. -Default value: \fBX\fR -.TP -.B scaled_zoom -Zoom/Unzoom the current terminal to fill the window, and scale its font. -Default value: \fBZ\fR -.TP -.B next_tab +.br +Default value: \fBW\fP +.RE +.sp +\fBclose_window\fP +.RS 4 +Close the current window. +.br +Default value: \fBQ\fP +.RE +.SS "Navigation" +.sp +\fBcycle_next\fP +.RS 4 +Focus the next terminal. This is an alias for \fBgo_next\fP. +.br +Default value: \fBTab\fP +.RE +.sp +\fBcycle_prev\fP +.RS 4 +Focus the previous terminal. This is an alias for \fBgo_prev\fP. +.br +Default value: \fBTab\fP +.RE +.sp +\fBgo_next\fP +.RS 4 +Focus the next terminal. +.br +Default value: \fBN\fP +.RE +.sp +\fBgo_prev\fP +.RS 4 +Focus the previous terminal. +.br +Default value: \fBP\fP +.RE +.sp +\fBgo_up\fP +.RS 4 +Focus the terminal above the current one. +.br +Default value: \fBUp\fP +.RE +.sp +\fBgo_down\fP +.RS 4 +Focus the terminal below the current one. +.br +Default value: \fBDown\fP +.RE +.sp +\fBgo_left\fP +.RS 4 +Focus the terminal to the left of the current one. +.br +Default value: \fBLeft\fP +.RE +.sp +\fBgo_right\fP +.RS 4 +Focus the terminal to the right of the current one. +.br +Default value: \fBRight\fP +.RE +.sp +\fBpage_up\fP +.RS 4 +Scroll the terminal up one page. +.RE +.sp +\fBpage_down\fP +.RS 4 +Scroll the terminal down one page. +.RE +.sp +\fBpage_up_half\fP +.RS 4 +Scroll the terminal up half a page. +.RE +.sp +\fBpage_down_half\fP +.RS 4 +Scroll the terminal down half a page. +.RE +.sp +\fBline_up\fP +.RS 4 +Scroll the terminal up one line. +.RE +.sp +\fBline_down\fP +.RS 4 +Scroll the terminal down one line. +.RE +.sp +\fBnext_tab\fP +.RS 4 Move to the next tab. -Default value: \fBPage_Down\fR -.TP -.B prev_tab +.br +Default value: \fBPage_Down\fP +.RE +.sp +\fBprev_tab\fP +.RS 4 Move to the previous tab. -Default value: \fBPage_Up\fR -.TP -.B switch_to_tab_1 - switch_to_tab_10 -Keys to switch directly to the numbered tab. -Note that 1 may need to be provided as ! or similar, -depending on your keyboard layout. -Default value: \fBUnbound\fR -.TP -.B edit_window_title -Edit the current active window's title -Default value: \fBW\fR -.TP -.B edit_tab_title -Edit the currently active tab's title -Default value: \fBA\fR -.TP -.B edit_terminal_title -Edit the currently active terminal's title -Default value: \fBX\fR -.TP -.B full_screen -Toggle the window to a fullscreen window. -Default value: \fBF11\fR -.TP -.B reset +.br +Default value: \fBPage_Up\fP +.RE +.sp +\fBswitch_to_tab_1\fP, \fBswitch_to_tab_2\fP, ... \fBswitch_to_tab_10\fP +.RS 4 +Move to the \fBN\fPth tab. +Note that \fB1\fP may be provided as \fB!\fP or similar, +depending on the keyboard layout. +.RE +.SS "Organisation" +.sp +\fBresize_up\fP +.RS 4 +Move the parent dragbar up. +.br +Default value: \fBUp\fP +.RE +.sp +\fBresize_down\fP +.RS 4 +Move the parent dragbar down. +.br +Default value: \fBDown\fP +.RE +.sp +\fBresize_left\fP +.RS 4 +Move the parent dragbar left. +.br +Default value: \fBLeft\fP +.RE +.sp +\fBresize_right\fP +.RS 4 +Move the parent dragbar right. +.br +Default value: \fBRight\fP +.RE +.sp +\fBrotate_cw\fP +.RS 4 +Rotate terminals clockwise. +.br +Default value: \fBR\fP +.RE +.sp +\fBrotate_ccw\fP +.RS 4 +Rotate terminals counter+clockwise. +.br +Default value: \fBR\fP +.RE +.sp +\fBmove_tab_right\fP +.RS 4 +Move the current tab to the right by swapping position with the next +tab. +.br +Default value: \fBPage_Down\fP +.RE +.sp +\fBmove_tab_left\fP +.RS 4 +Move the current tab to the left by swapping position with the previous +tab. +.br +Default value: \fBPage_Up\fP +.RE +.SS "Focus" +.sp +\fBfull_screen\fP +.RS 4 +Toggle window to fullscreen. +.br +Default value: \fBF11\fP +.RE +.sp +\fBtoggle_zoom\fP +.RS 4 +Toggle maximisation of the current terminal. +.br +Default value: \fBX\fP +.RE +.sp +\fBscaled_zoom\fP +.RS 4 +Toggle maximisation of the current terminal and scale the font when +maximised. +.br +Default value: \fBZ\fP +.RE +.sp +\fBhide_window\fP +.RS 4 +Hide/Show all Terminator windows. +.br +Default value: \fBA\fP +.RE +.SS "Grouping & Broadcasting" +.sp +\fBcreate_group\fP +.RS 4 +Create a new group. +.RE +.sp +\fBgroup_all\fP +.RS 4 +Group all terminals together. +.br +Default value: \fBG\fP +.RE +.sp +\fBungroup_all\fP +.RS 4 +Ungroup all terminals. +.RE +.sp +\fBgroup_all_toggle\fP +.RS 4 +Toggle grouping of all terminals. +.RE +.sp +\fBgroup_win\fP +.RS 4 +Group all terminals in the current window together. +.RE +.sp +\fBungroup_win\fP +.RS 4 +Ungroup all terminals in the current window. +.br +Default value: \fBW\fP +.RE +.sp +\fBgroup_win_toggle\fP +.RS 4 +Toggle grouping of all terminals in the current window. +.RE +.sp +\fBgroup_tab\fP +.RS 4 +Group all terminals in the current tab together. +.br +Default value: \fBT\fP +.RE +.sp +\fBungroup_tab\fP +.RS 4 +Ungroup all terminals in the current tab. +.br +Default value: \fBT\fP +.RE +.sp +\fBgroup_tab_toggle\fP +.RS 4 +Toggle grouping of all terminals in the current tab. +.RE +.sp +\fBbroadcast_off\fP +.RS 4 +Turn broadcasting off. +.RE +.sp +\fBbroadcast_group\fP +.RS 4 +Broadcast to all terminals in the same group as the current terminal. +.RE +.sp +\fBbroadcast_all\fP +.RS 4 +Broadcast to all terminals. +.RE +.SS "Miscellaneous" +.sp +\fBhelp\fP +.RS 4 +Open the full HTML manual in the browser. +.br +Default value: \fBF1\fP +.RE +.sp +\fBpreferences\fP +.RS 4 +Open the Preferences window. +.RE +.sp +\fBpreferences_keybindings\fP +.RS 4 +Open the Preferences window and show the Keybindings tab. +.br +Default value: \fBK\fP +.RE +.sp +\fBcopy\fP +.RS 4 +Copy the selected text to the Clipboard. +.br +Default value: \fBC\fP +.RE +.sp +\fBpaste\fP +.RS 4 +Paste the current contents of the Clipboard. +.br +Default value: \fBV\fP +.RE +.sp +\fBpaste_selection\fP +.RS 4 +Paste the current contents of the Primary Selection. +.RE +.sp +\fBtoggle_scrollbar\fP +.RS 4 +Toggle the scrollbar. +.br +Default value: \fBS\fP +.RE +.sp +\fBsearch\fP +.RS 4 +Search for text in the terminal scrollback history. +.br +Default value: \fBF\fP +.RE +.sp +\fBreset\fP +.RS 4 Reset the terminal state. -Default value: \fBR\fR -.TP -.B reset_clear +.br +Default value: \fBR\fP +.RE +.sp +\fBreset_clear\fP +.RS 4 Reset the terminal state and clear the terminal window. -Default value: \fBG\fR -.TP -.B hide_window -Toggle visibility of the Terminator window. -Default value: \fBa\fR -.TP -.B group_all -Group all terminals together so input sent to one goes to all of them. -Default value: \fBg\fR -.TP -.B ungroup_all -Remove grouping from all terminals. -Default value: \fBG\fR -.TP -.B group_tab -Group all terminals in the current tab together so input sent to one goes to all of them. -Default value: \fBt\fR -.TP -.B ungroup_tab -Remove grouping from all terminals in the current tab. -Default value: \fBT\fR -.TP -.B new_window -Open a new Terminator window as part of the existing process. -Default value: \fBI\fR -.TP -.B new_terminator -Spawn a new instance of Terminator. -Default value: \fBi\fR - -.SH profiles -These are the options Terminator currently supports in the profiles section. -Each profile should be its own subsection with a header in the format \fB[[name]]\fR - -.B allow_bold\fR (boolean) -If true, allow applications in the terminal to make text boldface. -Default value: \fBTrue\fR -.TP -.B audible_bell\fR (boolean) -If true, make a noise when applications send the escape sequence for the terminal bell. -Default value: \fBFalse\fR -.TP -.B visible_bell\fR (boolean) -If true, flash the terminal when applications send the escape sequence for the terminal bell. -Default value: \fBFalse\fR -.TP -.B urgent_bell\fR (boolean) -If true, set the window manager "urgent" hint when applications send the escale sequence for the terminal bell. Any keypress will cancel the urgent status. -Default value: \fBFalse\fR -.TP -.B icon_bell\fR (boolean) -If true, briefly show a small icon on the terminal title bar for the terminal bell. -Default value: \fBTrue\fR -.TP -.B force_no_bell\fR (boolean) -If true, don't make a noise or flash. All terminal bells will be ignored. -Default value: \fBFalse\fR -.TP -.B use_theme_colors -If true, ignore the configured colours and use values from the theme instead. -Default value: \fBFalse\fR -.TP -.B bold_is_bright -If true, show bold text with increased brightness. If false, then text boldness can be controlled by applications independently from the text brightness. -Default value: \fBFalse\fR -.TP -.B background_color -Default colour of terminal background, as a colour specification (can be HTML-style hex digits, or a colour name such as "red"). \fBNote:\fR You may need to set \fBuse_theme_colors=False\fR to force this setting to take effect. -Default value: \fB'#000000'\fR -.TP -.B background_darkness -A value between 0.0 and 1.0 indicating how much to darken the background image. 0.0 means no darkness, 1.0 means fully dark. If the terminal is set to transparent, this setting controls how transparent it is. 0.0 means fully transparent, 1.0 means fully opaque. -Default value: \fB0.5\fR -.TP -.B background_type -Type of terminal background. May be "solid" for a solid colour or "transparent" for full transparency in compositing window managers. -Default value: \fBsolid\fR -.TP -.B backspace_binding -Sets what code the backspace key generates. Possible values are "ascii-del" for the ASCII DEL character, "control-h" for Control-H (AKA the ASCII BS character), "escape-sequence" for the escape sequence typically bound to backspace or delete. "ascii-del" is normally considered the correct setting for the Backspace key. -Default value: \fBascii\-del\fR -.TP -.B delete_binding -Sets what code the delete key generates. Possible values are "ascii-del" for the ASCII DEL character, "control-h" for Control-H (AKA the ASCII BS character), "escape-sequence" for the escape sequence typically bound to backspace or delete. "escape-sequence" is normally considered the correct setting for the Delete key. -Default value: \fBescape\-sequence\fR -.TP -.B color_scheme \fR(boolean) -If specified this sets foreground_color and background_color to pre-set values. Possible options are 'grey_on_black', 'black_on_yellow', 'black_on_white', 'white_on_black', 'green_on_black', 'orange_on_black', 'ambience', 'solarized_dark', 'solarized_light'. -Default value: \fRgrey_on_black\fR -.TP -.B cursor_blink \fR(boolean) -Controls if the cursor blinks. -Default value: \fBTrue\fR -.TP -.B cursor_color -Default colour of cursor, as a colour specification (can be HTML-style hex digits, or a colour name such as "red"). -Default value: Current value of \fBforeground_color\fR -.TP -.B cursor_shape -Default shape of cursor. Possibilities are "block", "ibeam", and "underline". -Default value: \fBblock\fR -.TP -.B term -This translates into the value that will be set for TERM in the environment of your terminals. -Default value: \fBxterm-256color\fR -.TP -.B colorterm -This translates into the value that will be set for COLORTERM in the environment of your terminals. -Default value: \fBtruecolor\fR -.TP -.B use_system_font -Whether or not to use the GNOME default monospace font for terminals. -Default value: \fBTrue\fR -.TP -.B font -An Pango font name. Examples are "Sans 12" or "Monospace Bold 14". -Default value: \fBMono 10\fR -.TP -.B foreground_color -Default colour of text in the terminal, as a colour specification (can be HTML-style hex digits, or a colour name such as "red"). \fBNote:\fR You may need to set \fBuse_theme_colors=False\fR to force this setting to take effect. -Default value: \fB'#AAAAAA'\fR -.TP -.B scrollbar_position -Where to put the terminal scrollbar. Possibilities are "left", "right", and "disabled". -Default value: \fBright\fR -.TP -.B show_titlebar -If true, a titlebar will be drawn for each terminal which shows the current title of that terminal. -Default value: \fBTrue\fR -.TP -.B scroll_background \fR(boolean) -If true, scroll the background image with the foreground text; if false, keep the image in a fixed position and scroll the text above it. -Default value: \fBTrue\fR -.TP -.B scroll_on_keystroke \fR(boolean) -If true, pressing a key jumps the scrollbar to the bottom. -Default value: \fBTrue\fR -.TP -.B scroll_on_output \fR(boolean) -If true, whenever there's new output the terminal will scroll to the bottom. -Default value: \fBFalse\fR -.TP -.B scrollback_lines -Number of scrollback lines to keep around. You can scroll back in the terminal by this number of lines; lines that don't fit in the scrollback are discarded. Warning: with large values, rewrapping on resize might be slow. -Default value: \fB500\fR -.TP -.B scrollback_infinite -If this is set to True, scrollback_lines will be ignored and VTE will keep the entire scrollback history. -Default value: \fBFalse\fR -.TP -.B focus_on_close -Sets which terminal should get the focus when another terminal is closed. Values can be "prev", "next" or "auto". -Using "auto", if the closed terminal is within a split window, the focus will be on the sibling terminal rather than another tab. -Default value: \fBauto\fR -.TP -.B exit_action -Possible values are "close" to close the terminal, and "restart" to restart the command. -Default value: \fBclose\fR -.TP -.B palette -Terminals have a 16-colour palette that applications inside the terminal can use. This is that palette, in the form of a colon-separated list of colour names. Colour names should be in hex format e.g. "#FF00FF". -.TP -.B word_chars -When selecting text by word, sequences of these characters are also considered members of single words. The hyphen and alphanumerics do not need to be specified. Ranges can be given as "A-Z". -Default value: \fB',./?%&#:_'\fR -.TP -.B mouse_autohide \fR(boolean) -Controls whether the mouse cursor should be hidden while typing. -Default value: \fBTrue\fR -.TP -.B use_custom_command \fR(boolean) -If True, the value of \fBcustom_command\fR will be used instead of the default shell. -Default value: \fBFalse\fR -.TP -.B custom_command -Command to execute instead of the default shell, if \fBuse_custom_command\fR is set to True. -Default value: Nothing -.TP -.B http_proxy -URL of an HTTP proxy to use, e.g. http://proxy.lan:3128/ -Default value: Nothing -.TP -.B encoding -Character set to use for the terminal. -Default value: \fBUTF-8\fR -.TP -.B copy_on_selection \fR(boolean) -If set to True, text selections will be automatically copied to the clipboard, in addition to being made the Primary selection. -Default value: \fBFalse\fR -.TP - -.SH layouts - -This describes the layouts section of the config file. Like with the profiles, each layout should be defined as a sub-section with a name formatted like: \fB[[name]]\fR. - -Each object in a layout is a named sub-sub-section with various properties: - +.br +Default value: \fBG\fP +.RE +.sp +\fBzoom_in\fP +.RS 4 +Increase the font size by one unit. +.br +Default value: \fBplus\fP +.RE +.sp +\fBzoom_out\fP +.RS 4 +Decrease the font size by one unit. +.br +Default value: \fBminus\fP +.RE +.sp +\fBzoom_normal\fP +.RS 4 +Restore the original font size. +.br +Default value: \fB0\fP +.RE +.sp +\fBzoom_in_all\fP +.RS 4 +Increase the font size by one unit for all terminals. +.RE +.sp +\fBzoom_out_all\fP +.RS 4 +Decrease the font size by one unit for all terminals. +.RE +.sp +\fBzoom_normal_all\fP +.RS 4 +Restore the original font size for all terminals. +.RE +.sp +\fBedit_window_title\fP +.RS 4 +Rename the current window. +.br +Default value: \fBW\fP +.RE +.sp +\fBedit_tab_title\fP +.RS 4 +Rename the current tab. +.br +Default value: \fBA\fP +.RE +.sp +\fBedit_terminal_title\fP +.RS 4 +Rename the current terminal. +.br +Default value: \fBX\fP +.RE +.sp +\fBinsert_number\fP +.RS 4 +Insert the current terminal\(cqs number, i.e. 1 to 12. +.br +Default value: \fB1\fP +.RE +.sp +\fBinsert_padded\fP +.RS 4 +Insert the current terminal\(cqs number, but zero padded, i.e. 01 to 12. +.br +Default value: \fB0\fP +.RE +.sp +\fBnext_profile\fP +.RS 4 +Switch to the next profile. +.RE +.sp +\fBprevious_profile\fP +.RS 4 +Switch to the previous profile. +.RE +.SH "PROFILES" +.sp +These are the options Terminator currently supports in the \fBprofiles\fP +section. Each profile should be its own subsection with a header in the +format \fB[[name]]\fP. +.SS "General" +.sp +\fBallow_bold\fP = \fIboolean\fP +.RS 4 +If set to True, text in the terminal can displayed in bold. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBcopy_on_selection\fP = \fIboolean\fP +.RS 4 +If set to True, text selections will be automatically copied to the +Clipboard, in addition to being copied to the Primary Selection. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBdisable_mousewheel_zoom\fP = \fIboolean\fP +.RS 4 +If set to True, Ctrl+mouse_wheel will not zoom or unzoom the terminal. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBword_chars\fP = \fIstring\fP +.RS 4 +Specify the characters that will be considered part of a single word +when selecting text by word. +Hyphen and alphanumerics do not need to be specified. +Ranges can be given, e.g. "A\-Z". +.br +For example, if \fBword_chars\fP = "," then "foo,bar" is considered a single +word. +.br +Default value: \fB\-,./?%&#:_\fP +.RE +.sp +\fBmouse_autohide\fP = \fIboolean\fP +.RS 4 +If set to True, the mouse pointer will be hidden when typing. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBterm\fP = \fIstring\fP +.RS 4 +Specify the value Terminator will assign to the \*(AqTERM\*(Aq environment +variable. +.br +Default value: \fBxterm\-256color\fP +.RE +.sp +\fBcolorterm\fP = \fIstring\fP +.RS 4 +Specify the value Terminator will assign to the \*(AqCOLORTERM\*(Aq environment +variable. +.br +Default value: \fBtruecolor\fP +.RE +.sp +\fBsplit_to_group\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal created by splitting will be inserted in +the current terminal\(cqs group. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBautoclean_groups\fP = \fIboolean\fP +.RS 4 +If set to True, empty groups will be removed. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBuse_system_font\fP = \fIboolean\fP +.RS 4 +If set to True, the system default font will be used for text in the +terminal. Otherwise, the value of \fBfont\fP will be used. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBfont\fP = \fIstring\fP +.RS 4 +Specify which font to use for text in the terminal. +This option is ignored unless \fBuse_system_font\fP is set to False. +.br +Default value: \fBMono 10\fP +.RE +.sp +\fBcursor_blink\fP = \fIboolean\fP +.RS 4 +If set to True, the cursor will blink when not typing. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBcursor_shape\fP = \fIstring\fP +.RS 4 +Specify the shape of the cursor. +Can be any of: \*(Aqblock\*(Aq, \*(Aqunderline\*(Aq, \*(Aqibeam\*(Aq. +.br +Default value: \fBblock\fP +.RE +.sp +\fBcursor_color_default\fP = \fIboolean\fP +.RS 4 +If set to True, the background and foreground colors of the terminal +will be used as foreground and background colors for the cursor, +respectively. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBcursor_fg_color\fP = \fIcolor string\fP +.RS 4 +Specify the foreground color to use for the cursor. +This option is ignored unless \fBcursor_color_default\fP is set to False. +.RE +.sp +\fBcursor_bg_color\fP = \fIcolor string\fP +.RS 4 +Specify the background color to use for the cursor. +This option is ignored unless \fBcursor_color_default\fP is set to False. +.RE +.sp +\fBaudible_bell\fP = \fIboolean\fP +.RS 4 +If set to True, a sound will be played when an application writes the +escape sequence for the terminal bell. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBvisible_bell\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal will flash when an application writes the +escape sequence for the terminal bell. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBurgent_bell\fP = \fIboolean\fP +.RS 4 +If set to True, the window\(cqs urgency hint will be set when an +application writes the escape sequence for the terminal bell. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBicon_bell\fP = \fIboolean\fP +.RS 4 +If set to True, a small icon will be shown on the terminal titlebar when +an application writes the escape sequence for the terminal bell. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBforce_no_bell\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal bell will be completely disabled. +.br +Default value: \fBFalse\fP +.RE +.SS "Command" +.sp +\fBlogin_shell\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal will run the default shell (or the command +specified by \fBcustom_command\fP) as a login shell. +This means the first argument passed to the shell/command will be \*(Aq\-l\*(Aq. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBuse_custom_command\fP = \fIboolean\fP +.RS 4 +If set to True, the value of \fBcustom_command\fP will be used instead of +the default shell. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBcustom_command\fP = \fIstring\fP +.RS 4 +Specify the command to execute instead of the default shell. +This option is ignored unless \fBuse_custom_command\fP is set to True. +.RE +.sp +\fBexit_action\fP = \fIstring\fP +.RS 4 +Specify the action to perform when the terminal is closed. +\*(Aqclose\*(Aq to remove the terminal. +\*(Aqrestart\*(Aq to restart the shell (or the command specified by +\fBcustom_command\fP). +\*(Aqhold\*(Aq to keep the terminal open, even if the process in it has +terminated. +.br +Default value: \fBclose\fP +.RE +.SS "Colors" +.sp +\fBuse_theme_colors\fP = \fIboolean\fP +.RS 4 +If set to True, the theme\(cqs foreground and background colors will be +used for the terminal. Otherwise, the values of \fBforeground_color\fP and +\fBbackground_color\fP will be used. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBforeground_color\fP = \fIcolor string\fP +.RS 4 +Specify the foreground color to use for the terminal. +This option is ignored unless \fBuse_theme_colors\fP is set to False. +.br +Default value: \fB#AAAAAA\fP +.RE +.sp +\fBbackground_color\fP = \fIcolor string\fP +.RS 4 +Specify the background color to use for the terminal. +This option is ignored unless \fBuse_theme_colors\fP is set to False. +.br +Default value: \fB#000000\fP +.RE +.sp +\fBpalette\fP = \fIstring list of colors\fP +.RS 4 +Specify the 16\-color palette to use for the terminal. +The value must be a string containing a colon\-separated list of colors +in hex format. +.br +For example, "#000000:#cd0000:#00cd00: ... ". +.RE +.sp +\fBbold_is_bright\fP = \fIboolean\fP +.RS 4 +If set to True, bold text will have brighter colors. +.br +Default value: \fBFalse\fP +.RE +.SS "Background" +.sp +\fBbackground_darkness\fP = \fIfloat\fP +.RS 4 +Specify the transparency of the background color. +The value must be between 0.0 and 1.0. +This option is ignored unless \fBbackground_type\fP is set to \*(Aqtransparent\*(Aq +or \*(Aqimage\*(Aq. +.br +Default value: \fB0.5\fP +.RE +.sp +\fBbackground_type\fP = \fIstring\fP +.RS 4 +Specify what type of background the terminal will have. +\*(Aqsolid\*(Aq for a solid (opaque) background. +\*(Aqtransparent\*(Aq for a transparent background. +\*(Aqimage\*(Aq for a background image. +.br +If this is set to \*(Aqtransparent\*(Aq, the transparency of the background will +be the value of \fBbackground_darkness\fP. +If this is set to \*(Aqimage\*(Aq, the image specified by \fBbackground_image\fP +will be the background; the background color will then be drawn on top +of it, with a transparency specified by \fBbackground_darkness\fP. +.br +Default value: \fBsolid\fP +.RE +.sp +\fBbackground_image\fP = \fIpath string\fP +.RS 4 +Specify the path to an image that will be used as background. +This option is ignored unless \fBbackground_type\fP is set to \*(Aqimage\*(Aq. +.RE +.sp +\fBbackground_image_mode\fP = \fIstring\fP +.RS 4 +Specify how the background image will be drawn. +\*(Aqstretch_and_fill\*(Aq to fill the terminal entirely, without necessarily +maintaining aspect ratio. +\*(Aqscale_and_fit\*(Aq to fit the image inside the terminal, eventually leaving +blank bars, while maintaining aspect ratio. +\*(Aqscale_and_crop\*(Aq to fill the terminal entirely, eventually cropping the +image, while maintaining aspect ratio. +\*(Aqtiling\*(Aq to repeat the image as to fill the terminal. +This option is ignored unless \fBbackground_type\fP is set to \*(Aqimage\*(Aq. +.br +Default value: \fBstretch_and_fill\fP +.RE +.sp +\fBbackground_image_align_horiz\fP = \fIstring\fP +.RS 4 +Specify the horizontal alignment of the background image. +Can be any of: \*(Aqleft\*(Aq, \*(Aqcenter\*(Aq, \*(Aqright\*(Aq. +This option is ignored unless \fBbackground_type\fP is set to \*(Aqimage\*(Aq. +.br +Default value: \fBcenter\fP +.RE +.sp +\fBbackground_image_align_vert\fP = \fIstring\fP +.RS 4 +Specify the vertical alignment of the background image. +Can be any of: \*(Aqtop\*(Aq, \*(Aqmiddle\*(Aq, \*(Aqbottom\*(Aq. +This option is ignored unless \fBbackground_type\fP is set to \*(Aqimage\*(Aq. +.br +Default value: \fBmiddle\fP +.RE +.SS "Scrolling" +.sp +\fBscrollbar_position\fP = \fIstring\fP +.RS 4 +Specify where the terminal scrollbar is put. +Can be any of: \*(Aqleft\*(Aq, \*(Aqright\*(Aq, \*(Aqhidden\*(Aq. +.br +Default value: \fBright\fP +.RE +.sp +\fBscroll_on_output\fP = \fIboolean\fP +.RS 4 +If set to True, the terminall will scroll to the bottom when an +application writes text to it. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBscroll_on_keystroke\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal will scroll to the bottom when typing. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBscrollback_infinite\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal will keep the entire scrollback history. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBscrollback_lines\fP = \fIinteger\fP +.RS 4 +Specify how many lines of scrollback history will be kept by the +terminal. Lines that don\(cqt fit in the scrollback history will be +discarted. Note that setting large values can slow down rewrapping and +resizing. +This option is ignored unless \fBscrollback_infinite\fP is set to False. +.br +Default value: \fB500\fP +.RE +.SS "Compatibility" +.sp +\fBbackspace_binding\fP = \fIstring\fP +.RS 4 +Specify what code will be generated by the backspace key. +The value can be: +\*(Aqascii\-del\*(Aq for the ASCII DEL character; +\*(Aqcontrol\-h\*(Aq for the ASCII BS character (Ctrl+H); +\*(Aqescape\-sequence\*(Aq for the escape sequence typically bound to backspace +or delete; +\*(Aqautomatic\*(Aq for letting the terminal automatically decide the character +sequence to use. +.br +Default value: \fBascii\-del\fP +.RE +.sp +\fBdelete_binding\fP = \fIstring\fP +.RS 4 +Specify what code will be generated by the delete key. +The value can be: +\*(Aqascii\-del\*(Aq for the ASCII DEL character; +\*(Aqcontrol\-h\*(Aq for the ASCII BS character (Ctrl+H); +\*(Aqescape\-sequence\*(Aq for the escape sequence typically bound to backspace +or delete; +\*(Aqautomatic\*(Aq for letting the terminal automatically decide the character +sequence to use. +.br +Default value: \fBescape\-sequence\fP +.RE +.SS "Titlebar" +.sp +\fBshow_titlebar\fP = \fIboolean\fP +.RS 4 +If set to True, the terminal will have a titlebar showing the current +title of that terminal. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBtitle_hide_sizetext\fP = \fIboolean\fP +.RS 4 +If set to True, the size of the terminal will not be written on its +titlebar. +.br +Default value: \fBFalse\fP +.RE +.sp +\fBtitle_use_system_font\fP = \fIboolean\fP +.RS 4 +If set to True, the system default font will be used for text in the +terminal\(cqs titlebar. Otherwise, the value of \fBtitle_font\fP will be used. +.br +Default value: \fBTrue\fP +.RE +.sp +\fBtitle_font\fP = \fIstring\fP +.RS 4 +Specify which font to use for text in the terminal\(cqs titlebar. +This option is ignored unless \fBtitle_use_system_font\fP is set to False. +.br +Default value: \fBSans 9\fP +.RE +.sp +\fBtitle_transmit_fg_color\fP = \fIcolor string\fP +.RS 4 +Specify the foreground color to use for the terminal\(cqs titlebar in case +the terminal is focused. +.br +Default value: \fB#ffffff\fP +.RE +.sp +\fBtitle_transmit_bg_color\fP = \fIcolor string\fP +.RS 4 +Specify the background color to use for the terminal\(cqs titlebar in case +the terminal is focused. +.br +Default value: \fB#c80003\fP +.RE +.sp +\fBtitle_inactive_fg_color\fP = \fIcolor string\fP +.RS 4 +Specify the foreground color to use for the terminal\(cqs titlebar in case +the terminal is unfocused. +.br +Default value: \fB#000000\fP +.RE +.sp +\fBtitle_inactive_bg_color\fP = \fIcolor string\fP +.RS 4 +Specify the background color to use for the terminal\(cqs titlebar in case +the terminal is unfocused. +.br +Default value: \fB#c0bebf\fP +.RE +.sp +\fBtitle_receive_fg_color\fP = \fIcolor string\fP +.RS 4 +Specify the foreground color to use for the terminal\(cqs titlebar in case +the terminal is in a group and is receiving input while unfocused. +.br +Default value: \fB#ffffff\fP +.RE +.sp +\fBtitle_receive_bg_color\fP = \fIcolor string\fP +.RS 4 +Specify the background color to use for the terminal\(cqs titlebar in case +the terminal is in a group and is receiving input while unfocused. +.br +Default value: \fB#0076c9\fP +.RE +.SH "LAYOUTS" +.sp +The \fBlayouts\fP section contains all the saved layouts. Each layout should +be its own subsection with a header in the format \fB[[name]]\fP. +.sp +Each object in a layout is a named sub\-sub\-section with various +properties. +.sp +\fBtype\fP = \fIstring\fP +.RS 4 +Can be any of: \*(AqWindow\*(Aq, \*(AqNotebook\*(Aq, \*(AqHPaned\*(Aq, \*(AqVPaned\*(Aq, \*(AqTerminal\*(Aq. +.RE +.sp +\fBparent\fP = \fIstring\fP +.RS 4 +Specify which object is the parent of the component being defined. +All objects, except those of type Window, must specify a parent. +.RE +.sp +This is an example of a \fBlayouts\fP section containing only the layout +named "default". +.sp +.if n .RS 4 +.nf +.fam C [layouts] [[default]] - [[window0]] + [[[window0]]] type = Window - [[child1]] + parent = "" + [[[child1]]] type = Terminal parent = window0 - -Window objects may not have a parent attribute. \fBEvery\fR other object must specify a parent. This is how the structure of the window is determined. - -.SH plugins - -Terminator plugins can add their own configuration to the config file, and will appear as a sub-section. Please refer to the documentation of individual plugins for more information. - +.fam +.fi +.if n .RE +.SH "PLUGINS" +.sp +Terminator plugins can add their own configuration to the config file, +and it will appear as a subsection. Please refer to the documentation of +individual plugins for more information. .SH "SEE ALSO" -.TP -\fBterminator\fP(1), http://www.voidspace.org.uk/python/configobj.html +.sp +\fBterminator\fP(1), \c +.URL "https://configobj.readthedocs.io/" "" "" \ No newline at end of file From cd04443e292c596e1abb497d92b400eff157f648 Mon Sep 17 00:00:00 2001 From: x000zh Date: Sun, 4 Jun 2023 19:13:37 +0800 Subject: [PATCH 081/101] add new tab after current tab option --- terminatorlib/config.py | 2 ++ terminatorlib/notebook.py | 2 ++ terminatorlib/preferences.glade | 19 ++++++++++++++++++- terminatorlib/prefseditor.py | 11 ++++++++++- 4 files changed, 32 insertions(+), 2 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index dcd982ab5..7a7d10f8e 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -119,6 +119,8 @@ 'link_single_click' : False, 'title_at_bottom' : False, 'detachable_tabs' : True, + + 'new_tab_after_current_tab': False, }, 'keybindings': { 'zoom_in' : 'plus', diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index a6e302988..9cb6bd489 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -306,6 +306,8 @@ def newtab(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=N if metadata and 'tabnum' in metadata: tabpos = metadata['tabnum'] + elif self.config['new_tab_after_current_tab'] == True: + tabpos = self.get_current_page() + 1 else: tabpos = -1 diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 857553831..fd18a16da 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -1245,7 +1245,7 @@ True False - 6 + 8 12 @@ -1330,6 +1330,23 @@ 2 + + + New tab after current tab + False + True + True + False + 0 + True + + + + 0 + 4 + 2 + + True diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index 15ffef88d..82fad666d 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -356,7 +356,11 @@ def set_values(self): # title bar at bottom widget = guiget('title_at_bottom_checkbutton') widget.set_active(self.config['title_at_bottom']) - + + # new tab after current tab + widget = guiget('new_tab_after_current_checkbutton') + widget.set_active(self.config['new_tab_after_current_tab']) + #Always split with profile widget = guiget('always_split_with_profile') widget.set_active(self.config['always_split_with_profile']) @@ -888,6 +892,11 @@ def on_title_at_bottom_checkbutton_toggled(self, widget): self.config['title_at_bottom'] = widget.get_active() self.config.save() + def on_new_tab_after_current_checkbutton_toggled(self, widget): + """New tab after current tab """ + self.config['new_tab_after_current_tab'] = widget.get_active() + self.config.save() + def on_always_split_with_profile_toggled(self, widget): """Always split with profile setting changed""" self.config['always_split_with_profile'] = widget.get_active() From 928a3dc5ec036868f2191b3b1c386f498bff9cac Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Fri, 9 Jun 2023 23:16:34 -0400 Subject: [PATCH 082/101] Revert "modify terminator separater size setting in gui to start from 1" This reverts commit c8cd50ba9a7c1b4ecac83c2336122d4133cfabe2. --- terminatorlib/config.py | 2 +- terminatorlib/preferences.glade | 4 ++-- terminatorlib/prefseditor.py | 2 -- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/terminatorlib/config.py b/terminatorlib/config.py index 0d2390243..adfd0ad46 100644 --- a/terminatorlib/config.py +++ b/terminatorlib/config.py @@ -84,7 +84,7 @@ 'global_config': { 'dbus' : True, 'focus' : 'click', - 'handle_size' : 1, + 'handle_size' : -1, 'geometry_hinting' : False, 'window_state' : 'normal', 'borderless' : False, diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade index 04a8adce1..466d302ad 100644 --- a/terminatorlib/preferences.glade +++ b/terminatorlib/preferences.glade @@ -353,9 +353,9 @@ - 1 + -1 20 - 1 + -1 1 2 diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py index f805c8c6d..c5bf7c0c0 100755 --- a/terminatorlib/prefseditor.py +++ b/terminatorlib/prefseditor.py @@ -1381,8 +1381,6 @@ def on_handlesize_value_changed(self, widget): value = int(value) # Cast to int. if value > 20: value = 20 - if value < 1: - value = 1 self.config['handle_size'] = value self.config.save() guiget = self.builder.get_object From ea97c21871f6f805dd4836a67e9e5dc53fe67b92 Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:52:30 +0000 Subject: [PATCH 083/101] Translate po/terminator.pot in hr 100% translated source file: 'po/terminator.pot' on 'hr'. --- po/hr.po | 267 +++++++++++++++---------------------------------------- 1 file changed, 70 insertions(+), 197 deletions(-) diff --git a/po/hr.po b/po/hr.po index e8c0fb5dd..7427a547a 100644 --- a/po/hr.po +++ b/po/hr.po @@ -2,28 +2,26 @@ # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. -# +# # Translators: # Gnome Terminator , 2020 -# Marko Dzidic , 2020 # Markus Frosch , 2021 -# +# Marko Dzidic , 2023 +# #, fuzzy msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-22 00:51+0100\n" +"POT-Creation-Date: 2022-10-19 09:29-0400\n" "PO-Revision-Date: 2020-04-22 08:11+0000\n" -"Last-Translator: Markus Frosch , 2021\n" -"Language-Team: Croatian (https://www.transifex.com/terminator/teams/109338/" -"hr/)\n" -"Language: hr\n" +"Last-Translator: Marko Dzidic , 2023\n" +"Language-Team: Croatian (https://app.transifex.com/terminator/teams/109338/hr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" -"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" +"Language: hr\n" +"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" #. Command uuid req. Description #: ../remotinator.py:39 @@ -48,7 +46,7 @@ msgstr "Dobij popis svih terminala" #: ../remotinator.py:44 msgid "Get the uuid of the current focused terminal" -msgstr "" +msgstr "Dobij UUID trenutnog terminala u fokusu" #: ../remotinator.py:45 msgid "Get the UUID of a parent window" @@ -68,23 +66,23 @@ msgstr "Dobij naslov nadređene kartice" #: ../remotinator.py:49 msgid "Set the title of a parent tab" -msgstr "" +msgstr "Postavite naslov glavne kartice" #: ../remotinator.py:50 msgid "Set the background image" -msgstr "" +msgstr "Postavite pozadinsku sliku" #: ../remotinator.py:51 msgid "Set the background image for all terminals" -msgstr "" +msgstr "Postavite pozadinsku sliku za sve terminale" #: ../remotinator.py:52 msgid "Switch current terminal profile" -msgstr "" +msgstr "Promijeni trenutni profil terminala" #: ../remotinator.py:53 msgid "Switch profile of all currently running terminals" -msgstr "" +msgstr "Promijeni profil svih trenutno pokrenutih terminala" #: ../remotinator.py:70 #, python-format @@ -111,23 +109,24 @@ msgstr "UUID terminala, kad nije u TERMINATOR_UUID varijabli okruženja" #: ../remotinator.py:80 msgid "Profile name to switch to" -msgstr "" +msgstr "Naziv profila za prebacivanje" #: ../remotinator.py:83 msgid "File to pass to command" -msgstr "" +msgstr "Datoteka za prosljeđivanje naredbi" #: ../remotinator.py:86 msgid "Command to run in new terminal" -msgstr "" +msgstr "Naredba za pokretanje u novom terminalu" #: ../remotinator.py:89 msgid "Tab name to set. Only used with \"set_tab_title\" command." msgstr "" +"Naziv kartice za postavljanje. Koristi se samo s naredbom \"set_tab_title\"." #: ../remotinator.py:92 msgid "Tab name to set." -msgstr "" +msgstr "Naziv kartice za postavljanje." #: ../data/terminator.desktop.in.h:1 ../data/terminator.appdata.xml.in.h:1 #: ../terminatorlib/plugins/activitywatch.py:83 @@ -149,11 +148,11 @@ msgstr "Robotska budućnost terminala" msgid "" "A power-user tool for arranging terminals. It is inspired by programs such " "as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging " -"terminals in grids (tabs is the most common default method, which Terminator " -"also supports)." +"terminals in grids (tabs is the most common default method, which Terminator" +" also supports)." msgstr "" -"Profesionalni korisnički alat za raspoređivanje terminala, slično programima " -"poput gnome-multi-term, quadkonsole, itd., a glavna ideja je pločasto " +"Profesionalni korisnički alat za raspoređivanje terminala, slično programima" +" poput gnome-multi-term, quadkonsole, itd., a glavna ideja je pločasto " "raspoređivanje terminala (kartice su najraširenija metoda, koju Terminator " "također podržava)." @@ -304,8 +303,8 @@ msgid "" "Use the rest of the command line as a command to execute inside the " "terminal, and its arguments" msgstr "" -"Koristi ostatak naredbenog retka kao naredbu za izvršavanje unutar terminala " -"i njezine argumente" +"Koristi ostatak naredbenog retka kao naredbu za izvršavanje unutar terminala" +" i njezine argumente" #: ../terminatorlib/optionparse.py:69 msgid "Specify a config file" @@ -361,15 +360,15 @@ msgstr "Ako je Terminator već pokrenut, jednostavno otvori novu karticu" #: ../terminatorlib/optionparse.py:98 msgid "If Terminator is already running, just unhide all hidden windows" -msgstr "" +msgstr "Ako je Terminator već pokrenut, samo otkrijte sve skrivene prozore" #: ../terminatorlib/optionparse.py:100 msgid "List all profiles" -msgstr "" +msgstr "Popis svih profila" #: ../terminatorlib/optionparse.py:102 msgid "List all layouts" -msgstr "" +msgstr "Popis svih izgleda" #: ../terminatorlib/plugins/activitywatch.py:54 msgid "Watch for _activity" @@ -487,7 +486,7 @@ msgstr "Naziv *%s* već postoji" #: ../terminatorlib/plugins/dir_open.py:26 msgid "Open current directory" -msgstr "" +msgstr "Otvori trenutni direktorij" #: ../terminatorlib/plugins/logger.py:21 #: ../terminatorlib/plugins/terminalshot.py:21 @@ -757,15 +756,15 @@ msgstr "Međuspremnik" #: ../terminatorlib/preferences.glade.h:62 msgid "Clear selection on copy" -msgstr "" +msgstr "Obriši obilježeno nakon kopiranja" #: ../terminatorlib/preferences.glade.h:63 msgid "Open links with a single click (instead of Ctrl-left click)" -msgstr "" +msgstr "Otvaranje poveznica jednim klikom (umjesto Ctrl-lijevi klik)" #: ../terminatorlib/preferences.glade.h:64 msgid "Disable mouse paste" -msgstr "" +msgstr "Onemogući lijepljenje mišom" #: ../terminatorlib/preferences.glade.h:65 msgid "Custom URL handler:" @@ -793,11 +792,11 @@ msgstr "Dodatno stiliziranje (ovisno o temi)" #: ../terminatorlib/preferences.glade.h:71 msgid "Cell Height:" -msgstr "" +msgstr "Visina ćelije:" #: ../terminatorlib/preferences.glade.h:72 msgid "Cell Width:" -msgstr "" +msgstr "Širina ćelije:" #: ../terminatorlib/preferences.glade.h:73 msgid "Tab position:" @@ -869,11 +868,11 @@ msgstr "Titranje" #: ../terminatorlib/preferences.glade.h:90 msgid "Use default colors" -msgstr "" +msgstr "Koristi zadane boje" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "" +msgstr "Prednja strana:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" @@ -933,11 +932,11 @@ msgstr "Ugrađene she_me:" #: ../terminatorlib/preferences.glade.h:107 msgid "_Foreground:" -msgstr "" +msgstr "_Prvi plan:" #: ../terminatorlib/preferences.glade.h:108 msgid "_Background:" -msgstr "" +msgstr "_Boja pozadine:" #: ../terminatorlib/preferences.glade.h:109 msgid "Palette" @@ -969,11 +968,11 @@ msgstr "_Prozirna pozadina" #: ../terminatorlib/preferences.glade.h:116 msgid "Background Image" -msgstr "" +msgstr "Pozadinska slika" #: ../terminatorlib/preferences.glade.h:117 msgid "Background Image File:" -msgstr "" +msgstr "Datoteka pozadinske slike:" #: ../terminatorlib/preferences.glade.h:118 msgid "Choose file" @@ -981,7 +980,7 @@ msgstr "Odaberi datoteku" #: ../terminatorlib/preferences.glade.h:119 msgid "S_hade background:" -msgstr "" +msgstr "Zasjeniti pozadinu:" #: ../terminatorlib/preferences.glade.h:120 msgid "None" @@ -1027,8 +1026,8 @@ msgstr "Klizanje" msgid "" "Note: These options may cause some applications to behave " "incorrectly. They are only here to allow you to work around certain " -"applications and operating systems that expect different terminal behavior." +"applications and operating systems that expect different terminal " +"behavior." msgstr "" "Napomena: Ove opcije mogu prouzrokovati neispravan rad " "nekih programa. Ovdje se nalaze samo kako bi se zaobišli problemi s " @@ -1077,7 +1076,7 @@ msgstr "Odaberi font za traku naslova" #: ../terminatorlib/preferences.glade.h:141 msgid "Titlebar" -msgstr "" +msgstr "Naslovna traka" #: ../terminatorlib/preferences.glade.h:142 #: ../terminatorlib/terminal_popup_menu.py:204 @@ -1130,30 +1129,17 @@ msgstr "Priključci" #: ../terminatorlib/preferences.glade.h:158 msgid "Version: 2.1.1" -msgstr "" +msgstr "Verzija: 2.1.1" #: ../terminatorlib/preferences.glade.h:159 msgid "" -"The goal of this project is to produce a useful tool for arranging " -"terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, " -"etc. in that the main focus is arranging terminals in grids (tabs is the " -"most common default method, which Terminator also supports).\n" +"The goal of this project is to produce a useful tool for arranging terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging terminals in grids (tabs is the most common default method, which Terminator also supports).\n" "\n" -"Much of the behavior of Terminator is based on GNOME Terminal, and we are " -"adding more features from that as time goes by, but we also want to extend " -"out in different directions with useful features for sysadmins and other " -"users. If you have any suggestions, please file wishlist bugs! (see left for " -"the Development link)" +"Much of the behavior of Terminator is based on GNOME Terminal, and we are adding more features from that as time goes by, but we also want to extend out in different directions with useful features for sysadmins and other users. If you have any suggestions, please file wishlist bugs! (see left for the Development link)" msgstr "" -"Cilj ovog projekta je proizvesti koristan alat za raspoređivanje terminala, " -"slično programima poput gnome-multi-term, quadkonsole, itd., a glavna ideja " -"je pločasto raspoređivanje terminala (kartice su najraširenija standardna " -"metoda, koju Terminator također podržava).\n" +"Cilj ovog projekta je proizvesti koristan alat za raspoređivanje terminala, slično programima poput gnome-multi-term, quadkonsole, itd., a glavna ideja je pločasto raspoređivanje terminala (kartice su najraširenija standardna metoda, koju Terminator također podržava).\n" "\n" -"Terminator se uveliko temelji se na GNOME Terminalu i s vremenom dodajemo " -"daljnje njegove funkcije, ali ga također razvijamo s raznim dodatnim " -"korisnim funkcijama za administratore sustava i za ostale korisnike. " -"Prijedlozi se mogu dodati u popis želja! (vidi lijevo poveznicu „Razvoj”)" +"Terminator se uveliko temelji se na GNOME Terminalu i s vremenom dodajemo daljnje njegove funkcije, ali ga također razvijamo s raznim dodatnim korisnim funkcijama za administratore sustava i za ostale korisnike. Prijedlozi se mogu dodati u popis želja! (vidi lijevo poveznicu „Razvoj”)" #: ../terminatorlib/preferences.glade.h:162 msgid "The Manual" @@ -1162,12 +1148,10 @@ msgstr "Priručnik" #: ../terminatorlib/preferences.glade.h:163 msgid "" "Development\n" -"Bugs / " -"Enhancements" +"Bugs / Enhancements" msgstr "" "Razvoj\n" -"Greške i " -"poboljšanja" +"Greške i poboljšanja" #: ../terminatorlib/preferences.glade.h:165 msgid "About" @@ -1187,15 +1171,15 @@ msgstr "Vrati izvornu veličinu fonta" #: ../terminatorlib/prefseditor.py:107 msgid "Increase font size on all terminals" -msgstr "" +msgstr "Povećaj veličinu fonta na svim terminalima" #: ../terminatorlib/prefseditor.py:108 msgid "Decrease font size on all terminals" -msgstr "" +msgstr "Smanji veličinu fonta na svim terminalima" #: ../terminatorlib/prefseditor.py:109 msgid "Restore original font size on all terminals" -msgstr "" +msgstr "Vrati izvornu veličinu fonta na svim terminalima" #: ../terminatorlib/prefseditor.py:110 msgid "Create a new tab" @@ -1255,7 +1239,7 @@ msgstr "Umetni iz međuspremnika" #: ../terminatorlib/prefseditor.py:126 msgid "Paste primary selection" -msgstr "" +msgstr "Umetni primarni odabir" #: ../terminatorlib/prefseditor.py:127 msgid "Show/Hide the scrollbar" @@ -1407,15 +1391,15 @@ msgstr "Razdvoji sve terminale" #: ../terminatorlib/prefseditor.py:164 msgid "Group terminals in window" -msgstr "" +msgstr "Grupiraj terminale u prozoru" #: ../terminatorlib/prefseditor.py:165 msgid "Group/Ungroup terminals in window" -msgstr "" +msgstr "Grupiraj/razgrupiraj terminale u prozoru" #: ../terminatorlib/prefseditor.py:166 msgid "Ungroup terminals in window" -msgstr "" +msgstr "Razgrupiraj terminale u prozoru" #: ../terminatorlib/prefseditor.py:167 msgid "Group terminals in tab" @@ -1489,11 +1473,11 @@ msgstr "Otvori prozor postavki" msgid "Open the manual" msgstr "Otvori priručnik" -#: ../terminatorlib/prefseditor.py:1370 +#: ../terminatorlib/prefseditor.py:1366 msgid "New Profile" msgstr "Novi profil" -#: ../terminatorlib/prefseditor.py:1413 ../terminatorlib/prefseditor.py:1418 +#: ../terminatorlib/prefseditor.py:1409 ../terminatorlib/prefseditor.py:1414 msgid "New Layout" msgstr "Novi raspored" @@ -1540,7 +1524,7 @@ msgstr "_Umetni" #: ../terminatorlib/terminal_popup_menu.py:112 msgid "Set W_indow Title" -msgstr "" +msgstr "Postav_ite naslov prozora" #: ../terminatorlib/terminal_popup_menu.py:117 msgid "Split H_orizontally" @@ -1580,7 +1564,7 @@ msgstr "Grupiranje" #: ../terminatorlib/terminal_popup_menu.py:186 msgid "Relaunch Command" -msgstr "" +msgstr "Ponovo pokreni naredbu" #: ../terminatorlib/terminal_popup_menu.py:191 msgid "Show _scrollbar" @@ -1605,11 +1589,11 @@ msgstr "Ukloni grupu %s" #: ../terminatorlib/terminal.py:512 msgid "G_roup all in window" -msgstr "" +msgstr "G_rupirajte sve u prozoru" #: ../terminatorlib/terminal.py:517 msgid "Ungro_up all in window" -msgstr "" +msgstr "Razgr_upiraj sve u prozoru" #: ../terminatorlib/terminal.py:522 msgid "G_roup all in tab" @@ -1656,25 +1640,25 @@ msgstr "_Umetni broj terminala" msgid "Insert _padded terminal number" msgstr "Umetni _broj terminala s predstavljenom nulom" -#: ../terminatorlib/terminal.py:1490 +#: ../terminatorlib/terminal.py:1492 msgid "Unable to find a shell" msgstr "Nije moguće pronaći ljusku" -#: ../terminatorlib/terminal.py:1521 +#: ../terminatorlib/terminal.py:1546 msgid "Unable to start shell:" msgstr "Nije moguće pokrenuti ljusku:" -#: ../terminatorlib/terminal.py:1975 +#: ../terminatorlib/terminal.py:2000 msgid "Rename Window" msgstr "Preimenuj prozor" -#: ../terminatorlib/terminal.py:1983 +#: ../terminatorlib/terminal.py:2008 msgid "Enter a new title for the Terminator window..." msgstr "Upiši novi naslov za prozor Terminatora …" #: ../terminatorlib/titlebar.py:112 msgid "[INACTIVE: Right-Click for Relaunch option] " -msgstr "" +msgstr "[NEAKTIVNO: Desni klik za opciju ponovnog pokretanja]" #: ../terminatorlib/titlebar.py:258 msgid "Alpha" @@ -1779,120 +1763,9 @@ msgstr "prozor" #: ../terminatorlib/window.py:773 #, python-format msgid "Window group %s" -msgstr "" +msgstr "Grupa prozora %s" #: ../terminatorlib/window.py:799 #, python-format msgid "Tab %d" msgstr "Kartica %d" - -#~ msgid "Current Locale" -#~ msgstr "Trenutačni jezik" - -#~ msgid "Western" -#~ msgstr "Zapadni" - -#~ msgid "Central European" -#~ msgstr "Srednjoeuropski" - -#~ msgid "South European" -#~ msgstr "Južnoeuropski" - -#~ msgid "Baltic" -#~ msgstr "Baltički" - -#~ msgid "Cyrillic" -#~ msgstr "Ćirilični" - -#~ msgid "Arabic" -#~ msgstr "Arapski" - -#~ msgid "Greek" -#~ msgstr "Grčki" - -#~ msgid "Hebrew Visual" -#~ msgstr "Vizualni hebrejski" - -#~ msgid "Hebrew" -#~ msgstr "Hebrejski" - -#~ msgid "Turkish" -#~ msgstr "Turski" - -#~ msgid "Nordic" -#~ msgstr "Nordijski" - -#~ msgid "Celtic" -#~ msgstr "Keltski" - -#~ msgid "Romanian" -#~ msgstr "Rumunjski" - -#~ msgid "Unicode" -#~ msgstr "Unikod" - -#~ msgid "Armenian" -#~ msgstr "Armenski" - -#~ msgid "Chinese Traditional" -#~ msgstr "Kineski tradicionalni" - -#~ msgid "Cyrillic/Russian" -#~ msgstr "Ćirilica/Ruski" - -#~ msgid "Japanese" -#~ msgstr "Japanski" - -#~ msgid "Korean" -#~ msgstr "Korejski" - -#~ msgid "Chinese Simplified" -#~ msgstr "Kineski pojednostavljeni" - -#~ msgid "Georgian" -#~ msgstr "Gruzijski" - -#~ msgid "Cyrillic/Ukrainian" -#~ msgstr "Ćirilica/Ukrajinski" - -#~ msgid "Croatian" -#~ msgstr "Hrvatski" - -#~ msgid "Hindi" -#~ msgstr "Hindski" - -#~ msgid "Persian" -#~ msgstr "Perzijski" - -#~ msgid "Gujarati" -#~ msgstr "Gudžaratski" - -#~ msgid "Gurmukhi" -#~ msgstr "Gurmuki" - -#~ msgid "Icelandic" -#~ msgstr "Islandski" - -#~ msgid "Vietnamese" -#~ msgstr "Vijetnamski" - -#~ msgid "Thai" -#~ msgstr "Tajlandski" - -#~ msgid "Line Height:" -#~ msgstr "Prored:" - -#~ msgid "Encoding:" -#~ msgstr "Kodiranje:" - -#~ msgid "Encodings" -#~ msgstr "Kodiranja" - -#~ msgid "Default" -#~ msgstr "Standardno" - -#~ msgid "User defined" -#~ msgstr "Korisnički određeno" - -#~ msgid "Other Encodings" -#~ msgstr "Ostala kodiranja" From 685aa75170847b54b53e76e5cbd35029d7229d52 Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:52:51 +0000 Subject: [PATCH 084/101] Translate po/terminator.pot in hr 100% translated source file: 'po/terminator.pot' on 'hr'. --- po/hr.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/po/hr.po b/po/hr.po index 7427a547a..425c1860d 100644 --- a/po/hr.po +++ b/po/hr.po @@ -872,7 +872,7 @@ msgstr "Koristi zadane boje" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "Prednja strana:" +msgstr "Prvi plan:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" From 635e5338ec79b0a3c38763535873ae76dd4dabba Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:53:15 +0000 Subject: [PATCH 085/101] Translate po/terminator.pot in hr 100% translated source file: 'po/terminator.pot' on 'hr'. --- po/hr.po | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/po/hr.po b/po/hr.po index 425c1860d..c2c6f47b6 100644 --- a/po/hr.po +++ b/po/hr.po @@ -872,7 +872,7 @@ msgstr "Koristi zadane boje" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "Prvi plan:" +msgstr "Prednji plan:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" @@ -932,7 +932,7 @@ msgstr "Ugrađene she_me:" #: ../terminatorlib/preferences.glade.h:107 msgid "_Foreground:" -msgstr "_Prvi plan:" +msgstr "_Prednji plan:" #: ../terminatorlib/preferences.glade.h:108 msgid "_Background:" From 64bccd27b57922d2186497826a900390054fa62c Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:55:16 +0000 Subject: [PATCH 086/101] Translate po/terminator.pot in hr 100% translated source file: 'po/terminator.pot' on 'hr'. --- po/hr.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/po/hr.po b/po/hr.po index c2c6f47b6..644805961 100644 --- a/po/hr.po +++ b/po/hr.po @@ -764,7 +764,7 @@ msgstr "Otvaranje poveznica jednim klikom (umjesto Ctrl-lijevi klik)" #: ../terminatorlib/preferences.glade.h:64 msgid "Disable mouse paste" -msgstr "Onemogući lijepljenje mišom" +msgstr "Onemogući umetanje mišom" #: ../terminatorlib/preferences.glade.h:65 msgid "Custom URL handler:" From 1a4921b26204bfe654012b8fec6483eca2c4e573 Mon Sep 17 00:00:00 2001 From: Matt Rose Date: Sat, 17 Jun 2023 21:31:00 -0400 Subject: [PATCH 087/101] Alter get_text_range call based on VTE version In vte 0.72 there was a regression that caused Vte.Terminal.get_text_range() to fail to return the text requested However, in the same version, there was a new call introduced that does retrieve the text, so if I detect a vte minor version above 72, I call that instead. --- terminatorlib/plugins/logger.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/terminatorlib/plugins/logger.py b/terminatorlib/plugins/logger.py index 8b3c721e4..c2bb1545f 100644 --- a/terminatorlib/plugins/logger.py +++ b/terminatorlib/plugins/logger.py @@ -6,7 +6,7 @@ import os import sys -from gi.repository import Gtk +from gi.repository import Gtk,Vte import terminatorlib.plugin as plugin from terminatorlib.translation import _ @@ -19,6 +19,7 @@ class Logger(plugin.MenuItem): dialog_action = Gtk.FileChooserAction.SAVE dialog_buttons = (_("_Cancel"), Gtk.ResponseType.CANCEL, _("_Save"), Gtk.ResponseType.OK) + vte_version = Vte.get_minor_version() def __init__(self): plugin.MenuItem.__init__(self) @@ -40,8 +41,11 @@ def callback(self, menuitems, menu, terminal): def write_content(self, terminal, row_start, col_start, row_end, col_end): """ Final function to write a file """ - content = terminal.get_text_range(row_start, col_start, row_end, col_end, + if self.vte_version < 72: + content = terminal.get_text_range(row_start, col_start, row_end, col_end, lambda *a: True) + else: + content = terminal.get_text_range_format(Vte.Format.TEXT,row_start, col_start, row_end, col_end) content = content[0] fd = self.loggers[terminal]["fd"] # Don't write the last char which is always '\n' From d0e366ff8d4b6350463d23b40d2505ea18906e3c Mon Sep 17 00:00:00 2001 From: Tyler Hardin Date: Wed, 21 Jun 2023 13:14:20 -0400 Subject: [PATCH 088/101] Enable sixel support in VTE if it's available. --- terminatorlib/terminal.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 914d69d7b..9dccf7b33 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -155,6 +155,9 @@ def __init__(self): self.composite_support = True dbg('composite_support: %s' % self.composite_support) + if hasattr(self.vte, "set_enable_sixel"): + self.vte.set_enable_sixel(True) + self.vte.show() self.update_url_matches() From e61fc1ce607a91607ff6671c27f5ee8b2d538ac7 Mon Sep 17 00:00:00 2001 From: Julien Dusser Date: Thu, 20 Jul 2023 17:08:44 +0200 Subject: [PATCH 089/101] Add command line option --toggle-visibility Useful for Wayland where global shortcuts are not available. Use window manager to bind "terminator --toggle-visibilty" to a keyboard shortcut. --- doc/terminator.1 | 12 ++++++++++-- doc/terminator.adoc | 10 ++++++++-- terminator | 3 +++ terminatorlib/ipc.py | 10 ++++++++++ terminatorlib/optionparse.py | 2 ++ terminatorlib/window.py | 1 + 6 files changed, 34 insertions(+), 4 deletions(-) diff --git a/doc/terminator.1 b/doc/terminator.1 index a224b5307..ccd18b999 100644 --- a/doc/terminator.1 +++ b/doc/terminator.1 @@ -171,6 +171,13 @@ be displayed. If this is specified and Terminator is already running, DBus will be used to spawn a new tab in the first Terminator window. .RE +.sp +\fB\-\-toggle\-visibility\fP +.RS 4 +If this is specified and Terminator is already running, DBus will be +used to toggle Terminator window visibility. Usable under Wayland to +replace hide keyboad shortcut. +.RE .SH "KEYBINDINGS" .sp The following default keybindings can be used to control Terminator. @@ -347,8 +354,9 @@ of the current one (zoom). .sp \fBCtrl+Shift+Alt+A\fP .RS 4 -Hide the initial window. Note that this is a global binding, and can -only be bound once. +Hide the initial window. Note that this is a X11 global binding, and can +only be bound once. On Wayland use window manager keyboard shortcuts to +call \fBterminator \-\-toggle\-visibility\fP. .RE .SS "Grouping & Broadcasting" .sp diff --git a/doc/terminator.adoc b/doc/terminator.adoc index 92408f131..25ba6c1c8 100644 --- a/doc/terminator.adoc +++ b/doc/terminator.adoc @@ -108,6 +108,11 @@ be displayed. If this is specified and Terminator is already running, DBus will be used to spawn a new tab in the first Terminator window. +*--toggle-visibility*:: +If this is specified and Terminator is already running, DBus will be +used to toggle Terminator window visibility. Usable under Wayland to +replace hide keyboad shortcut. + == KEYBINDINGS The following default keybindings can be used to control Terminator. Most of these keybindings can be changed in the Preferences. @@ -221,8 +226,9 @@ Toggle between showing all terminals and only showing a scaled version of the current one (zoom). *Ctrl+Shift+Alt+A*:: -Hide the initial window. Note that this is a global binding, and can -only be bound once. +Hide the initial window. Note that this is a X11 global binding, and can +only be bound once. On Wayland use window manager keyboard shortcuts to +call *terminator --toggle-visibility*. === Grouping & Broadcasting The following items relate to grouping and broadcasting. diff --git a/terminator b/terminator index dcc2fb563..c7ab0e787 100755 --- a/terminator +++ b/terminator @@ -102,6 +102,9 @@ if __name__ == '__main__': if OPTIONS.new_tab: dbg('Requesting a new tab') ipc.new_tab_cmdline(optionslist) + elif OPTIONS.toggle_visibility: + dbg('requesting to toggle windows visibility') + ipc.toggle_visibility_cmdline(optionslist) elif OPTIONS.unhide: print('requesting to unhide windows') ipc.unhide_cmdline(optionslist) diff --git a/terminatorlib/ipc.py b/terminatorlib/ipc.py index 4303f28ff..5f30ad99d 100644 --- a/terminatorlib/ipc.py +++ b/terminatorlib/ipc.py @@ -100,6 +100,12 @@ def new_tab_cmdline(self, options=dbus.Dictionary()): window = self.terminator.get_windows()[0] window.tab_new() + @dbus.service.method(BUS_NAME, in_signature='a{ss}') + def toggle_visibility_cmdline(self,options=dbus.Dictionary): + dbg('toggle_visibility_cmdline') + for window in self.terminator.get_windows(): + window.on_hide_window() + @dbus.service.method(BUS_NAME, in_signature='a{ss}') def unhide_cmdline(self,options=dbus.Dictionary): dbg('unhide_cmdline') @@ -343,6 +349,10 @@ def new_tab_cmdline(session, options): """Call the dbus method to open a new tab in the first window""" session.new_tab_cmdline(options) +@with_proxy +def toggle_visibility_cmdline(session,options): + session.toggle_visibility_cmdline(options) + @with_proxy def unhide_cmdline(session,options): session.unhide_cmdline(options) diff --git a/terminatorlib/optionparse.py b/terminatorlib/optionparse.py index 631e5d3f2..da8d0a970 100644 --- a/terminatorlib/optionparse.py +++ b/terminatorlib/optionparse.py @@ -96,6 +96,8 @@ def parse_options(): help=_('Comma separated list of methods to limit debugging to')) parser.add_argument('--new-tab', action='store_true', dest='new_tab', help=_('If Terminator is already running, just open a new tab')) + parser.add_argument('--toggle-visibility', action='store_true', dest='toggle_visibility', + help=_('If Terminator is already running, toggle windows visibility')) parser.add_argument('--unhide', action='store_true', dest='unhide', help=_('If Terminator is already running, just unhide all hidden windows')) parser.add_argument('--list-profiles', action='store_true', dest='list_profiles', diff --git a/terminatorlib/window.py b/terminatorlib/window.py index 694b768ba..9cf7f688c 100644 --- a/terminatorlib/window.py +++ b/terminatorlib/window.py @@ -103,6 +103,7 @@ def __init__(self): self.apply_icon(icon_to_apply) self.pending_set_rough_geometry_hint = False + self.hidefunc = self.hide def do_get_property(self, prop): """Handle gobject getting a property""" From 7173bb1c380b23fb435a67584721f5e241f16584 Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Fri, 21 Jul 2023 08:54:43 +0000 Subject: [PATCH 090/101] Translate po/terminator.pot in zh_CN 100% translated source file: 'po/terminator.pot' on 'zh_CN'. --- po/zh_CN.po | 279 +++++++++++++++------------------------------------- 1 file changed, 82 insertions(+), 197 deletions(-) diff --git a/po/zh_CN.po b/po/zh_CN.po index 8c7850646..815a61e7b 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -2,24 +2,24 @@ # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. -# +# # Translators: # Gnome Terminator , 2020 -# +# Mony Xie , 2023 +# #, fuzzy msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-22 00:51+0100\n" +"POT-Creation-Date: 2022-10-19 09:29-0400\n" "PO-Revision-Date: 2020-04-22 08:11+0000\n" -"Last-Translator: Gnome Terminator , 2020\n" -"Language-Team: Chinese (China) (https://www.transifex.com/terminator/" -"teams/109338/zh_CN/)\n" -"Language: zh_CN\n" +"Last-Translator: Mony Xie , 2023\n" +"Language-Team: Chinese (China) (https://app.transifex.com/terminator/teams/109338/zh_CN/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Language: zh_CN\n" "Plural-Forms: nplurals=1; plural=0;\n" #. Command uuid req. Description @@ -45,7 +45,7 @@ msgstr "获取所有终端的列表" #: ../remotinator.py:44 msgid "Get the uuid of the current focused terminal" -msgstr "" +msgstr "获取当前聚焦终端的 UUID" #: ../remotinator.py:45 msgid "Get the UUID of a parent window" @@ -65,23 +65,23 @@ msgstr "获取父标签页的标题" #: ../remotinator.py:49 msgid "Set the title of a parent tab" -msgstr "" +msgstr "设置父级标签页的标题" #: ../remotinator.py:50 msgid "Set the background image" -msgstr "" +msgstr "设置背景图片" #: ../remotinator.py:51 msgid "Set the background image for all terminals" -msgstr "" +msgstr "设置所有终端的背景图片" #: ../remotinator.py:52 msgid "Switch current terminal profile" -msgstr "" +msgstr "切换当前终端配置" #: ../remotinator.py:53 msgid "Switch profile of all currently running terminals" -msgstr "" +msgstr "切换当前所有运行中终端的配置" #: ../remotinator.py:70 #, python-format @@ -108,23 +108,23 @@ msgstr "终端UUID如果未设置TERMINATOR_UUID环境变量" #: ../remotinator.py:80 msgid "Profile name to switch to" -msgstr "" +msgstr "要切换到的配置名" #: ../remotinator.py:83 msgid "File to pass to command" -msgstr "" +msgstr "要传递给命令的文件" #: ../remotinator.py:86 msgid "Command to run in new terminal" -msgstr "" +msgstr "要在新终端中运行的命令" #: ../remotinator.py:89 msgid "Tab name to set. Only used with \"set_tab_title\" command." -msgstr "" +msgstr "要设置的标签页名。仅与“set_tab_title”命令一起使用。" #: ../remotinator.py:92 msgid "Tab name to set." -msgstr "" +msgstr "要设置的标签页名。" #: ../data/terminator.desktop.in.h:1 ../data/terminator.appdata.xml.in.h:1 #: ../terminatorlib/plugins/activitywatch.py:83 @@ -146,9 +146,11 @@ msgstr "高级终端的未来" msgid "" "A power-user tool for arranging terminals. It is inspired by programs such " "as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging " -"terminals in grids (tabs is the most common default method, which Terminator " -"also supports)." +"terminals in grids (tabs is the most common default method, which Terminator" +" also supports)." msgstr "" +"一个用来管理终端的高级用户工具。灵感来自于 gnome-multi-term,quadkonsole " +"等程序。它的主要功能是用网格来管理终端窗口(但同时也支持标签页)。" #: ../data/terminator.appdata.xml.in.h:5 msgid "" @@ -157,6 +159,8 @@ msgid "" "out in different directions with useful features for sysadmins and other " "users." msgstr "" +"Terminator 的大部分行为都基于 GNOME " +"Terminal,在此基础上我们还会将更多功能集成进来。但我们同时也希望向更多不同的方面扩展,从而给系统管理员和其他用户带来更多有用的特性。" #: ../data/terminator.appdata.xml.in.h:6 msgid "Some highlights:" @@ -295,7 +299,7 @@ msgstr "指定一个配置文件" #: ../terminatorlib/optionparse.py:71 msgid "Specify a partial config json file" -msgstr "" +msgstr "指定一个部分配置 json 文件" #: ../terminatorlib/optionparse.py:76 msgid "Set the working directory" @@ -343,15 +347,15 @@ msgstr "如果 Terminator 已经运行,打开一个新的标签页" #: ../terminatorlib/optionparse.py:98 msgid "If Terminator is already running, just unhide all hidden windows" -msgstr "" +msgstr "如果 Terminator 已经在运行,则仅显示所有隐藏窗口" #: ../terminatorlib/optionparse.py:100 msgid "List all profiles" -msgstr "" +msgstr "列出所有配置" #: ../terminatorlib/optionparse.py:102 msgid "List all layouts" -msgstr "" +msgstr "列出所有布局" #: ../terminatorlib/plugins/activitywatch.py:54 msgid "Watch for _activity" @@ -469,7 +473,7 @@ msgstr "*%s*已经存在" #: ../terminatorlib/plugins/dir_open.py:26 msgid "Open current directory" -msgstr "" +msgstr "打开当前目录" #: ../terminatorlib/plugins/logger.py:21 #: ../terminatorlib/plugins/terminalshot.py:21 @@ -715,7 +719,7 @@ msgstr "默认广播:" #: ../terminatorlib/preferences.glade.h:56 msgid "PuTTY style paste:" -msgstr "" +msgstr "粘贴 PuTTY 样式:" #: ../terminatorlib/preferences.glade.h:57 msgid "Smart copy" @@ -731,23 +735,23 @@ msgstr "使用自定义的URL处理程序" #: ../terminatorlib/preferences.glade.h:60 msgid "PRIMARY" -msgstr "" +msgstr "PRIMARY" #: ../terminatorlib/preferences.glade.h:61 msgid "Clipboard" -msgstr "" +msgstr "Clipboard" #: ../terminatorlib/preferences.glade.h:62 msgid "Clear selection on copy" -msgstr "" +msgstr "复制后清除选择" #: ../terminatorlib/preferences.glade.h:63 msgid "Open links with a single click (instead of Ctrl-left click)" -msgstr "" +msgstr "点击打开链接(默认为 Ctrl + 点击)" #: ../terminatorlib/preferences.glade.h:64 msgid "Disable mouse paste" -msgstr "" +msgstr "禁用鼠标粘贴" #: ../terminatorlib/preferences.glade.h:65 msgid "Custom URL handler:" @@ -775,11 +779,11 @@ msgstr "扩展样式 (主题依赖)" #: ../terminatorlib/preferences.glade.h:71 msgid "Cell Height:" -msgstr "" +msgstr "格子高度:" #: ../terminatorlib/preferences.glade.h:72 msgid "Cell Width:" -msgstr "" +msgstr "格子宽度:" #: ../terminatorlib/preferences.glade.h:73 msgid "Tab position:" @@ -795,7 +799,7 @@ msgstr "标签滚动按钮" #: ../terminatorlib/preferences.glade.h:76 msgid "Title bar at bottom (Require restart)" -msgstr "" +msgstr "标题栏置于下方(需重启)" #: ../terminatorlib/preferences.glade.h:77 msgid "Global" @@ -831,7 +835,7 @@ msgstr "选中则复制" #: ../terminatorlib/preferences.glade.h:85 msgid "Disable Ctrl+mousewheel zoom" -msgstr "" +msgstr "禁用 Ctrl + 滚轮缩放" #: ../terminatorlib/preferences.glade.h:86 msgid "Select-by-_word characters:" @@ -851,11 +855,11 @@ msgstr "闪烁" #: ../terminatorlib/preferences.glade.h:90 msgid "Use default colors" -msgstr "" +msgstr "使用默认配色" #: ../terminatorlib/preferences.glade.h:91 msgid "Foreground:" -msgstr "" +msgstr "前景色:" #: ../terminatorlib/preferences.glade.h:92 msgid "Background:" @@ -915,11 +919,11 @@ msgstr "内置方案(_M):" #: ../terminatorlib/preferences.glade.h:107 msgid "_Foreground:" -msgstr "" +msgstr "前景色(_F):" #: ../terminatorlib/preferences.glade.h:108 msgid "_Background:" -msgstr "" +msgstr "背景色(_B):" #: ../terminatorlib/preferences.glade.h:109 msgid "Palette" @@ -935,7 +939,7 @@ msgstr "调色板(_A):" #: ../terminatorlib/preferences.glade.h:112 msgid "Show b_old text in bright colors" -msgstr "" +msgstr "用明亮色显示粗体文字(_O)" #: ../terminatorlib/preferences.glade.h:113 msgid "Colors" @@ -951,19 +955,19 @@ msgstr "透明背景(_T)" #: ../terminatorlib/preferences.glade.h:116 msgid "Background Image" -msgstr "" +msgstr "背景图片" #: ../terminatorlib/preferences.glade.h:117 msgid "Background Image File:" -msgstr "" +msgstr "背景图片文件:" #: ../terminatorlib/preferences.glade.h:118 msgid "Choose file" -msgstr "" +msgstr "选择文件" #: ../terminatorlib/preferences.glade.h:119 msgid "S_hade background:" -msgstr "" +msgstr "背景着色(_H):" #: ../terminatorlib/preferences.glade.h:120 msgid "None" @@ -1009,11 +1013,10 @@ msgstr "滚动" msgid "" "Note: These options may cause some applications to behave " "incorrectly. They are only here to allow you to work around certain " -"applications and operating systems that expect different terminal behavior." +"applications and operating systems that expect different terminal " +"behavior." msgstr "" -"注意:这些选项可能造成一些应用程序产生不正确的行为。仅用于允" -"许您在一些应用程序和操作系统中作调整以获得不同的终端行为。" +"注意:这些选项可能造成一些应用程序产生不正确的行为。仅用于允许您在一些应用程序和操作系统中作调整以获得不同的终端行为。" #: ../terminatorlib/preferences.glade.h:131 msgid "_Backspace key generates:" @@ -1057,7 +1060,7 @@ msgstr "选择标题栏字体" #: ../terminatorlib/preferences.glade.h:141 msgid "Titlebar" -msgstr "" +msgstr "标题栏" #: ../terminatorlib/preferences.glade.h:142 #: ../terminatorlib/terminal_popup_menu.py:204 @@ -1110,27 +1113,16 @@ msgstr "插件" #: ../terminatorlib/preferences.glade.h:158 msgid "Version: 2.1.1" -msgstr "" +msgstr "版本:2.1.1" #: ../terminatorlib/preferences.glade.h:159 msgid "" -"The goal of this project is to produce a useful tool for arranging " -"terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, " -"etc. in that the main focus is arranging terminals in grids (tabs is the " -"most common default method, which Terminator also supports).\n" +"The goal of this project is to produce a useful tool for arranging terminals. It is inspired by programs such as gnome-multi-term, quadkonsole, etc. in that the main focus is arranging terminals in grids (tabs is the most common default method, which Terminator also supports).\n" "\n" -"Much of the behavior of Terminator is based on GNOME Terminal, and we are " -"adding more features from that as time goes by, but we also want to extend " -"out in different directions with useful features for sysadmins and other " -"users. If you have any suggestions, please file wishlist bugs! (see left for " -"the Development link)" +"Much of the behavior of Terminator is based on GNOME Terminal, and we are adding more features from that as time goes by, but we also want to extend out in different directions with useful features for sysadmins and other users. If you have any suggestions, please file wishlist bugs! (see left for the Development link)" msgstr "" -"一个用来管理终端的高级用户工具。它的灵感来自于gnome-multi-term,quadkonsole等" -"程序。它致力于用格子来管理终端(最普遍的方法是用标签页,Terminator也支" -"持)。\n" -"Terminator的大部分行为基于GNOME Terminal,我们还在从中集成更多特性。但我们同" -"时也希望向扩展更多不同方面的实用特性从而服务于系统管理员和其他用户。如果你有" -"任何建议,请向wishlist中提交!(看左边的开发者链接)" +"一个用来管理终端的高级用户工具。它的灵感来自于gnome-multi-term,quadkonsole等程序。它致力于用格子来管理终端(最普遍的方法是用标签页,Terminator也支持)。\n" +"Terminator的大部分行为基于GNOME Terminal,我们还在从中集成更多特性。但我们同时也希望向扩展更多不同方面的实用特性从而服务于系统管理员和其他用户。如果你有任何建议,请向wishlist中提交!(看左边的开发者链接)" #: ../terminatorlib/preferences.glade.h:162 msgid "The Manual" @@ -1139,9 +1131,10 @@ msgstr "手册" #: ../terminatorlib/preferences.glade.h:163 msgid "" "Development\n" -"Bugs / " -"Enhancements" +"Bugs / Enhancements" msgstr "" +"开发\n" +"提交 Bug 或改进意见" #: ../terminatorlib/preferences.glade.h:165 msgid "About" @@ -1161,15 +1154,15 @@ msgstr "恢复为原始字体大小" #: ../terminatorlib/prefseditor.py:107 msgid "Increase font size on all terminals" -msgstr "" +msgstr "增大所有终端的字体" #: ../terminatorlib/prefseditor.py:108 msgid "Decrease font size on all terminals" -msgstr "" +msgstr "减小所有终端的字体" #: ../terminatorlib/prefseditor.py:109 msgid "Restore original font size on all terminals" -msgstr "" +msgstr "恢复所有终端的字体大小" #: ../terminatorlib/prefseditor.py:110 msgid "Create a new tab" @@ -1229,7 +1222,7 @@ msgstr "粘贴剪贴板" #: ../terminatorlib/prefseditor.py:126 msgid "Paste primary selection" -msgstr "" +msgstr "从 PRIMARY 选区粘贴" #: ../terminatorlib/prefseditor.py:127 msgid "Show/Hide the scrollbar" @@ -1365,7 +1358,7 @@ msgstr "切换窗口可见性" #: ../terminatorlib/prefseditor.py:160 msgid "Create new group" -msgstr "" +msgstr "创建新组" #: ../terminatorlib/prefseditor.py:161 msgid "Group all terminals" @@ -1381,15 +1374,15 @@ msgstr "解组所有终端" #: ../terminatorlib/prefseditor.py:164 msgid "Group terminals in window" -msgstr "" +msgstr "对窗口中的终端分组" #: ../terminatorlib/prefseditor.py:165 msgid "Group/Ungroup terminals in window" -msgstr "" +msgstr "对窗口中的终端分组或取消分组" #: ../terminatorlib/prefseditor.py:166 msgid "Ungroup terminals in window" -msgstr "" +msgstr "对窗口中的终端取消分组" #: ../terminatorlib/prefseditor.py:167 msgid "Group terminals in tab" @@ -1457,17 +1450,17 @@ msgstr "切换到上一个配置文件" #: ../terminatorlib/prefseditor.py:183 msgid "Open the Preferences window" -msgstr "" +msgstr "打开首选项窗口" #: ../terminatorlib/prefseditor.py:184 msgid "Open the manual" msgstr "打开手册" -#: ../terminatorlib/prefseditor.py:1370 +#: ../terminatorlib/prefseditor.py:1366 msgid "New Profile" msgstr "新配置" -#: ../terminatorlib/prefseditor.py:1413 ../terminatorlib/prefseditor.py:1418 +#: ../terminatorlib/prefseditor.py:1409 ../terminatorlib/prefseditor.py:1414 msgid "New Layout" msgstr "新布局" @@ -1514,7 +1507,7 @@ msgstr "粘贴(_P)" #: ../terminatorlib/terminal_popup_menu.py:112 msgid "Set W_indow Title" -msgstr "" +msgstr "设置窗口标题(_I)" #: ../terminatorlib/terminal_popup_menu.py:117 msgid "Split H_orizontally" @@ -1554,7 +1547,7 @@ msgstr "分组" #: ../terminatorlib/terminal_popup_menu.py:186 msgid "Relaunch Command" -msgstr "" +msgstr "重新启动命令" #: ../terminatorlib/terminal_popup_menu.py:191 msgid "Show _scrollbar" @@ -1562,7 +1555,7 @@ msgstr "显示滚动条" #: ../terminatorlib/terminal_popup_menu.py:248 msgid "_Layouts..." -msgstr "" +msgstr "布局...(_L)" #: ../terminatorlib/terminal.py:481 msgid "N_ew group..." @@ -1579,11 +1572,11 @@ msgstr "移除组 %s" #: ../terminatorlib/terminal.py:512 msgid "G_roup all in window" -msgstr "" +msgstr "将窗口中所有终端纳入分组(_R)" #: ../terminatorlib/terminal.py:517 msgid "Ungro_up all in window" -msgstr "" +msgstr "将窗口中所有终端移出分组(_U)" #: ../terminatorlib/terminal.py:522 msgid "G_roup all in tab" @@ -1630,25 +1623,25 @@ msgstr "插入终端编号(_I)" msgid "Insert _padded terminal number" msgstr "插入对齐的终端编号(_I)" -#: ../terminatorlib/terminal.py:1490 +#: ../terminatorlib/terminal.py:1492 msgid "Unable to find a shell" msgstr "无法找到shell" -#: ../terminatorlib/terminal.py:1521 +#: ../terminatorlib/terminal.py:1546 msgid "Unable to start shell:" msgstr "无法启动shell:" -#: ../terminatorlib/terminal.py:1975 +#: ../terminatorlib/terminal.py:2000 msgid "Rename Window" msgstr "重命名窗口" -#: ../terminatorlib/terminal.py:1983 +#: ../terminatorlib/terminal.py:2008 msgid "Enter a new title for the Terminator window..." msgstr "输入新的Terminator窗口标题" #: ../terminatorlib/titlebar.py:112 msgid "[INACTIVE: Right-Click for Relaunch option] " -msgstr "" +msgstr "[不活动:右击查看重启选项]" #: ../terminatorlib/titlebar.py:258 msgid "Alpha" @@ -1753,117 +1746,9 @@ msgstr "窗口" #: ../terminatorlib/window.py:773 #, python-format msgid "Window group %s" -msgstr "" +msgstr "窗口组 %s" #: ../terminatorlib/window.py:799 #, python-format msgid "Tab %d" msgstr "标签 %d" - -#~ msgid "Current Locale" -#~ msgstr "当前 Locale" - -#~ msgid "Western" -#~ msgstr "西文" - -#~ msgid "Central European" -#~ msgstr "中欧语系" - -#~ msgid "South European" -#~ msgstr "南欧语系" - -#~ msgid "Baltic" -#~ msgstr "波罗的海语系" - -#~ msgid "Cyrillic" -#~ msgstr "西里尔文" - -#~ msgid "Arabic" -#~ msgstr "阿拉伯语" - -#~ msgid "Greek" -#~ msgstr "希腊语" - -#~ msgid "Hebrew Visual" -#~ msgstr "希伯来语 (视觉顺序)" - -#~ msgid "Hebrew" -#~ msgstr "希伯来语" - -#~ msgid "Turkish" -#~ msgstr "土耳其语" - -#~ msgid "Nordic" -#~ msgstr "日耳曼语" - -#~ msgid "Celtic" -#~ msgstr "凯尔特语" - -#~ msgid "Romanian" -#~ msgstr "罗马尼亚语" - -#~ msgid "Unicode" -#~ msgstr "Unicode" - -#~ msgid "Armenian" -#~ msgstr "亚美尼亚语" - -#~ msgid "Chinese Traditional" -#~ msgstr "繁体中文" - -#~ msgid "Cyrillic/Russian" -#~ msgstr "西里尔语/俄语" - -#~ msgid "Japanese" -#~ msgstr "日语" - -#~ msgid "Korean" -#~ msgstr "朝鲜语" - -#~ msgid "Chinese Simplified" -#~ msgstr "简体中文" - -#~ msgid "Georgian" -#~ msgstr "格鲁吉亚语" - -#~ msgid "Cyrillic/Ukrainian" -#~ msgstr "西里尔语/乌克兰语" - -#~ msgid "Croatian" -#~ msgstr "克罗地亚语" - -#~ msgid "Hindi" -#~ msgstr "印地语" - -#~ msgid "Persian" -#~ msgstr "波斯语" - -#~ msgid "Gujarati" -#~ msgstr "古吉拉特语" - -#~ msgid "Gurmukhi" -#~ msgstr "果鲁穆奇语" - -#~ msgid "Icelandic" -#~ msgstr "冰岛语" - -#~ msgid "Vietnamese" -#~ msgstr "越南语" - -#~ msgid "Thai" -#~ msgstr "泰语" - -#~ msgid "Encoding:" -#~ msgstr "编码:" - -#~ msgid "Encodings" -#~ msgstr "编码" - -#~ msgid "Default" -#~ msgstr "默认" - -#~ msgid "User defined" -#~ msgstr "用户定义" - -#~ msgid "Other Encodings" -#~ msgstr "其他编码" From 368666c0af38df949dbdb18eb41c065f68182824 Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Fri, 21 Jul 2023 08:55:44 +0000 Subject: [PATCH 091/101] Translate po/terminator.pot in zh_CN 100% translated source file: 'po/terminator.pot' on 'zh_CN'. --- po/zh_CN.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/po/zh_CN.po b/po/zh_CN.po index 815a61e7b..8115f755b 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -65,7 +65,7 @@ msgstr "获取父标签页的标题" #: ../remotinator.py:49 msgid "Set the title of a parent tab" -msgstr "设置父级标签页的标题" +msgstr "设置父标签页的标题" #: ../remotinator.py:50 msgid "Set the background image" From 98659bdd8d8d7e0c4ee0af7c9fed49fdce0f9820 Mon Sep 17 00:00:00 2001 From: "transifex-integration[bot]" <43880903+transifex-integration[bot]@users.noreply.github.com> Date: Fri, 21 Jul 2023 08:55:55 +0000 Subject: [PATCH 092/101] Translate po/terminator.pot in zh_CN 100% translated source file: 'po/terminator.pot' on 'zh_CN'. --- po/zh_CN.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/po/zh_CN.po b/po/zh_CN.po index 8115f755b..590805c2b 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -57,7 +57,7 @@ msgstr "获取父窗口的标题" #: ../remotinator.py:47 msgid "Get the UUID of a parent tab" -msgstr "获取一个父标签页的UUID" +msgstr "获取父标签页的UUID" #: ../remotinator.py:48 msgid "Get the title of a parent tab" From d91d017e20df848891d3d601637951253736e4be Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Sun, 6 Aug 2023 20:18:28 +0530 Subject: [PATCH 093/101] -remove the plugin from the plugin shortcut util / helper code --- .../plugins/mousefree_url_handler.py | 171 ------------------ 1 file changed, 171 deletions(-) delete mode 100644 terminatorlib/plugins/mousefree_url_handler.py diff --git a/terminatorlib/plugins/mousefree_url_handler.py b/terminatorlib/plugins/mousefree_url_handler.py deleted file mode 100644 index bb782ea3f..000000000 --- a/terminatorlib/plugins/mousefree_url_handler.py +++ /dev/null @@ -1,171 +0,0 @@ -""" -- With min changes to main code base, implementing mouse free url handling. -- Using shortcuts to browse URL, next / previous, clear search. Selected URL -is copied to clipboard. - -- Vishweshwar Saran Singh Deo vssdeo@gmail.com -""" - -import gi -gi.require_version('Vte', '2.91') # vte-0.38 (gnome-3.14) -from gi.repository import Vte - -from terminatorlib.terminator import Terminator - -from terminatorlib.config import Config -import terminatorlib.plugin as plugin -from terminatorlib.plugin import KeyBindUtil - -from terminatorlib.util import get_config_dir, err, dbg, gerr -from terminatorlib import regex - -import re - - -AVAILABLE = ['MouseFreeURLHandler'] - -PluginUrlActFindNext = "plugin_url_find_next" -PluginUrlActFindPrev = "plugin_url_find_prev" -PluginUrlActEsc = "plugin_url_esc" -PluginUrlActLaunch = "plugin_url_launch" - - -PluginUrlFindNext = "Plugin Url Find Next" -PluginUrlFindPrev = "Plugin Url Find Prev" -PluginUrlEsc = "Plugin Url Esc" -PluginUrlLaunch = "Plugin Url Launch" - -class MouseFreeURLHandler(plugin.Plugin): - - capabilities = ['url_handler'] - handler_name = 'MouseFreeURLHandler' - nameopen = None - namecopy = None - match = None - - flag_http_on = False - config = Config() - keyb = KeyBindUtil(config) - matches = [] - matches_ptr = -1 - #basic pattern - searchtext = "https?\:\/\/[^\s]+[\/\w]" - - def __init__(self): - self.connect_signals() - - self.keyb.bindkey_check_config( - [PluginUrlFindNext , PluginUrlActFindNext, "j"]) - self.keyb.bindkey_check_config( - [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) - self.keyb.bindkey_check_config( - [PluginUrlEsc , PluginUrlActEsc, "Escape"]) - self.keyb.bindkey_check_config( - [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) - - def connect_signals(self): - self.windows = Terminator().get_windows() - for window in self.windows: - window.connect('key-press-event', self.on_keypress) - - - def unload(self): - # - for window in self.windows: - window.disconnect_by_func(self.on_keypress) - - self.keyb.unbindkey( - [PluginUrlFindNext , PluginUrlActFindNext, "j"]) - self.keyb.unbindkey( - [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) - self.keyb.unbindkey( - [PluginUrlEsc , PluginUrlActEsc, "Escape"]) - self.keyb.unbindkey( - [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) - - def extract(self): - #can we do extract more efficiently - col, row = self.vte.get_cursor_position() - (txt, attr) = self.vte.get_text_range(0,0,row, col) - self.matches = re.findall(self.searchtext, txt) - self.matches_ptr = len(self.matches)-1 - - def get_term(self): - return Terminator().last_focused_term - - def get_selected_url(self): - if len(self.matches): - dbg("selected URL (%s %s)" % (self.matches_ptr, self.matches[self.matches_ptr])) - return self.matches[self.matches_ptr] - dbg("selected URL (%s %s)" % (self.matches_ptr, "not found")) - return None - - def on_keypress(self, widget, event): - act = self.keyb.keyaction(event) - dbg("keyaction: (%s) (%s)" % (str(act), event.keyval)) - - if act == PluginUrlActFindNext: - if not self.flag_http_on: - dbg("search URL on") - self.search() - self.extract() - #so when we start search last item be selected - self.vte.search_find_previous() - self.get_selected_url() # dbg url print - self.vte.copy_clipboard() - return True - else: - self.vte.search_find_next() - - if (self.matches_ptr < len(self.matches)-1): - self.matches_ptr += 1 - else: - self.matches_ptr = 0 - - self.vte.copy_clipboard() - self.get_selected_url() # dbg url print - return True - - if act == PluginUrlActFindPrev: - if not self.flag_http_on: - self.search() - self.extract() - self.get_selected_url() # dbg url print - self.vte.search_find_previous() - self.vte.copy_clipboard() - return True - - self.vte.search_find_previous() - - if self.matches_ptr > 0: - self.matches_ptr -= 1 - elif len(self.matches): - self.matches_ptr = len(self.matches)-1 - - self.vte.copy_clipboard() - self.get_selected_url() # dbg url print - return True - - if act == PluginUrlActEsc: - self.matches = [] - self.vte = self.get_term().get_vte() - self.vte.search_set_regex(None, 0) - self.flag_http_on = False - dbg("search URL off") - - if act == PluginUrlActLaunch: - url = self.get_selected_url() - if url: - self.get_term().open_url(url, prepare=False) - - def search(self): - self.flag_http_on = True - self.vte = self.get_term().get_vte() - - self.vte.search_set_wrap_around(True) - regex_flags_pcre2 = (regex.FLAGS_PCRE2 | regex.PCRE2_CASELESS) - searchre = Vte.Regex.new_for_search(self.searchtext, - len(self.searchtext), regex_flags_pcre2) - - self.vte.search_set_regex(searchre, 0) - From 11639159b41a4133028c2cc3acf9a8d0ace7b5ea Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 9 Aug 2023 14:39:45 +0530 Subject: [PATCH 094/101] - removed KeyBindUtil dependency as its now a seperate pull request - this branch is further decoupled using the current commit, 681-Plugin-Submission-Plugin-Utility-KeyBinding-Mouseless-Keyboard-URL-Open --- terminatorlib/notebook.py | 4 + terminatorlib/plugin.py | 16 +- .../plugins/mousefree_url_handler.py | 204 ++++++++++++++++++ 3 files changed, 221 insertions(+), 3 deletions(-) create mode 100644 terminatorlib/plugins/mousefree_url_handler.py diff --git a/terminatorlib/notebook.py b/terminatorlib/notebook.py index 9cb6bd489..eb630b171 100644 --- a/terminatorlib/notebook.py +++ b/terminatorlib/notebook.py @@ -343,6 +343,10 @@ def newtab(self, debugtab=False, widget=None, cwd=None, metadata=None, profile=N self.set_current_page(tabpos) self.show_all() if maker.isinstance(term_widget, 'Terminal'): + #notify plugins of tab-change + dbg("emit tab-change for tabpos: %s " % tabpos) + term_widget.emit('tab-change', tabpos) + self.set_current_page(tabpos) widget.grab_focus() def wrapcloseterm(self, widget): diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py index 7a0487a40..ac9d3aa98 100644 --- a/terminatorlib/plugin.py +++ b/terminatorlib/plugin.py @@ -69,12 +69,14 @@ def prepare_attributes(self): if not self.available_plugins: self.available_plugins = {} - def load_plugins(self): + def load_plugins(self, force=False): """Load all plugins present in the plugins/ directory in our module""" - if self.done: + if self.done and (not force): dbg('Already loaded') return + dbg('loading plugins, force:(%s)' % force) + config = Config() for plugindir in self.path: @@ -93,8 +95,8 @@ def load_plugins(self): try: module = __import__(plugin[:-3], None, None, ['']) for item in getattr(module, 'AVAILABLE'): + func = getattr(module, item) if item not in list(self.available_plugins.keys()): - func = getattr(module, item) self.available_plugins[item] = func if item not in config['enabled_plugins']: @@ -102,6 +104,14 @@ def load_plugins(self): continue if item not in self.instances: self.instances[item] = func() + elif force: + #instead of multiple copies of loaded + #plugin objects, unload where plugins + #can clean up and then re-init so there + #is one plugin object + self.instances[item].unload() + self.instances.pop(item, None) + self.instances[item] = func() except Exception as ex: err('PluginRegistry::load_plugins: Importing plugin %s \ failed: %s' % (plugin, ex)) diff --git a/terminatorlib/plugins/mousefree_url_handler.py b/terminatorlib/plugins/mousefree_url_handler.py new file mode 100644 index 000000000..2b7da5433 --- /dev/null +++ b/terminatorlib/plugins/mousefree_url_handler.py @@ -0,0 +1,204 @@ +""" +- With min changes to main code base, implementing mouse free url handling. +- Using shortcuts to browse URL, next / previous, clear search. Selected URL +is copied to clipboard. + +- Vishweshwar Saran Singh Deo vssdeo@gmail.com +""" + +import gi +gi.require_version('Vte', '2.91') # vte-0.38 (gnome-3.14) +from gi.repository import Vte + +from terminatorlib.terminator import Terminator + +from terminatorlib.config import Config +import terminatorlib.plugin as plugin +from terminatorlib.plugin import KeyBindUtil + +from terminatorlib.util import get_config_dir, err, dbg, gerr +from terminatorlib import regex + +import re + + +AVAILABLE = ['MouseFreeURLHandler'] + +PluginUrlActFindNext = "plugin_url_find_next" +PluginUrlActFindPrev = "plugin_url_find_prev" +PluginUrlActEsc = "plugin_url_esc" +PluginUrlActLaunch = "plugin_url_launch" + + +PluginUrlFindNext = "Plugin Url Find Next" +PluginUrlFindPrev = "Plugin Url Find Prev" +PluginUrlEsc = "Plugin Url Esc" +PluginUrlLaunch = "Plugin Url Launch" + +class MouseFreeURLHandler(plugin.Plugin): + + capabilities = ['MouseFreeHandler'] + handler_name = 'MouseFreeHandler' + nameopen = None + namecopy = None + match = None + + flag_http_on = False + config = Config() + keyb = KeyBindUtil(config) + matches = [] + matches_ptr = -1 + #basic pattern + searchtext = "https?\:\/\/[^\s]+[\/\w]" + + def __init__(self): + self.connect_signals() + + self.keyb.bindkey_check_config( + [PluginUrlFindNext , PluginUrlActFindNext, "j"]) + self.keyb.bindkey_check_config( + [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) + self.keyb.bindkey_check_config( + [PluginUrlEsc , PluginUrlActEsc, "Escape"]) + self.keyb.bindkey_check_config( + [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) + + def connect_signals(self): + #this is not giving list off all connected terminals in window + dbg("direct terminals: %s" % Terminator().terminals) + + #get list of all terminals indirectly + terms = Terminator().terminals[0] + dbg("in-direct get terminals: %s" % terms.terminator.terminals) + + for term in terms.terminator.terminals: + dbg("signal connect term:%s" % term) + term.connect('tab-change', self.on_focus_in) + + self.windows = Terminator().get_windows() + for window in self.windows: + window.connect('key-press-event', self.on_keypress) + + def unload(self): + dbg("unloading") + #disconnect all signals and events + terms = Terminator().terminals[0] + for term in terms.terminator.terminals: + try: + term.disconnect_by_func(self.on_focus_in) + except: + dbg("no connected signals") + + for window in self.windows: + try: + window.disconnect_by_func(self.on_keypress) + except: + dbg("no connected signals") + + self.keyb.unbindkey( + [PluginUrlFindNext , PluginUrlActFindNext, "j"]) + self.keyb.unbindkey( + [PluginUrlFindPrev , PluginUrlActFindPrev, "k"]) + self.keyb.unbindkey( + [PluginUrlEsc , PluginUrlActEsc, "Escape"]) + self.keyb.unbindkey( + [PluginUrlLaunch, PluginUrlActLaunch, "Return"]) + + def extract(self): + #can we do extract more efficiently + col, row = self.vte.get_cursor_position() + (txt, attr) = self.vte.get_text_range(0,0,row, col) + self.matches = re.findall(self.searchtext, txt) + self.matches_ptr = len(self.matches)-1 + + def get_term(self): + return Terminator().last_focused_term + + def get_selected_url(self): + if len(self.matches): + dbg("found selected URL (%s %s %s)" % + (self.matches_ptr, self.matches[self.matches_ptr], self)) + return self.matches[self.matches_ptr] + dbg("selected URL (%s %s)" % (self.matches_ptr, "not found")) + return None + + def on_focus_in(self, widget, event): + dbg("focus-in clear url search buffer: %s" % self) + self.clear_search() + + def on_keypress(self, widget, event): + act = self.keyb.keyaction(event) + dbg("keyaction: (%s) (%s)" % (str(act), event.keyval)) + + if act == PluginUrlActFindNext: + if not self.flag_http_on: + dbg("search URL on") + self.search() + self.extract() + #so when we start search last item be selected + self.vte.search_find_previous() + self.get_selected_url() # dbg url print + self.vte.copy_clipboard() + return True + else: + self.vte.search_find_next() + + if (self.matches_ptr < len(self.matches)-1): + self.matches_ptr += 1 + else: + self.matches_ptr = 0 + + self.vte.copy_clipboard() + self.get_selected_url() # dbg url print + return True + + if act == PluginUrlActFindPrev: + if not self.flag_http_on: + self.search() + self.extract() + self.vte.search_find_previous() + self.get_selected_url() # dbg url print + self.vte.copy_clipboard() + return True + + self.vte.search_find_previous() + + if self.matches_ptr > 0: + self.matches_ptr -= 1 + elif len(self.matches): + self.matches_ptr = len(self.matches)-1 + + self.vte.copy_clipboard() + self.get_selected_url() # dbg url print + return True + + if act == PluginUrlActEsc: + self.clear_search() + + if act == PluginUrlActLaunch: + url = self.get_selected_url() + if url: + self.get_term().open_url(url, prepare=False) + + + def clear_search(self): + self.matches = [] + self.flag_http_on = False + self.matches_ptr = -1 + if self.get_term(): + self.vte = self.get_term().get_vte() + self.vte.search_set_regex(None, 0) + dbg("search URL off") + + def search(self): + dbg("searching text") + self.flag_http_on = True + self.vte = self.get_term().get_vte() + + self.vte.search_set_wrap_around(True) + regex_flags_pcre2 = (regex.FLAGS_PCRE2 | regex.PCRE2_CASELESS) + searchre = Vte.Regex.new_for_search(self.searchtext, + len(self.searchtext), regex_flags_pcre2) + + self.vte.search_set_regex(searchre, 0) + From 64a6e391acd7b627576e824221c678c9ed669580 Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 9 Aug 2023 14:47:42 +0530 Subject: [PATCH 095/101] - more changes from 681-Plugin-Submission-Plugin-Utility-KeyBinding-Mouseless-Keyboard-URL-Open that were to be decoupled --- terminatorlib/terminal.py | 11 +++++++++++ terminatorlib/terminator.py | 8 ++++++++ 2 files changed, 19 insertions(+) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 914d69d7b..8680d20bf 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -156,6 +156,13 @@ def __init__(self): dbg('composite_support: %s' % self.composite_support) self.vte.show() + + #force to load for new window/terminal use case loading plugin + #and connecting signals, note the line update_url_matches also + #calls load_plugins, but it won't reload since already loaded + + self.load_plugins(force = True) + self.update_url_matches() self.terminalbox = self.create_terminalbox() @@ -285,6 +292,10 @@ def create_terminalbox(self): return(terminalbox) + def load_plugins(self, force = False): + registry = plugin.PluginRegistry() + registry.load_plugins(force) + def _add_regex(self, name, re): match = -1 if regex.FLAGS_PCRE2: diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index db3f465f9..a72704662 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -186,6 +186,13 @@ def find_terminal_by_uuid(self, uuid): for terminal in self.terminals: dbg('checking: %s (%s)' % (terminal.uuid.urn, terminal)) if terminal.uuid.urn == uuid: + if terminal.get_toplevel().is_child_notebook(): + topchild = terminal.get_toplevel().get_child() + current_page = topchild.get_current_page() + #we need to emit signal for plugin and retain same page + dbg("current_page for tab-change-signal:%s" % current_page) + terminal.emit('tab-change', current_page) + return terminal return None @@ -210,6 +217,7 @@ def new_window(self, cwd=None, profile=None): window.add(terminal) window.show(True) terminal.spawn_child() + terminal.emit('tab-change', 0) return(window, terminal) From fdfaa80907f3db095d83091a86983043cb0c078f Mon Sep 17 00:00:00 2001 From: xuezhixin Date: Wed, 9 Aug 2023 17:33:12 +0800 Subject: [PATCH 096/101] Document syntax error Signed-off-by: xuezhixin --- doc/terminator.1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/terminator.1 b/doc/terminator.1 index a224b5307..b1776add0 100644 --- a/doc/terminator.1 +++ b/doc/terminator.1 @@ -68,7 +68,7 @@ Start with a fullscreen window. .sp \fB\-b\fP, \fB\-\-borderless\fP .RS 4 -Instruct the window manager not to render borders/decoration on the +Instruct the window manager not to render borders/decorations on the Terminator window (this works well with \-\-maximise). .RE .sp @@ -474,4 +474,4 @@ Terminator was written by Chris Jones and others. This manual page was written by Chris Jones and others. .SH "SEE ALSO" .sp -\fBterminator_config\fP(5) \ No newline at end of file +\fBterminator_config\fP(5) From d39968ebba816cf1cd14b81894ccb7ec6290fb2a Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 9 Aug 2023 16:11:59 +0530 Subject: [PATCH 097/101] - [bug 681] removed force plugin load from plugin and separated the code in a diff issue Plugin Submission + Generic Plugin Utility Functions & KeyBinding Feature: Mouseless / Mousefree / Keyboard URL opening or yanking --- terminatorlib/plugin.py | 16 +++------------- terminatorlib/terminal.py | 11 ----------- 2 files changed, 3 insertions(+), 24 deletions(-) diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py index ac9d3aa98..7a0487a40 100644 --- a/terminatorlib/plugin.py +++ b/terminatorlib/plugin.py @@ -69,14 +69,12 @@ def prepare_attributes(self): if not self.available_plugins: self.available_plugins = {} - def load_plugins(self, force=False): + def load_plugins(self): """Load all plugins present in the plugins/ directory in our module""" - if self.done and (not force): + if self.done: dbg('Already loaded') return - dbg('loading plugins, force:(%s)' % force) - config = Config() for plugindir in self.path: @@ -95,8 +93,8 @@ def load_plugins(self, force=False): try: module = __import__(plugin[:-3], None, None, ['']) for item in getattr(module, 'AVAILABLE'): - func = getattr(module, item) if item not in list(self.available_plugins.keys()): + func = getattr(module, item) self.available_plugins[item] = func if item not in config['enabled_plugins']: @@ -104,14 +102,6 @@ def load_plugins(self, force=False): continue if item not in self.instances: self.instances[item] = func() - elif force: - #instead of multiple copies of loaded - #plugin objects, unload where plugins - #can clean up and then re-init so there - #is one plugin object - self.instances[item].unload() - self.instances.pop(item, None) - self.instances[item] = func() except Exception as ex: err('PluginRegistry::load_plugins: Importing plugin %s \ failed: %s' % (plugin, ex)) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 8680d20bf..914d69d7b 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -156,13 +156,6 @@ def __init__(self): dbg('composite_support: %s' % self.composite_support) self.vte.show() - - #force to load for new window/terminal use case loading plugin - #and connecting signals, note the line update_url_matches also - #calls load_plugins, but it won't reload since already loaded - - self.load_plugins(force = True) - self.update_url_matches() self.terminalbox = self.create_terminalbox() @@ -292,10 +285,6 @@ def create_terminalbox(self): return(terminalbox) - def load_plugins(self, force = False): - registry = plugin.PluginRegistry() - registry.load_plugins(force) - def _add_regex(self, name, re): match = -1 if regex.FLAGS_PCRE2: From 3b4d32cda315c8c33b7ce585b07c4c7ee78b658e Mon Sep 17 00:00:00 2001 From: Vishweshwar Saran Singh Deo Date: Wed, 9 Aug 2023 16:31:41 +0530 Subject: [PATCH 098/101] [bug 808] Plugins-dont-receive-keboard-signals-on-newly-opened-windows - code separated for force loading of plugins on every terminal instance --- terminatorlib/plugin.py | 16 +++++++++++++--- terminatorlib/terminal.py | 11 +++++++++++ 2 files changed, 24 insertions(+), 3 deletions(-) diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py index 7a0487a40..ac9d3aa98 100644 --- a/terminatorlib/plugin.py +++ b/terminatorlib/plugin.py @@ -69,12 +69,14 @@ def prepare_attributes(self): if not self.available_plugins: self.available_plugins = {} - def load_plugins(self): + def load_plugins(self, force=False): """Load all plugins present in the plugins/ directory in our module""" - if self.done: + if self.done and (not force): dbg('Already loaded') return + dbg('loading plugins, force:(%s)' % force) + config = Config() for plugindir in self.path: @@ -93,8 +95,8 @@ def load_plugins(self): try: module = __import__(plugin[:-3], None, None, ['']) for item in getattr(module, 'AVAILABLE'): + func = getattr(module, item) if item not in list(self.available_plugins.keys()): - func = getattr(module, item) self.available_plugins[item] = func if item not in config['enabled_plugins']: @@ -102,6 +104,14 @@ def load_plugins(self): continue if item not in self.instances: self.instances[item] = func() + elif force: + #instead of multiple copies of loaded + #plugin objects, unload where plugins + #can clean up and then re-init so there + #is one plugin object + self.instances[item].unload() + self.instances.pop(item, None) + self.instances[item] = func() except Exception as ex: err('PluginRegistry::load_plugins: Importing plugin %s \ failed: %s' % (plugin, ex)) diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 914d69d7b..8680d20bf 100644 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -156,6 +156,13 @@ def __init__(self): dbg('composite_support: %s' % self.composite_support) self.vte.show() + + #force to load for new window/terminal use case loading plugin + #and connecting signals, note the line update_url_matches also + #calls load_plugins, but it won't reload since already loaded + + self.load_plugins(force = True) + self.update_url_matches() self.terminalbox = self.create_terminalbox() @@ -285,6 +292,10 @@ def create_terminalbox(self): return(terminalbox) + def load_plugins(self, force = False): + registry = plugin.PluginRegistry() + registry.load_plugins(force) + def _add_regex(self, name, re): match = -1 if regex.FLAGS_PCRE2: From f7b6ea07bc8f48dd95ae5fc863d785c32e063b5a Mon Sep 17 00:00:00 2001 From: Matthew Rose Date: Sat, 26 Aug 2023 09:21:18 -0400 Subject: [PATCH 099/101] Fix Insert Term Name Plugin error The "Insert terminal name" Plugin causes the following traceback Traceback (most recent call last): File "/Users/mattrose/Code/terminator/terminatorlib/terminator.py", line 588, in do_insert_term_name term.feed(name) File "/Users/mattrose/Code/terminator/terminatorlib/terminal.py", line 1709, in feed self.vte.feed_child(text) This PR fixes it so the plugin inserts the terminal name, as intended. --- terminatorlib/terminator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index db3f465f9..8a01b6adf 100644 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -585,7 +585,7 @@ def do_insert_term_name(self, widget): for term in self.get_target_terms(widget): name = term.titlebar.get_custom_string() or term.get_window_title() - term.feed(name) + term.feed(name.encode()) def get_sibling_terms(self, widget): termset = [] From 7fa87058d58b0aa62589b2937fc2a0d5743540a4 Mon Sep 17 00:00:00 2001 From: Tristan F Date: Sun, 3 Sep 2023 10:11:00 -0400 Subject: [PATCH 100/101] chore: bump ations/checkout (v2 -> v3) --- .github/workflows/python.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 2889b70f0..8aaa0c929 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -20,7 +20,7 @@ jobs: - '3.9' steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python }} uses: actions/setup-python@v1 From 8f8343f95f2794850c2a2ad96ba8e571b9e3a8df Mon Sep 17 00:00:00 2001 From: Tristan F Date: Tue, 12 Sep 2023 18:53:52 -0400 Subject: [PATCH 101/101] ci: bump actions/checkout ~> v4 --- .github/workflows/python.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 8aaa0c929..b2a90e27c 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -20,7 +20,7 @@ jobs: - '3.9' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python }} uses: actions/setup-python@v1