1325 @param prefClass preferences class used as the storage area |
1325 @param prefClass preferences class used as the storage area |
1326 @return the requested editor colour |
1326 @return the requested editor colour |
1327 """ |
1327 """ |
1328 col = prefClass.settings.value("Editor/Colour/" + key) |
1328 col = prefClass.settings.value("Editor/Colour/" + key) |
1329 if col is not None: |
1329 if col is not None: |
|
1330 if len(col) == 9: |
|
1331 # color string with alpha |
|
1332 col = "#" + col[3:] |
1330 return QtGui.QColor(col) |
1333 return QtGui.QColor(col) |
1331 else: |
1334 else: |
1332 return prefClass.editorColourDefaults[key] |
1335 return prefClass.editorColourDefaults[key] |
1333 |
1336 |
1334 def setEditorColour(key, value, prefClass = Prefs): |
1337 def setEditorColour(key, value, prefClass = Prefs): |