diff --git a/ChangeLog b/ChangeLog
index fb7261f4..706ecf85 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
terminator trunk:
- * Features
- * Enhancements
+ Features
+
+ Enhancements
* As part of GTK3 fixup, some backported improvements to the DBus
interface, and remotinator (Steve Boddy)
* Can now open a window or tab using remotinator
@@ -17,7 +18,14 @@ terminator trunk:
(Steve Boddy)
* Updated and grouped default shortcuts in man page (Steve Boddy)
* Added smart copy mode switch to prefs (Steve Boddy, LP#1223129)
- * Bug fixes
+ * Make Zoom/Maximize inactive if a single terminal (Egmont
+ Koblinger, LP#1518081)
+ * Add dimming for 256 colour palettes (Egmont Koblinger,
+ LP#1518111)
+ * Update TERM to more modern values (Egmont Koblinger,
+ LP#1518557)
+
+ Bug fixes
* Fix for those not running IBus, where the IBus workaround caused
broken keys in other keymaps set with non-IBus tools (Steve
Boddy, LP#1494606)
@@ -29,6 +37,21 @@ terminator trunk:
* Fix focus dimming so when set to 1.0, it doesn't trash temporary
palette changes by applications. Not needed in gtk3 (Steve Boddy,
LP#1512905)
+ * Correct some British spelt translated strings to American
+ (Egmont Koblinger, LP#1518085)
+ * Fix the palette for inactive terminals after Prefs window
+ (Egmont Koblinger, LP#1518108)
+ * Fix copy on selection to work on already open terminals (Egmont
+ Koblinger, LP#1518109)
+ * Fix warning trying to import the __init__.py file as a plugin
+ (Egmont Koblinger, LP#1518065)
+ * Fix unwanted seperator size change, and increase granularity of
+ dim/transparent sliders (Egmont Koblinger, LP#1518114)
+ * Fix cwd when new term spawned from a symlinked directory - has
+ no impact, just keeping code aligned (Egmont Koblinger,
+ LP#1518554)
+ * Correct terminator_config man page regarding scrollback (Egmont
+ Koblinger, LP#1518559)
terminator 0.98:
* Features
diff --git a/doc/terminator_config.5 b/doc/terminator_config.5
index 411238a9..a1fca6eb 100644
--- a/doc/terminator_config.5
+++ b/doc/terminator_config.5
@@ -418,9 +418,9 @@ Default value: \fBblock\fR
Sets what type of terminal should be emulated.
Default value: \fBxterm\fR
.TP
-.B xterm
+.B term
This translates into the value that will be set for TERM in the environment of your terminals.
-Default value: \fBxterm\fR
+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.
@@ -463,11 +463,11 @@ Whether or not the mouse wheel scrolls alternate screen buffers (man, vim, mutt,
Default value: \fBTrue\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. Be careful with this setting; it's the primary factor in determining how much memory the terminal will use.
+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.
Default value: \fB500\fR
.TP
.B scrollback_infinite
-If this is set to True, scrollback_lines will be ignored and VTE will continue to allocate RAM for scrollback history.
+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
@@ -531,4 +531,5 @@ Window objects may not have a parent attribute. \fBEvery\fR other object must sp
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.
.SH "SEE ALSO"
-.BR gnome\-terminal(1), http://www.voidspace.org.uk/python/configobj.html
+.TP
+\fBterminator\fP(1), http://www.voidspace.org.uk/python/configobj.html
diff --git a/terminatorlib/config.py b/terminatorlib/config.py
index 797bb94c..47355d86 100755
--- a/terminatorlib/config.py
+++ b/terminatorlib/config.py
@@ -217,7 +217,7 @@ DEFAULTS = {
'cursor_shape' : 'block',
'cursor_color' : '#aaaaaa',
'emulation' : 'xterm',
- 'term' : 'xterm',
+ 'term' : 'xterm-256color',
'colorterm' : 'gnome-terminal',
'font' : 'Mono 10',
'foreground_color' : '#aaaaaa',
diff --git a/terminatorlib/optionparse.py b/terminatorlib/optionparse.py
index 1c36ad21..f22e4207 100755
--- a/terminatorlib/optionparse.py
+++ b/terminatorlib/optionparse.py
@@ -49,7 +49,7 @@ def parse_options():
parser.add_option('-v', '--version', action='store_true', dest='version',
help=_('Display program version'))
parser.add_option('-m', '--maximise', action='store_true', dest='maximise',
- help=_('Maximise the window'))
+ help=_('Maximize the window'))
parser.add_option('-f', '--fullscreen', action='store_true',
dest='fullscreen', help=_('Make the window fill the screen'))
parser.add_option('-b', '--borderless', action='store_true',
diff --git a/terminatorlib/plugin.py b/terminatorlib/plugin.py
index 639b6542..33f69623 100755
--- a/terminatorlib/plugin.py
+++ b/terminatorlib/plugin.py
@@ -86,6 +86,8 @@ class PluginRegistry(borg.Borg):
sys.path.remove(plugindir)
continue
for plugin in files:
+ if plugin == '__init__.py':
+ continue
pluginpath = os.path.join(plugindir, plugin)
if os.path.isfile(pluginpath) and plugin[-3:] == '.py':
dbg('PluginRegistry::load_plugins: Importing plugin %s' %
diff --git a/terminatorlib/preferences.glade b/terminatorlib/preferences.glade
index 4bc577a8..b2e37651 100644
--- a/terminatorlib/preferences.glade
+++ b/terminatorlib/preferences.glade
@@ -69,7 +69,7 @@
Black on white
-
Grey on black
+
Gray on black
Green on black
@@ -864,10 +864,12 @@
@@ -2955,7 +2957,8 @@
TrueTruebackground_darkness_scale
- 1
+ 2
+ 2bottom
diff --git a/terminatorlib/prefseditor.py b/terminatorlib/prefseditor.py
index 3f791e72..3b353092 100755
--- a/terminatorlib/prefseditor.py
+++ b/terminatorlib/prefseditor.py
@@ -116,7 +116,7 @@ class PrefsEditor:
'resize_right' : _('Resize the terminal right'),
'move_tab_right' : _('Move the tab right'),
'move_tab_left' : _('Move the tab left'),
- 'toggle_zoom' : _('Maximise terminal'),
+ 'toggle_zoom' : _('Maximize terminal'),
'scaled_zoom' : _('Zoom terminal'),
'next_tab' : _('Switch to the next tab'),
'prev_tab' : _('Switch to the previous tab'),
@@ -861,9 +861,12 @@ class PrefsEditor:
self.config['scrollbar_position'] = value
self.config.save()
- def on_darken_background_scale_change_value(self, widget, scroll, value):
+ def on_darken_background_scale_change_value(self, widget, scroll, _value_not_rounded):
"""Background darkness setting changed"""
- self.config['background_darkness'] = round(value, 2)
+ value = widget.get_value() # This one is rounded according to the UI.
+ if value > 1.0:
+ value = 1.0
+ self.config['background_darkness'] = value
self.config.save()
def on_background_image_filechooser_file_set(self, widget):
@@ -1020,16 +1023,18 @@ class PrefsEditor:
self.config['title_transmit_fg_color'] = color2hex(widget)
self.config.save()
- def on_inactive_color_offset_change_value(self, widget, scroll, value):
+ def on_inactive_color_offset_change_value(self, widget, scroll, _value_not_rounded):
"""Inactive 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_color_offset'] = round(value, 2)
+ self.config['inactive_color_offset'] = value
self.config.save()
- def on_handlesize_change_value(self, widget, scroll, value):
+ def on_handlesize_change_value(self, widget, scroll, _value_not_rounded):
"""Handle size changed"""
- value = int(value)
+ value = widget.get_value() # This one is rounded according to the UI.
+ value = int(value) # Cast to int.
if value > 5:
value = 5
self.config['handle_size'] = value
diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py
index 4f6af869..d9711d52 100755
--- a/terminatorlib/terminal.py
+++ b/terminatorlib/terminal.py
@@ -339,6 +339,10 @@ class Terminal(gtk.VBox):
self.vte.match_remove(self.matches[name])
del(self.matches[name])
+ def maybe_copy_clipboard(self):
+ if self.config['copy_on_selection']:
+ self.vte.copy_clipboard()
+
def connect_signals(self):
"""Connect all the gtk signals and drag-n-drop mechanics"""
@@ -375,10 +379,8 @@ class Terminal(gtk.VBox):
self.vte.connect('drag-data-received',
self.on_drag_data_received, self)
- # FIXME: Shouldn't this be in configure()?
- if self.config['copy_on_selection']:
- self.cnxids.new(self.vte, 'selection-changed',
- lambda widget: self.vte.copy_clipboard())
+ self.cnxids.new(self.vte, 'selection-changed',
+ lambda widget: self.maybe_copy_clipboard())
if self.composite_support:
self.vte.connect('composited-changed', self.reconfigure)
@@ -667,18 +669,39 @@ class Terminal(gtk.VBox):
getattr(self.fgcolor_inactive, "blue")))
colors = self.config['palette'].split(':')
self.palette_active = []
- self.palette_inactive = []
for color in colors:
if color:
newcolor = gtk.gdk.color_parse(color)
- newcolor_inactive = newcolor.copy()
- for bit in ['red', 'green', 'blue']:
- setattr(newcolor_inactive, bit,
- getattr(newcolor_inactive, bit) * factor)
self.palette_active.append(newcolor)
- self.palette_inactive.append(newcolor_inactive)
- self.vte.set_colors(self.fgcolor_active, self.bgcolor,
- self.palette_active)
+ if len(colors) == 16:
+ # RGB values for indices 16..255 copied from vte source in order to dim them
+ shades = [0, 95, 135, 175, 215, 255]
+ for r in xrange(0, 6):
+ for g in xrange(0, 6):
+ for b in xrange(0, 6):
+ newcolor = gtk.gdk.Color(shades[r] / 255.0,
+ shades[g] / 255.0,
+ shades[b] / 255.0)
+ self.palette_active.append(newcolor)
+ for y in xrange(8, 248, 10):
+ newcolor = gtk.gdk.Color(y / 255.0,
+ y / 255.0,
+ y / 255.0)
+ self.palette_active.append(newcolor)
+ self.palette_active = self.palette_active[:255]
+ self.palette_inactive = []
+ for color in self.palette_active:
+ newcolor = gtk.gdk.Color()
+ for bit in ['red', 'green', 'blue']:
+ setattr(newcolor, bit,
+ getattr(color, bit) * factor)
+ self.palette_inactive.append(newcolor)
+ if self.terminator.last_focused_term == self:
+ self.vte.set_colors(self.fgcolor_active, self.bgcolor,
+ self.palette_active)
+ else:
+ self.vte.set_colors(self.fgcolor_inactive, self.bgcolor,
+ self.palette_inactive)
self.set_cursor_color()
if hasattr(self.vte, 'set_cursor_shape'):
self.vte.set_cursor_shape(getattr(vte, 'CURSOR_SHAPE_' +
@@ -1384,6 +1407,7 @@ class Terminal(gtk.VBox):
envv = []
envv.append('TERM=%s' % self.config['term'])
envv.append('COLORTERM=%s' % self.config['colorterm'])
+ envv.append('PWD=%s' % self.cwd)
envv.append('TERMINATOR_UUID=%s' % self.uuid.urn)
if self.terminator.dbus_name:
envv.append('TERMINATOR_DBUS_NAME=%s' % self.terminator.dbus_name)
diff --git a/terminatorlib/terminal_popup_menu.py b/terminatorlib/terminal_popup_menu.py
index 887badc6..f4b8edcf 100755
--- a/terminatorlib/terminal_popup_menu.py
+++ b/terminatorlib/terminal_popup_menu.py
@@ -150,12 +150,16 @@ class TerminalPopupMenu(object):
menu.append(gtk.MenuItem())
if not terminal.is_zoomed():
+ sensitive = not terminal.get_toplevel() == terminal.get_parent()
+
item = gtk.MenuItem(_('_Zoom terminal'))
item.connect('activate', terminal.zoom)
+ item.set_sensitive(sensitive)
menu.append(item)
- item = gtk.MenuItem(_('Ma_ximise terminal'))
+ item = gtk.MenuItem(_('Ma_ximize terminal'))
item.connect('activate', terminal.maximise)
+ item.set_sensitive(sensitive)
menu.append(item)
menu.append(gtk.MenuItem())
diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py
index 5508d406..525748f4 100755
--- a/terminatorlib/terminator.py
+++ b/terminatorlib/terminator.py
@@ -25,6 +25,7 @@ class Terminator(Borg):
groups = None
config = None
keybindings = None
+ last_focused_term = None
origcwd = None
dbus_path = None