Paul Davis
f9f0bfe6ed
new TrackingText canvas item, to resolve conceptual issues with the Editor::VerboseCursor
2014-08-17 18:53:52 -04:00
Tim Mayberry
dbcc1f1d39
Rename PBD::find_file_in_search_path to just PBD::find_file
...
saves a bit of typing and not necessary if you look at how it is used.
Conflicts:
gtk2_ardour/about.cc
gtk2_ardour/session_dialog.cc
libs/pbd/system_exec.cc
2014-08-17 18:36:02 -04:00
Ben Loftis
17b601a9f3
last piece of scroll-wheel checkin, oops
2014-08-17 18:10:21 -04:00
Ben Loftis
d0f41a4f5e
add scroll wheel handler to canvas
2014-08-17 18:10:15 -04:00
Paul Davis
d893b493d6
return of the zero line
2014-08-17 18:07:37 -04:00
Paul Davis
1b58dd6ecf
revert drawing of rectified waves back to previous approach since it (might be) slightly more efficient and is simpler to understand; add comments
2014-08-17 18:07:32 -04:00
Paul Davis
87cc9f7d4f
completely rethink waveform rendering (again)
...
There are 3 possible components to draw at each x-axis position: the waveform "line", the zero line and an outline/clip indicator.
We have to decide which of the 3 to draw at each position, pixel by pixel. This makes the rendering less efficient but it is
the only way I can see to do this correctly.
2014-08-17 18:07:24 -04:00
Paul Davis
e0bceb3e4e
fix logic error that meant one side of the waveform outline is not drawn; draw zero line before outline, for better effects with low amplitude waves
2014-08-17 18:07:14 -04:00
Paul Davis
9ebbcdde09
Canvas::Group was removed
2014-08-17 18:04:05 -04:00
Paul Davis
28fdc71d70
more canvas refactoring.
...
Remove Canvas::Layout, use Canvas::Container for the same purpose, move child-rendering into Item::render_children() so that it
could theoretically be used by any derived type.
2014-08-17 17:44:17 -04:00
Paul Davis
72ab6f6fe5
add missing new files for canvas redesign
2014-08-17 17:44:12 -04:00
Paul Davis
f11ad4f901
explicitly qualify cast to ArdourCanvas::Container so that it works.
...
I assume that gcc is failing to complain about ambiguity with Gtk::Container even though there should
really be no ambiguity
2014-08-17 17:43:51 -04:00
Paul Davis
98aa604aa0
refactor Canvas so that all Items have children; add Container abstract base class; rename Group as "Layout" and retain only drawing semantics
2014-08-17 17:42:59 -04:00
Paul Davis
1ba94eab60
if we're not going to notify parents of bbox changes while an item is hidden, we need to remind it when the item is hidden or shown
2014-08-17 16:24:21 -04:00
Paul Davis
4d4851cffc
a whole slew of changes related to centralizing and rationalizing cursor management.
...
Debugging output left in place to help address the reports that will come in as people test this more
2014-08-17 16:23:52 -04:00
nick_m
929a787b71
Canvas tweaks.
...
* Only queue a draw for changed items that are set visible and in-window.
2014-08-17 16:23:37 -04:00
Paul Davis
3ef2430ae0
a set of 3 fixes that cure Canvas::Text leaving dirty pixels when being dragged. or might not - testing is non-deterministic, which is alarming
2014-08-17 15:34:13 -04:00
Paul Davis
df72a6ca25
use a different approach for indicating expose rects (from robin gareus). #ifdef'd out by default
2014-08-17 15:34:05 -04:00
nick_m
36a93b0d18
Cache entries are now region colour aware.
2014-08-17 15:33:22 -04:00
Paul Davis
ab47194ee8
comment correction regarding Canvas::visible_area()
2014-08-17 15:29:02 -04:00
Paul Davis
465456dbf4
initialize _scroll_parent in Canvas::item
2014-08-17 15:28:56 -04:00
Robin Gareus
c56d3ad812
initialize uninitialized variable
2014-08-17 15:28:03 -04:00
John Emmas
37a2ac8617
Add newly introduced sources to our MSVC projects
2014-08-17 15:26:34 -04:00
John Emmas
cb0abfb008
Remove no longer needed sources from MSVC projects
2014-08-17 15:26:28 -04:00
Paul Davis
452cf1db35
change Canvas heirarchy and constructors
...
Items no longer need a parent group (they require a Canvas pointer instead), so all constructors have been rationalized
and have two variants, one with a parent and one with a canvas.
All Items now inherit from Fill and Outline, to banish diagonal inheritance and virtual base classes and all that.
There were zero changes to the Ardour GUI arising from these changes.
2014-08-17 15:08:56 -04:00
Paul Davis
3cec76834e
remove drag handle canvas object - it was just a stupid unfinished experiment
2014-08-17 15:08:46 -04:00
Paul Davis
1a3596b071
derive ArdourCanvas::Ruler from Rectangle
2014-08-17 15:08:33 -04:00
Paul Davis
a7a75f105a
remove hard-coded colors
2014-08-17 15:08:19 -04:00
Paul Davis
473bcc3fa6
many fixes and improvements for a now-working ArdourCanvas::Ruler item
2014-08-17 15:06:11 -04:00
Paul Davis
126a293ab9
add ruler.cc to canvas wscript
2014-08-17 15:06:06 -04:00
Paul Davis
def1f12164
add Ruler to Canvas fwd.h
2014-08-17 15:05:59 -04:00
Paul Davis
76b9ad2294
add initial (untested) implementation of canvas ruler item
2014-08-17 15:05:48 -04:00
Paul Davis
592146822a
fix Canvas::LineSet implementation to support horizontal and vertical linesets
2014-08-17 15:00:23 -04:00
Paul Davis
6f38ff5c3c
remove global canvas scroll offset, to provide no-scroll-parent == no-scroll behaviour
2014-08-17 14:58:10 -04:00
Paul Davis
f07af61132
fix borked logic controlling whether/when to draw clip/outline pixels/lines in waveviews
2014-08-17 14:56:44 -04:00
nick_m
017a4a8a87
Use global clip level from prefs. Restore clip colour, \
2014-08-17 14:56:27 -04:00
Paul Davis
f188ecb954
when delivering enter/leave events to canvas items, ensure that the event coordinates are in canvas space, not window space
...
This fixes a variety of borkage in the canvas at present
2014-08-17 14:56:14 -04:00
Paul Davis
fc9447f2b5
add Item::canvas_origin() for convenience
2014-08-17 14:56:09 -04:00
nick_m
aebd5863f0
Use a dumb cache for waveview ImageSurfaces. This halves the size of the
...
previous one, but usually ends up using three of them at the current
CACHE_HIGH_WATER setting.
Should result in a smaller memory footprint for sessions with
multiple copies of nearby audio segments (electronic style).
The downside is the larger memory footprint for linear recording
sessions if CACHE_HIGH_WATER > 1 (1 giving a max of two
half - sized cache entries per audio stream).
2014-08-17 14:55:20 -04:00
Paul Davis
07cfa9e163
When rendering a Canvas::Rectangle take its _position into account, even though in general this is always (0,0) within its parent
2014-08-17 14:50:37 -04:00
Paul Davis
874ac355e7
clip rendering of ScrollGroup to just the part of the canvas covered by the scroll group.
...
This stops tracks from appearing to scroll up under the rulers, among other things.
2014-08-17 14:50:12 -04:00
Paul Davis
bbf037c4a3
fix problems with expose/redraws from canvas where requested area goes way outside the integer range allowed by GTK/GDK
2014-08-17 14:49:34 -04:00
Paul Davis
df24b1ab8d
remove debugging output
2014-08-17 14:44:31 -04:00
Paul Davis
c926ca2b6b
basic, initial structure for canvas widget item
2014-08-17 14:44:25 -04:00
John Emmas
83d0b6cd7a
Add newly introduced sources to MSVC project
...
(scroll_group stuff)
2014-08-17 13:46:21 -04:00
Paul Davis
fdbb93ea3c
merge onecanvas and cairocanvas branches, and manually resolve conflicts, including rounding in item_to_window() methods
2014-08-17 13:44:57 -04:00
Paul Davis
e8e3460665
more profound changes to canvas scrolling, in particular find appropriate ScrollGroup for Canvas::{window,canvas}_to_{canvas,window}()
...
Conflicts:
gtk2_ardour/editor_mouse.cc
2014-08-17 13:43:52 -04:00
Paul Davis
0bfbb030fa
fix missing leftover Canvas::pick_current_item() which was confusing button release event coordinates
2014-08-17 13:39:19 -04:00
Paul Davis
f60e579653
use window-based coordinates when picking current item so that we get per-item (per-scroll-group,really) computation of position and coverage.
2014-08-17 13:39:15 -04:00
Paul Davis
bed0c78432
various changes to get independent scrolling to work better in canvas. mostly tweaks relating to how scroll offsets are used during rendering.
...
Event handling offsets still require work.
2014-08-17 13:39:10 -04:00