add circle-ticks to the midi-metric area
[ardour.git] / gtk2_ardour / meter_strip.cc
index b9121e7418dead7a00d04b05c01aa1cb36b209ad..7c468ec698e6a6e7d96d6c173a1caa1bc8538cbc 100644 (file)
@@ -453,6 +453,7 @@ MeterStrip::render_metrics (Gtk::Widget& w, vector<DataType> types)
                }
 
                char buf[32];
+               gint pos;
 
                for (vector<int>::const_iterator j = points.begin(); j != points.end(); ++j) {
 
@@ -465,10 +466,15 @@ MeterStrip::render_metrics (Gtk::Widget& w, vector<DataType> types)
                        case DataType::MIDI:
                                fraction = *j / 127.0;
                                snprintf (buf, sizeof (buf), "%3d", *j);
+                               pos = height - (gint) rintf (height * fraction);
+
+                               cairo_arc(cr, 2, pos, 1.0, 0, 2 * M_PI);
+                               cairo_fill(cr);
+                               cairo_stroke (cr);
                                break;
                        }
 
-                       gint const pos = height - (gint) rintf (height * fraction);
+                       pos = height - (gint) rintf (height * fraction);
                        layout->set_text(buf);
 
                        /* we want logical extents, not ink extents here */