From 6019f06bdf919e1d95dd0912116cdec0834af8db Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Tue, 20 May 2014 23:08:15 -0400 Subject: different approach to independent scrolling, involving ArdourCanvas::ScrollGroup The idea now is that a scroll group item can be added to the canvas which will causes its children to scroll in either or both directions (horizontal or vertical). There are few complications: the position() of the ScrollGroup is ambiguous depending on whether you want it with scroll taken into account or not, so Item::canvas_position() was added, which defaults to the same value as Item::position() but is overridden by ScrollGroup to return the position independent of scrolling. This method is used when translating between item/canvas/window coordinate systems. Note that the basic idea is that we MOVE the scroll group when a scroll happens. This mirrors what happens in the GnomeCanvas, where Nick Mainsbridge came up with a great idea that allowed unification of the time bar and track canvases. --- libs/canvas/wscript | 1 + 1 file changed, 1 insertion(+) (limited to 'libs/canvas/wscript') diff --git a/libs/canvas/wscript b/libs/canvas/wscript index 913f8298fa..d0cbfc882f 100644 --- a/libs/canvas/wscript +++ b/libs/canvas/wscript @@ -50,6 +50,7 @@ canvas_sources = [ 'polygon.cc', 'rectangle.cc', 'root_group.cc', + 'scroll_group.cc', 'stateful_image.cc', 'text.cc', 'types.cc', -- cgit v1.2.3