Make transparency support much saner by making it much simpler. This means that enable_real_transparency being False doesn't prevent transparency from working, it just means it falls back to the fake transparency. Closes LP #328994

This commit is contained in:
Chris Jones 2009-02-13 10:43:11 +00:00
parent 64a52bcb78
commit 26e6eba2b5
1 changed files with 4 additions and 9 deletions

View File

@ -160,6 +160,7 @@ class TerminatorTerm (gtk.VBox):
self._vte = vte.Terminal ()
if not hasattr(self._vte, "set_opacity") or not hasattr(self._vte, "is_composited"):
self._composited_support = False
dbg ('H9TRANS: composited_support: %s' % self._composited_support)
#self._vte.set_double_buffered(True)
self._vte.set_size (80, 24)
self._vte._expose_data = None
@ -690,15 +691,9 @@ text/plain
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"))
background_transparent = (background_type == "transparent")
else:
dbg ('H9TRANS: Set background transparency to: False, hard')
background_transparent = False
dbg ("Setting VTE transparency to: %s" % background_transparent)
self._vte.set_background_transparent (background_transparent)
if background_type == "transparent":
if not self.conf.enable_real_transparency:
self._vte.set_background_transparent (True)
# Set our cursor blinkiness
self._vte.set_cursor_blinks (self.conf.cursor_blink)