summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_rulers.cc
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2008-02-21 19:51:41 +0000
committerDavid Robillard <d@drobilla.net>2008-02-21 19:51:41 +0000
commit4b5ee47d4471df0481ca7f52a0991c098cb8ae1d (patch)
tree899f7fe31516551647f4643b58d8e15c658349e6 /gtk2_ardour/editor_rulers.cc
parent4afabf43e578013eb4978ad9bbc27bf7595f4c18 (diff)
Fix ruler scale on initial view (apply patch from nick_m).
git-svn-id: svn://localhost/ardour2/branches/3.0@3101 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/editor_rulers.cc')
-rw-r--r--gtk2_ardour/editor_rulers.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/gtk2_ardour/editor_rulers.cc b/gtk2_ardour/editor_rulers.cc
index b18e917c85..cb3ef7d45e 100644
--- a/gtk2_ardour/editor_rulers.cc
+++ b/gtk2_ardour/editor_rulers.cc
@@ -802,8 +802,8 @@ Editor::update_ruler_visibility ()
time_canvas_event_box.show_all();
time_button_frame.show_all();
- compute_current_bbt_points (leftmost_frame, leftmost_frame + (nframes_t)(canvas_width * frames_per_unit));
- compute_bbt_ruler_scale (leftmost_frame, leftmost_frame + (nframes_t)(canvas_width * frames_per_unit));
+ compute_current_bbt_points (leftmost_frame, leftmost_frame + (nframes_t)(edit_packer.get_width() * frames_per_unit));
+ compute_bbt_ruler_scale (leftmost_frame, leftmost_frame + (nframes_t)(edit_packer.get_width() * frames_per_unit));
redisplay_tempo (false);
}
@@ -833,11 +833,11 @@ Editor::compute_fixed_ruler_scale ()
}
if (ruler_shown[ruler_metric_smpte]) {
- set_smpte_ruler_scale (leftmost_frame, leftmost_frame + (canvas_width * frames_per_unit) );
+ set_smpte_ruler_scale (leftmost_frame, leftmost_frame + (edit_packer.get_width() * frames_per_unit) );
}
if (ruler_shown[ruler_metric_minsec]) {
- set_minsec_ruler_scale (leftmost_frame, leftmost_frame + (canvas_width * frames_per_unit) );
+ set_minsec_ruler_scale (leftmost_frame, leftmost_frame + (edit_packer.get_width() * frames_per_unit) );
}
}