diff options
author | Robin Gareus <robin@gareus.org> | 2015-09-05 15:47:00 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2015-09-05 15:47:00 +0200 |
commit | 42f0142bb9d7559ef385e72499ee03ddd8f5b371 (patch) | |
tree | e50fe4c48090aefcb413b16245f84548ce741586 /libs/gtkmm2ext | |
parent | 1c9bb7de66dc9152f75cd907ded0f324e3d24626 (diff) |
remove a float loop counter
Diffstat (limited to 'libs/gtkmm2ext')
-rw-r--r-- | libs/gtkmm2ext/fastmeter.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/gtkmm2ext/fastmeter.cc b/libs/gtkmm2ext/fastmeter.cc index 3d28253c41..4183d372ee 100644 --- a/libs/gtkmm2ext/fastmeter.cc +++ b/libs/gtkmm2ext/fastmeter.cc @@ -240,7 +240,10 @@ FastMeter::generate_meter_pattern ( cairo_set_line_width(tc, 1.0); cairo_set_source_rgba(tc, .0, .0, .0, 0.4); //cairo_set_operator (tc, CAIRO_OPERATOR_SOURCE); - for (float y=0.5; y < height; y+= 2.0) { + for (int i = 0; float y = 0.5 + i * 2.0; ++i) { + if (y >= height) { + break; + } cairo_move_to(tc, 0, y); cairo_line_to(tc, width, y); cairo_stroke (tc); |