Commit Graph

992 Commits

Author SHA1 Message Date
bf87916fb1 tempo display: further simplifications to handling map changes
When a tempo map change originates from a drag, we know the required redraws have
already been done. Use a new bool member, ignore_map_change, to tell the Editor
to ignore the map change signal. For all other map changes, do the full reset.
2022-06-28 10:16:31 -06:00
6dfaac9e94 redesign the mechanisms for updating tempo/meter display during drags and other map changes
We now simply move markers during drags, and do not seek to create/delete markers.

When the map is changed, we rebuild the markers from scratch. This might need optimization to avoid doing
when the editor itself changed the map.
2022-06-27 22:21:27 -06:00
b2d553cc51 editor: fix HitCreateDrag to (a) not crash (b) use the right length (c) snap correctly 2022-06-22 13:31:08 -06:00
d47b581cbb remove RegionRippleDrag
This used to be a distinct kind of drag, but ended up being refactored into
something that happens during a regular drag. Has not been used in quite some time.
2022-06-21 15:52:16 -06:00
de2c553e1a improvements to BBT marker dialog appearance and behavior 2022-06-03 13:20:13 -06:00
b806ccf373 timestretching: fix inaccuracies in generated length
The design ignored the ratio computed by the drag interaction, and relied on getting the stretch
ratio from the dialog. This truncated the actual ratio, leading to (relatively) small errors
in the length of the generated region.

Now, if the ratio provided by the drag is not (1/1) (i.e. a single click while in timefx mode)
then the percentage stretch spinner is marked insensitive and the stretch ratio is taken from
the given ratio. For single clicks, the user can still adjust the percentage as they wish
2022-05-31 12:36:54 -06:00
265f5d8342 numerous fixes for meter marker drag 2022-05-30 21:14:57 -06:00
7168139861 abort reversible command if add-bbt-marker is cancelled 2022-05-29 14:41:55 -06:00
fdd634f530 add ctrl-drag on tempo bar/ruler to adjust tempo more directly 2022-05-29 14:19:27 -06:00
e2e6274956 libardour: change API of Session::request_locate() to include "force" argument (GUI edition) 2022-05-27 18:49:23 -06:00
69ee83e6ce require explicit time domain for most region-centric drags
This removed one #warning nutempo line.
2022-05-27 15:57:14 -06:00
399a5b3f25 convert use of operator* for tim::line types with ::scale(ratio_t) (GUI edition) 2022-05-27 12:47:44 -06:00
Mads Kiilerich
cc6a1e2d6f gtk2_ardour/editor_drag.cc: fix confusing newline 2022-05-24 17:15:37 -06:00
2ec6d45d6d temporal: remove the concept of a time domain for the tempo map (GUI edition) 2022-05-24 17:10:25 -06:00
1a44e612e9 ctrl-dragging a tempo mark uses horizontal, not vertical motion to adjust tempo 2022-05-24 17:10:25 -06:00
d8ba73f542 temporal: change "clamped" terminology to "continuing" (since that's what the GUI calls it) (GUI edition) 2022-05-23 08:07:08 -06:00
e0f9f11dfc automation-range-drag: if lane is empty, use current value for guard points
* in the case where there are no existing automation points, then
 initiating an automation range drag  (select range, switch to Draw)
 should initialize the line at the current knob position
2022-05-16 07:16:25 -05:00
f7abe8dacd fix: RegionMotionDrag actions are always rippling to other tracks
* if we aren't in RippleAll, you should only ripple the regions
 on the same track as the grabbed region
2022-05-14 14:16:21 -05:00
6f973af1e1 tempo end drag: make this work with new implementation 2022-05-13 19:05:13 -06:00
db17a46498 tempo twist drag: changes to work with new (old) implementation 2022-05-13 19:05:13 -06:00
a60412373a tempo map editing: re-enable stretch tempo drag 2022-05-13 19:05:13 -06:00
83d0892777 when drawing notes, the grid should be scaled to the zoom scale
this prevents the case where have enabled snap, and you add a note that
 appears to be on a bar line. but actually it is {some Grid value} off,
 it just looks right because of pixel rounding.
2022-05-11 11:45:33 -05:00
a60dfc19d2 take Snap enablement into account when drawing new notes
* snap_to_bbt assumes that snap is enabled and you want to snap to bbt
* snap_to() is the generic form to snap to the user's snap+grid settings
2022-05-11 11:38:54 -05:00
de9f18b4f9 when Drawing MIDI notes, enforce a minimum length
This fixes the issue where you click to create a note, but move the mouse
 just a little, resulting in a note of invisibly small length

Do the calculation in ::motion so it displays the final
 size while you are dragging. "what you see is what you will get"
2022-05-10 20:00:26 -05:00
5310e1e099 create_note: fix a few thinkos which resulted in nested undo 2022-05-10 15:47:56 -05:00
9fcf8b3a11 midi_region_view: rename commit_resizing -> finish_resizing
* 'commit' suggests that this function would commit an undo record
2022-05-10 15:47:48 -05:00
6f9aa3677f tempo markers: ctrl-drag now alters tempo for that section 2022-05-10 09:46:08 -06:00
66a3513dbd remove copy option for TempoMarkerDrag
This just seems like a dumb UI to implement. Drag-copying tempo markers is not a thing
2022-05-10 09:46:08 -06:00
eff34f2e1b use editor tempo editing API rather than TempoMap API 2022-05-10 09:46:08 -06:00
b5487415ec editing: a partiaally implemented version of TempoTwistDrag, to be completed. 2022-05-02 16:47:23 -06:00
0a99d67dac meter marker drag: better initialization of map member 2022-05-02 11:50:34 -06:00
90a38a2b31 fix tempo marker drag crash caused by use of uninitialized map member 2022-05-02 11:49:43 -06:00
789abc561d MIDI editing: fix selection during note resize drags
The ::start_drag() implementation now defers add/extend selection logic to
MidiRegionView::note_selected(), and drops the original limitation that we did
not do extend-selection on button press, only button release.
2022-04-17 22:18:31 -06:00
7293904e53 use new TempoCommand when putting tempo map ops into undo/redo history 2022-04-08 11:58:04 -06:00
883a44e6a4 temporal: TempoMap::use() returns a const ptr to enforce semantics (GUI version)
This commit leaves two issues outstanding:

1. unclear/ugly semantics for drag operations that reset the GUI thread's tempo map to the writable copy
2. undo/redo for the tempo map

These will be addressed in future commits
2022-04-08 11:58:04 -06:00
1a8b80e56e drop experimental use of RegionView::DisplaySuspender during trim drags 2022-04-05 20:52:10 -06:00
582661dbd0 as an experiment, prevent redisplay of (MIDI) regions during trimming
This doesn't actually work right now because of a conflicting design in MidiRegionView, but
could be promising. Or it might be reverted
2022-04-05 20:52:10 -06:00
ae8c043fe1 regionviews: use integer counter instead of boolean to control redisplay of contents 2022-04-05 20:52:09 -06:00
b3ccccb48f add #warning to code that should be fixed ASAP but not pre-Mixbus8 release 2022-03-21 13:00:01 -06:00
fead587a5a
Remove debug output 2022-03-21 18:47:53 +01:00
f6646eaa2d
Fix undo/redo when moving regions to a different track
This was broken during development of ripple-all.
First explicit rdiff_and_add_command() was used, but
when that was reverted later, the original stateful_diff
was not restored.

989408626d
1ccf272d58
2022-03-21 18:47:53 +01:00
139d54ac9b
Fix automation range drag guard points
This addresses an issue with missing guard points at the
beginning of a range drag when the range is not snapped to
a musical grid.

Note that the code below "same thing for the end" does not use
.beats() either.
2022-03-18 02:31:31 +01:00
e3b66825eb superclock_ticks_per_second: GUI edition changes 2022-03-17 14:15:59 -06:00
9f29986a16
Fix Wreorder 2022-03-17 17:12:08 +01:00
01ef5a5b24 ripple (gui part): should_ripple_all() encapsulates modes Ripple+RippleAll 2022-03-14 19:26:41 -05:00
luz paz
364f2f0788 Fix typos in gtk2_ardour/ directory
Found via `codespell -q 3 -S *.po,./share/patchfiles,./libs -L ba,buss,busses,doubleclick,hsi,ontop,ro,seh,siz,sur,te,trough,ue`
2022-01-26 12:35:38 -05:00
4c433106a4 add interview mode to preferences and fix up implementation 2022-01-24 11:29:36 -07:00
8a310a748a add new config variable for interview-editing
If enabled, this prevents range-selection from propagating across
all tracks when RippleAll is set
2022-01-24 11:29:36 -07:00
c916d3d952 Substantial overhaul of tempo display code
Major changes: do not delete and recreate markers and curves for every tempo map
change, attach tempo curves directly to their (preceding) tempo marker, notable
cleanup of TempoCurve class to remove unnecessary members.

More tweaks expected since algorithm for matching markers and tempo map
points is not correct yet.
2022-01-18 19:47:20 -07:00
a6727cace5 use new editor/tempo map editing API for tempo marker drag 2022-01-15 22:53:58 -07:00