Blob Blame History Raw
From 6d226e8f925c0d6ae5523e3b49a437a498bff0f0 Mon Sep 17 00:00:00 2001
From: Raphael Groner <raphro@fedoraproject.org>
Date: Sat, 9 Jul 2016 18:42:20 +0200
Subject: [PATCH] python3: slots do not work for class attribute

---
 apx/lib/graphics.py | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/apx/lib/graphics.py b/apx/lib/graphics.py
index 79fd95f..c48b865 100644
--- a/apx/lib/graphics.py
+++ b/apx/lib/graphics.py
@@ -194,10 +194,9 @@ class Graphics(object):
        See http://cairographics.org/documentation/pycairo/2/reference/context.html
        for detailed description of the cairo drawing functions.
     """
-    __slots__ = ('context', 'colors', 'extents', 'paths', '_last_matrix',
+    __slots__ = ('context', 'extents', 'paths', '_last_matrix',
                  '__new_instructions', '__instruction_cache', 'cache_surface',
                  '_cache_layout')
-    colors = Colors # pointer to the color utilities instance
 
     def __init__(self, context = None):
         self.context = context
@@ -327,7 +326,7 @@ def set_color(self, color, alpha = 1):
         also consider skipping this operation and specify the color on stroke and
         fill.
         """
-        color = self.colors.parse(color) # parse whatever we have there into a normalized triplet
+        color = Colors.parse(color) # parse whatever we have there into a normalized triplet
         if len(color) == 4 and alpha is None:
             alpha = color[3]
         r, g, b = color[:3]
@@ -1784,9 +1783,6 @@ def __init__(self, interactive = True, framerate = 60,
         if pytweener:
             self.tweener = pytweener.Tweener(0.4, pytweener.Easing.Cubic.ease_in_out)
 
-        #: instance of :class:`ColorUtils` class for color parsing
-        self.colors = Colors
-
         #: read only info about current framerate (frames per second)
         self.fps = None # inner frames per second counter