comparison layer/SingleColourLayer.cpp @ 299:5c59c433b358

* Show colour swatch next to layer name in pane (if available) * Fix for incorrect layer name prefix handling (was making some layers appear to have the same model name in cases where the model names differed by the final character only)
author Chris Cannam
date Wed, 05 Sep 2007 15:17:15 +0000
parents 860f9ada4327
children c0b9eec70639
comparison
equal deleted inserted replaced
298:226cb289bdf4 299:5c59c433b358
29 m_colourExplicitlySet(false) 29 m_colourExplicitlySet(false)
30 { 30 {
31 setDefaultColourFor(0); 31 setDefaultColourFor(0);
32 } 32 }
33 33
34 QPixmap
35 SingleColourLayer::getLayerPresentationPixmap(QSize size) const
36 {
37 return ColourDatabase::getInstance()->getExamplePixmap(m_colour, size);
38 }
39
34 bool 40 bool
35 SingleColourLayer::hasLightBackground() const 41 SingleColourLayer::hasLightBackground() const
36 { 42 {
37 bool dark = ColourDatabase::getInstance()->useDarkBackground(m_colour); 43 bool dark = ColourDatabase::getInstance()->useDarkBackground(m_colour);
38 return !dark; 44 return !dark;