diff layer/Colour3DPlotLayer.cpp @ 287:cd2492c5fe45

* Add SingleColourLayer to manage colours for layers that have a single predominant colour (i.e. most of them).
author Chris Cannam
date Thu, 12 Jul 2007 16:14:59 +0000
parents 9dd432665059
children c0b9eec70639
line wrap: on
line diff
--- a/layer/Colour3DPlotLayer.cpp	Wed Jul 11 20:46:37 2007 +0000
+++ b/layer/Colour3DPlotLayer.cpp	Thu Jul 12 16:14:59 2007 +0000
@@ -343,7 +343,7 @@
     int ch = h - 20;
     if (ch > 20 && m_cache) {
 
-        paint.setPen(Qt::black);
+        paint.setPen(v->getForeground());
         paint.drawRect(4, 10, cw - 8, ch - 19);
 
         for (int y = 0; y < ch - 20; ++y) {
@@ -354,7 +354,7 @@
         }
     }
 
-    paint.setPen(Qt::black);
+    paint.setPen(v->getForeground());
 
     int count = v->height() / paint.fontMetrics().height();
     int step = m_model->getHeight() / count;
@@ -643,7 +643,7 @@
 
 	    if (illuminate) {
 		if (r.contains(illuminatePos)) {
-		    paint.setPen(Qt::black);//!!!
+		    paint.setPen(v->getForeground());
 		}
 	    }
             
@@ -660,7 +660,7 @@
 		    float value = m_model->getValueAt(scx, sy);
 		    sprintf(labelbuf, "%06f", value);
 		    QString text(labelbuf);
-		    paint.setPen(Qt::white);
+		    paint.setPen(v->getBackground());
 		    paint.drawText(rx0 + 2,
 				   ry0 - h / sh - 1 + 2 + paint.fontMetrics().ascent(),
 				   text);