Changeset 11440:cb2508213612 in orange


Ignore:
Timestamp:
03/22/13 15:02:52 (13 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Fixed default colors for nodes in the canvas.

Location:
Orange/OrangeCanvas
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • Orange/OrangeCanvas/canvas/items/nodeitem.py

    r11411 r11440  
    5252    Create and return a default palette for a node. 
    5353    """ 
    54     return create_palette(QColor(NAMED_COLORS["light-orange"]), 
    55                           QColor(NAMED_COLORS["orange"])) 
     54    return create_palette(QColor(NAMED_COLORS["light-yellow"]), 
     55                          QColor(NAMED_COLORS["yellow"])) 
    5656 
    5757 
  • Orange/OrangeCanvas/registry/__init__.py

    r11418 r11440  
    3838     "yellow": "#F0EC4F", 
    3939     } 
     40 
     41 
     42# default color when the category does not provide it 
     43DEFAULT_COLOR = "light-yellow" 
    4044 
    4145 
  • Orange/OrangeCanvas/registry/qt.py

    r11393 r11440  
    2121from ..resources import icon_loader 
    2222 
    23 from . import cache, NAMED_COLORS 
     23from . import cache, NAMED_COLORS, DEFAULT_COLOR 
    2424 
    2525 
     
    219219            background = desc.background 
    220220        else: 
    221             background = "light-yellow" 
     221            background = DEFAULT_COLOR 
    222222 
    223223        background = NAMED_COLORS.get(background, background) 
     
    254254        elif category.background: 
    255255            background = category.background 
     256        else: 
     257            background = DEFAULT_COLOR 
    256258 
    257259        if background is not None: 
Note: See TracChangeset for help on using the changeset viewer.