[gedit] pythonconsole: Remove deprecated function



commit 95641b023c8858bfa49776859f21550b37540b38
Author: Sagar Ghuge <ghugesss gmail com>
Date:   Fri Nov 7 18:53:06 2014 +0530

    pythonconsole: Remove deprecated function
    
    Use GdkRGBA instead of GdkColor.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=739648

 plugins/pythonconsole/pythonconsole/config.py |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/plugins/pythonconsole/pythonconsole/config.py b/plugins/pythonconsole/pythonconsole/config.py
index 1690e31..484e6f5 100644
--- a/plugins/pythonconsole/pythonconsole/config.py
+++ b/plugins/pythonconsole/pythonconsole/config.py
@@ -57,10 +57,11 @@ class PythonConsoleConfigWidget(object):
 
     @staticmethod
     def set_colorbutton_color(colorbutton, value):
-        color = Gdk.color_parse(value)
+        rgba = Gdk.RGBA()
+        parsed = rgba.parse(value)
 
-        if color is not None:
-            colorbutton.set_color(color)
+        if parsed:
+            colorbutton.set_rgba(rgba)
 
     def on_colorbutton_command_color_set(self, colorbutton):
         self._settings.set_string(self.CONSOLE_KEY_COMMAND_COLOR,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]