[Bugs] #1592 UNSP: NEW FEATURE: enhanced color selector

Sugar Labs Bugs bugtracker-noreply at sugarlabs.org
Mon Aug 9 11:31:20 EDT 2010


#1592: NEW FEATURE: enhanced color selector
------------------------------------------+---------------------------------
    Reporter:  walter                     |          Owner:  tomeu      
        Type:  enhancement                |         Status:  new        
    Priority:  Unspecified by Maintainer  |      Milestone:  0.90       
   Component:  sugar                      |        Version:  Unspecified
    Severity:  Unspecified                |       Keywords:  r!         
Distribution:  Unspecified                |   Status_field:  Assigned   
------------------------------------------+---------------------------------
Changes (by erikos):

  * keywords:  r? => r!


Comment:

 Walter, I prefer the new approach of the patch, looks much better now.
 However, something is still left to do...

 {{{

 >>> from sugar.graphics import xocolor
 >>> c = xocolor.get_radom_color()
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
 AttributeError: 'module' object has no attribute 'get_radom_color'
 >>> c = xocolor.get_random_color()
 >>> c
 '#FF8F00,#AC32FF'
 >>> c.get_next_stroke_color()
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
 AttributeError: 'str' object has no attribute 'get_next_stroke_color'
 >>> get_next_stroke_color(c)
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
 NameError: name 'get_next_stroke_color' is not defined
 >>> xocolor.get_next_stroke_color(c)
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
   File "/home/erikos/sugar-jhbuild-master/install/lib/python2.6/site-
 packages/sugar/graphics/xocolor.py", line 242, in get_next_stroke_color
     current_index = _get_index(color)
   File "/home/erikos/sugar-jhbuild-master/install/lib/python2.6/site-
 packages/sugar/graphics/xocolor.py", line 311, in _get_index
     if colors[index] == [color.stroke, color.fill]:
 AttributeError: 'str' object has no attribute 'stroke'
 }}}

-- 
Ticket URL: <http://bugs.sugarlabs.org/ticket/1592#comment:27>
Sugar Labs <http://sugarlabs.org/>
Sugar Labs bug tracking system


More information about the Bugs mailing list