0f0aebf26b
remove naive attempt to avoid drawing first vertical pixel line of Canvas::WaveView
...
And add commented out attempt at more subtle attempt to get it right
2015-02-11 21:59:38 -05:00
a992a2e6e0
simplify Canvas::Rectangle rendering to avoid unnecessary nonsense, and remove TimeRectangle
2015-02-11 21:59:38 -05:00
2a5921ecf1
Canvas::Rect::contains() should treat its right/left coordinates as exclusive
2015-02-11 21:59:38 -05:00
34779ee81e
add a sort-of hack to allow us to avoid drawing the first pixel of a waveview when necessary
2015-02-10 19:48:47 -05:00
c679d616f6
correct drawing of rectangle borders.
...
They need to use fractional coordinates, and the border position needed
generalizing for other border widths. See verbose comment for details
2015-02-09 16:41:28 -05:00
736038556f
canvas items must be able to use fractional positions when rendering.
...
This is required to be able to draw precise single pixel lines, as described
in the Cairo FAQ
2015-02-09 16:40:10 -05:00
b4a0136155
tweak to help with uncoalesced renders
2015-02-03 17:35:37 -06:00
9fab39358a
render canvas using the GDK region rather than the GDK area.
...
The region is the un-coalesced set of rectangles that were requested for redraw. The area
is the coalesced single rectangle. In the worst cases, the coalesced rectangle could span
the entire window even though just two pixels in opposite corners were to be redrawn.
There is a problem with the verbose cursor as it is dragged across MIDI tracks. TO BE
FIXED.
2015-02-03 15:38:14 -05:00
ccd881d518
ScrollGroup::covers_{window,canvas}() need to account for possible non-zero position of the group.
...
They also do NOT need to consider scroll offset
2015-01-24 18:48:28 -05:00
e84e1f7403
ScrollGroups are kept in their own list, so ::window_to_canvas() does not need to inspect root group children to find them
...
Conflicts:
libs/canvas/canvas.cc
2015-01-24 18:48:15 -05:00
f282884094
apply Theme > “Show waveform clipping”
...
fixes http://tracker.ardour.org/view.php?id=5589#c15515
2015-01-21 19:35:04 +01:00
d2fa2450aa
use C locale, because POSIX locale is not supported on windows, and operation is undefined. C works on all platforms
2015-01-19 07:29:25 -06:00
a58730e8f9
Revert "Kludgey fix for invisible playhead when scrolled."
...
This reverts commit 8f823388d9
.
2015-01-16 22:06:10 -05:00
fc70b5a9f9
Compute arrow bbox manually to appease crazy canvas.
2015-01-16 22:04:26 -05:00
8f823388d9
Kludgey fix for invisible playhead when scrolled.
...
The problem this is avoiding makes absolutely no sense. Either I'm dumb, or
something is more deeply wrong with scroll group bounding boxes, or both, but I
don't care anymore. This works. Viva release mode.
2015-01-16 21:04:38 -05:00
b759fd5879
Put playhead on top of everything.
...
Achieve this by adding a new hscroll group just for cursors.
That requires a slightly smarter window_to_canvas() to deal with overlapping
sensitive scroll groups. New rule is that scroll groups can overlap, but the
most sensitive one found from the top down will be chosen to translate
coordinates. This basically means don't overlap scroll groups with different
sensitivities.
In the presence of scroll groups, having a canvas-wide window_to_canvas()
and/or canvas_to_window() fundamentally makes no sense. At some point in the
glorious future we should kill those and use only item-relative coordinate
translation.
2015-01-16 19:13:56 -05:00
d194ec9135
Update arrow bbox when geometry changes.
2015-01-16 19:13:56 -05:00
e48ff6b6a0
Fix clipping for scroll groups an offset bbox.
2015-01-16 19:13:56 -05:00
55278fb3b0
Fix mouse event position offset bug.
...
Search scroll groups for event delivery from top to bottom rather than bottom
to top. Overlapping scroll groups still aren't properly supported by the
canvas, but currently all we care about is that the top one gets the event, so
the hscroll group (tempo lines) can be below the hvscroll group (tracks), but
the latter gets events.
2015-01-12 01:05:01 -05:00
0367aa5825
remove cruft (old unused pre-git version files)
2015-01-09 06:11:57 +01:00
ec17b5388f
Fix bounding box of rectangles with wide outlines.
2015-01-08 18:36:10 -05:00
7985624037
Close polygon borders (fix partially drawn hits).
2015-01-08 11:09:38 -05:00
2558e52e22
Fix alleged use of uninitialized variable.
...
Looks like a guaranteed else branch to me, but who am I to argue with gcc?
2014-12-31 17:32:21 -05:00
86242348ec
Fix crash when getting width of item with no bbox.
2014-12-24 16:02:56 -05:00
a494211e73
add ArdourCanvas::change_alpha()
...
Time to move away from rgba macros
2014-12-19 09:53:26 -05:00
74be550698
change Item::visible() to Item::self_visible(); add Item::visible() which returns accurate visibility
...
Child items will be hidden when their ancestors are hidden. The old ::visible() implementation didn't reflect this. In addition,
when changes are made to hidden items (new definition of visible/not visible), don't bother to request redraws, since this will
be done when the item becomes visible again.
2014-12-18 10:30:38 -05:00
9831006c8e
add getters for SVAModifier
2014-12-15 12:06:53 -05:00
995bcd3aa0
fix typo
2014-12-15 09:29:04 -05:00
aa57e9e032
more fixes to SVAModifier constructor(s)
2014-12-15 09:03:52 -05:00
3fa4063d9b
fix up SVAModifier constructors
2014-12-14 23:41:31 -05:00
427b93055f
add SVAModifier to ArdourCanvas color code
2014-12-14 23:34:36 -05:00
624a86c39d
lots more color work, closer and closer to being ready for ... being taken apart again
2014-12-08 22:02:38 -05:00
9ac7ddb31d
remove all explicit button text colors; use contrasting_text_color() instead.
...
Also, use a slightly off-white rather than pure white, which should really be configurable
2014-12-07 13:55:40 -05:00
60f4f5b9d8
Fix inappropriately massive flag font.
2014-12-06 16:07:32 -05:00
9266e7524a
experimental drawing optimization.
...
Q: is bounding_box(); etc more complex than queuing draw?
either way, canvas should eventually switch to
use an optimized OptimizingLookupTable.
2014-12-05 22:40:26 +01:00
207fd04587
include alpha-delta computation in HSV::delta()
2014-12-05 09:01:55 -05:00
db3d42d551
first pass at optimization for low-level canvas code
2014-12-02 05:32:34 -05:00
f190e630ab
Show discrete/toggled automation as stepped line.
2014-11-28 21:15:28 -05:00
ea35595370
Add some newly introduced source files to our MSVC project (cairocanvas)
2014-11-28 14:42:17 +00:00
3d4b1d324e
Fix calculation using uninitialized value.
...
Implicit "this" is the devil.
2014-11-27 04:15:30 -05:00
6edd81e4f6
get correct ::distance() and ::delta() implementations for cases involving achromatics
2014-11-26 18:22:22 +02:00
318a9edab9
massive reworking of color selection implementation
2014-11-26 18:22:22 +02:00
ea5876b836
Remove dead code.
2014-11-25 02:11:44 -05:00
bd577a0663
Avoid possible use of uninitialized values.
...
This could only happen with a broken widget, but it shuts up clang and doesn't
hurt.
2014-11-18 02:55:03 -05:00
333c776e0e
Fix MIDI region keyboard editing (add key handling to canvas).
2014-11-15 02:04:28 -05:00
9a9a8f78ef
fix define
2014-11-13 19:05:58 +01:00
12b715e6fa
tweak canvas on_expose_event() handler to avoid unnecessary save/paint/restore
2014-11-10 20:34:20 -05:00
fdcb792358
further work on new color manipulation code
2014-11-10 20:33:54 -05:00
1317b57221
add required header for compilation
2014-11-10 11:46:17 -05:00
ef56948d4a
add background color property to Canvas::Canvas ; rearrange expose handling and include background fill
...
Conflicts:
libs/canvas/canvas.cc
libs/canvas/canvas/canvas.h
2014-11-10 10:43:25 -05:00