From 6f9955eb6a8332bee5fa38e0eb4e215f53bff786 Mon Sep 17 00:00:00 2001 From: Chris Jones Date: Mon, 19 Jan 2009 14:45:08 +0000 Subject: [PATCH] H9TRANS debugging, should help diagnose weird transparency issues --- terminatorlib/terminator.py | 1 + terminatorlib/terminatorterm.py | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 83617363..3e6388c7 100755 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -247,6 +247,7 @@ class Terminator: # Set RGBA colormap if possible so VTE can use real alpha # channels for transparency. if self.conf.enable_real_transparency: + dbg ('H9TRANS: Enabling real transparency') self.enable_rgba(True) # Start out with just one terminal diff --git a/terminatorlib/terminatorterm.py b/terminatorlib/terminatorterm.py index dade1df2..81a4d46c 100755 --- a/terminatorlib/terminatorterm.py +++ b/terminatorlib/terminatorterm.py @@ -578,13 +578,18 @@ text/plain # Set our background image, transparency and type # Many thanks to the authors of gnome-terminal, on which this code is based. background_type = self.conf.background_type + dbg ('H9TRANS: Configuring background type as: %s' % background_type) # set background image settings if background_type == "image": + dbg ('H9TRANS: Setting background image to: %s' % self.conf.background_image) self._vte.set_background_image_file (self.conf.background_image) + dbg ('H9TRANS: Setting background image scroll to: %s' % self.conf.scroll_background) self._vte.set_scroll_background (self.conf.scroll_background) else: + dbg ('H9TRANS: Unsetting background image') self._vte.set_background_image_file('') + dbg ('H9TRANS: Unsetting background image scrolling') self._vte.set_scroll_background(False) # set transparency for the background (image) @@ -593,15 +598,21 @@ text/plain self._vte.set_background_tint_color (bg_color) self._vte.set_background_saturation(1 - (self.conf.background_darkness)) opacity = int(self.conf.background_darkness * 65535) + dbg ('H9TRANS: Set background tint color to: %s' % bg_color) + dbg ('H9TRANS: Set background saturation to: %s' % (1 - (self.conf.background_darkness))) else: + dbg ('H9TRANS: Set background saturation to: 1') self._vte.set_background_saturation(1) if self._composited_support: + dbg ('H9TRANS: Set opacity to: %s' % opacity) self._vte.set_opacity(opacity) if self._composited_support and not self._vte.is_composited(): + dbg ('H9TRANS: Set background transparency to: %s' % (background_type == "transparent")) self._vte.set_background_transparent (background_type == "transparent") else: + dbg ('H9TRANS: Set background transparency to: False, hard') self._vte.set_background_transparent (False) # Set our cursor blinkiness