summaryrefslogtreecommitdiff
path: root/libs/canvas/canvas.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2014-06-17 11:34:10 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2014-06-17 11:34:54 -0400
commitf98e0a07075e9f003369e8d4b597d4a6c9a63fb7 (patch)
tree93f97b78e23bccc935f23d2be73ca5370a7ec3be /libs/canvas/canvas.cc
parentb4dd5b737fe7c6c8c01c37ca8f78ad7624262cb7 (diff)
use a different approach for indicating expose rects (from robin gareus). #ifdef'd out by default
Diffstat (limited to 'libs/canvas/canvas.cc')
-rw-r--r--libs/canvas/canvas.cc13
1 files changed, 9 insertions, 4 deletions
diff --git a/libs/canvas/canvas.cc b/libs/canvas/canvas.cc
index 07f52b0412..3d4f9e0c5d 100644
--- a/libs/canvas/canvas.cc
+++ b/libs/canvas/canvas.cc
@@ -110,10 +110,15 @@ Canvas::render (Rect const & area, Cairo::RefPtr<Cairo::Context> const & context
_root.render (*draw, context);
- // This outlines the rect being rendered, after it has been drawn.
- // context->rectangle (draw->x0, draw->y0, draw->x1 - draw->x0, draw->y1 - draw->y0);
- // context->set_source_rgba (1.0, 0, 0, 1.0);
- // context->stroke ();
+#if 0
+ // This transparently colors the rect being rendered, after it has been drawn.
+ double r = (random() % 65536) /65536.0;
+ double g = (random() % 65536) /65536.0;
+ double b = (random() % 65536) /65536.0;
+ context->rectangle (draw->x0, draw->y0, draw->x1 - draw->x0, draw->y1 - draw->y0);
+ context->set_source_rgba (r, g, b, 0.25);
+ context->fill ();
+#endif
}