* GTK fills in the snapshots in the background (using background threads
to test files).
* Actual colors may only available after the widget is realized (not
directly after ensure_style)
Much like the edit-tool and grid-types, clock-modes are UI state.
Saving the UI state separately allows them to be used
consistently for new sessions. Previously clock-modes were set
initially (at application start) and when loading sessions.
The clock modes of newly created sessions was different
depending on loading another session prior to creating the
session. This is now no longer the case.
The class now has two separate methods for setting a duration or a point
value. They MUST be used appropriately, because their behavior is different.
When ::set_duration() is used in timecode mode, an extent (inclusive-end
length) is shown rather than a length.
Some objects, such as the TimeInfoBox, now deliberately shown an inclusive end
for their "end" clock, but this not universally followed, pending more feedback
from users and investigating of conventions in other DAWs.
Sadly some popular Window Managers do not follow
freedesktop.org specifications. This results in Ardour's splash
screen obscuring session setup dialogs on those systems.
1. leave tertiary-scroll for navigation and primary scroll for session timeline zoom
2. unmodified scroll in edit mode scrolls contents
3. secondary-scroll zooms in and out on contents (i.e. vertical zoom for MIDI)
4. primary-secondary scroll has the just-one-edge behavior previously provided
Import via Drag/Drop previously worked by selecting a track,
and then importing to the selected track.
This approach fails when the selected track is in a track-group,
and selecting the track also selects other tracks of different type.
Now the track to drop onto is passed directly passed through to
::finish_bringing_in_material as existing_track.
This regressed with changes to SMFSource to unconditionally load
the model. "Black MIDI Trilogy 2" now shows again in under 4 sec.
Before this change it took roughly 3 mins (!) and the UI was marked
as unresponsive.
Confusion caused during nutempo development when a boolean related to nick_m's old
"for music" concept ended up becoming the "auto_partition" argument instead
It is tempting to update the list automatically when the dire contents change,
but this can lead to the list changing while the user is clicking to audition
or drag.
Instead, we should sensitize the button only when the dir contents have changed.
Found via `codespell -q 3 -S *.po,./.git,./share/patchfiles,./libs,./msvc_extra_headers,./share/web_surfaces,*.patch -L acount,ba,buss,busses,discreet,doubleclick,hsi,ontop,retrn,ro,scrollin,seh,siz,sord,sur,te,trough,ue`
With name-bars the region was colored using the track color
if the region is not high enough to show the name-bar.
This happened regardless of the color-regions-using-track-color
preference IFF name-bars were enabled.
However set_color/get_fill_color() is not called when the track-height
changes "high_enough_for_name". This lead to inconsistently colored
regions, some with a background some without.
This was lost when refactoring the editor lists into dedicated
Region, Source and Route lists. A patched version of gtk allows to
initiate a drag, rather than a name edit.
On modern systems `xdg-screensaver reset` does not necessarily
reset the timer. It depends on DPMS, and according to spec turns off
the screensaver (unlock the screen), via `xset dpms force on`.
Explicit window suspend/resume make use of DBus
org.freedesktop.ScreenSaver.Inhibit, which is not be supported
but all systems, so we fall back to good old `XResetScreenSaver`
which does reset the activation timer.
Window size has to be set before calling `setup_toplevel_window()`.
and `set_show_tabs()` - see also acf13e9498 and 42cb321039.
This also unconditionally saves the current settings to global config
instant.xml. This was previously only done in rare cases when first
closing the session and then quitting Ardour.
These were preventing Ardour from compiling on Windows (Clang or MSVC)
Possibly would've been buildable with MinGW but I don't have that available to test.
At present, TempoTwist is Primary-drag on the tempo ruler, and TempoCurve is Primary-drag on the meter
ruler. Not sure that this is quite what we want here, but it makes more sense than the prior
design, in which TempoTwist was available from non-tempo-related rulers
This avoids breaking bindings, and since the action name is generally not a part of the GUI,
really doesn't hurt anything in terms of understandability
An attempt to satisfy #8848.
Add a new action, "fork-regions-from-unselected", which unlinks all
selected MIDI regions from any unselected regions, but maintains links
within the selection, and add the new action to the region MIDI context
menu as "Unlink from unselected". Rename the existing "fork-region" action
to "fork-selected-regions", and amend the existing "Unlink from other
copies" menu item to "Unlink all selected regions" to (try to) clarify the
difference.
Attach the <Tertiary>U default key-binding to the new action: I personally
think it's generally slightly more useful (otherwise I wouldn't have
implemented it), though I'm not that fussed.
In the case that there's only one MIDI region selected, or that none of
the selected regions are mutually linked, both actions will have exactly
the same result. Ideally, we'd only show a single menu item in this case,
but that would require (a) implementing a function to check whether the
selection contains any linked regions, and (b) making the region MIDI
context sub-menu dynamically generated, so that it can change based on the
result of that function, neither of which I've tried to do yet.
The fix here is really just dropping the use of _offset when computing the session position
of a control point. This was just an arithmetical error.
However, session_sample_position() was redundant and just caused more work, so this
method was removed, and only ::session_position() is now used.
In addition, several closely related places now use C++11 (or later) "auto"
syntax for iterating over containers, for cleaner looking code
In case a user manually renames a session-folder and snapshot
it should still be impossible to delete the last snapshot
even if it is not named after the session-dir.
In theory this is impossible (one cannot delete the current snapshot)
Previously this setting was ignored. It is relevant when loading a demo
session, where initially there is no user Config instant.xml.
ARDOUR_UI::setup_windows is called directly after the engine starts, but
before the session is set.
Region actions are generally set insensitive whilst recording, so
special-case the "add-region-cue-marker" action by explicitly enabling it
when starting to roll in record. Additionally, the action becomes disabled
again after it's been executed, so re-enable it after queuing the cue when
recording.
This allows new user to select the soundcard and I/O settings
when loading demo sessions at first run, or when tricking Ardour
to open an existing session (try to create an existing session,
user may choose to load it instead).
Normally a user can only create a new session after first running
Ardour, and creating new sessions always shows the dialog (to
set the samplerate).
When loading the very first session is canceled (e.g.
sample-rate mismatch -> Do not load session) or fails otherwise,
execution returns to the startupFSM.
Loading another session after that then takes the same path again:
StartupFSM::dialog_response_handler() -> StartupFSM::engine_running()
-> ARDOUR_UI::attach_to_engine()
The call needs to be idempotent, otherwise setup_windows(),
create_editor() etc are called a second time and Ardour crashes.
Found via `codespell -q 3 -S *.po,./.git,./share/patchfiles,./libs,./msvc_extra_headers,./share/web_surfaces,*.patch -L ba,buss,busses,discreet,doubleclick,hsi,ontop,ro,scrollin,seh,siz,sord,sur,te,trough,ue`
Previously no unmap events were delivered (due to a bug in
Gtk EventBox), `lower_box_map` was called only once.
Furthermore when cross-compiling (ARM binary on Intel),
COCOA_LIVE_RESIZING was not detected.
see also df21698ea7
Rosetta bridge plugins have an initial size of 0x0 pixel.
Ardour's AU window size is set relative to the previous size. So the
window grows by the actual real initial size of the AU View.
However the window is already allocated and has a non-zero width given
by the plugin's toolbar.
This lead to oversize windows.
* Fix demo-session glob (missing "*" + session_archive_suffix)
* Copy demo-session also when copying settings from older version
* Also add demo-session to recent-list if it was previously unpacked
for new major versions.
This should fix a long-standing issue with interleaved display
of clients since jack_get_ports() does not return a well defined order.
(Internal backends based on Ardour::PortEngine keep ports sorted)
In case of MIDI CC/Bend/Pressure etc events, the underlying
data is provided by a MidiTrack (is-a Automatable) and not
an automation-control.
When directly calling AutomationControl::set_automation_state,
the AC disables automation-watch using shared_from_this().
With the Evoral::Control used for MidiTrack event-lists this
results in a tr1::bad_weak_ptr.
Locations::ripple() skips these markers when the ripple action is committed.
...but the editor moves the marker-items as a visual aid, before actually
committing the changes to Locations()
...so the editor needs the same logic, to avoid visually inconsistent behavior
In case of auto-scroll it is apparently possible that the
move_threshold_passed, but ::motion() is not called.
There already is an explicit _starting_point_passed variable
that is set when first_move occurred. So far it was just unused.
when dragging their location
* it should be possible to launch an arbitrary (non-quantized) sound
'anytime' on the timeline
* this was already possible anyway, by switching the Grid to None
When no movement has occurred, TrimDrag::motion was never called
and `begin_reversible_command()` was not called. There is nothing
to undo. This fixes
`commit_reversible_command(Command*): Assertion `_current_trans' failed`
This also fixes Menu > Edit Delete "delete MIDI" operation.
Pressing backspace/delete calls "Delete Selection" which is
unrelated to MRV::cut_copy_clear.
Gtk::manage only destroys managed widgets when the parent container
is destroyed. In Ardour's case this is not the case since
Gtkmm2ext::container_clear() is used to unpack/repack widgets
as required.
The Monitor Model usually depends on the studio setup (hardware
mixing desk), but also to some extent on the audio interface (zero-
latency monitoring). Since a user may also use different interfaces
(e.g. with a laptop), it makes sense to expose the monitor model
preference in the engine-dialog.
NB. It is not part of the engine-state (!), but still a preference.
* Remove Monitor Model Option
* Remove Monitor Section Option
These days those can be toggled after setup, even while the
session is loaded and engine is running. There is no need to bother
a user very early on with this question about Monitoring.
This has no been useful since years. Both Ardour and JACK
backends always use all available ports and the setting was
only useful to "hide" excess ports.
A fully transparent waveform (with only a semi-transparent outline)
looks very odd with all themes.
Perhaps this was a typo and the initially intended rendering was
supposed to be 31% transparent, however this is not distinguishable
from non-opaque regions (27% transparency).
It connects to the ParameterChanged (sigc++) signal, and to ensure automated
disconnection on object death, sigc::trackable is required in the
inheritance tree
It connects to the ParameterChanged (sigc++) signal, and to ensure automated
disconnection on object death, sigc::trackable is required in the
inheritance tree
The track-header (gtk) is packed with 1px box spacing. This
is added at the top of each box (best seen by looking at the
group-tab vs track-header alignment in the editor).
However the actual track separator line on the canvas is at the
bottom of each track, aligning with the top of the next track
or automation-lane.
The first track however lacks a separator at the top, which
needs to be provided by the ruler. Once the canvas is scrolled
this ruler/canvas separator overlaps with the bottom separator of
each TAV.
Using ruler Rectangle::set_outline had various issues.
The outline extends outside the rectangle. It bled into the
video-timeline instead of the canvas' top y-axis pixel.
Also the separator was above the video-timeline, not above the
canvas. Hence a dedicated separator Line is preferable.
It also provides a consistent separator if no rulers are visible.
Before nutempo, ::find_next_region_boundary() used to return -1
when no boundary was found (now timepos_t::max is returned).
timepos_t::increment() returns the incremented value, not increments
the variable itself.
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.
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.
Previously it was possible that the tempo-curve display was rendered
above a tempo-marker (e.g. create a marker in the between of existing
markers). With the tempo-curve in front, markers on the right
became inaccessible.
Code used to just push back new markers to the end of the relevant list, and
this would then the new marker to be deleted soon thereafter. Instead pass
an interator indicating where to place the marker in the list.
Note that we rely on the use of std::list<T> here to keep the iterator to the
existing marker valid.