Move selected/unselected region/waveform colours to colour file for configurability.

Changed the region selection colour in the default theme to match the track selection colour (and the tool one, and the MIDI one in 3.0, and....).
(Note: If someone hates these colours, the old "reverse video" like behaviour can still be done in the colour file or w/ the theme manager).


git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@2987 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
David Robillard 2008-02-02 01:54:01 +00:00
parent dbae21f78c
commit 9b36d0c57d
3 changed files with 17 additions and 13 deletions

View file

@ -1,11 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<Ardour>
<Canvas>
<Option name="waveform outline" value="0f0f0fcc"/>
<Option name="waveform fill" value="3d475378"/>
<Option name="waveform outline" value="0f0f0fc8"/>
<Option name="waveform fill" value="3d4753dc"/>
<Option name="selected waveform outline" value="0f0f0fcc"/>
<Option name="selected waveform fill" value="51518ac8"/>
<Option name="clipped waveform" value="ff0000e5"/>
<Option name="region base" value="99a7b5aa"/>
<Option name="selected region base" value="b591a8ff"/>
<Option name="region base" value="99a7b584"/>
<Option name="selected region base" value="51518aff"/>
<Option name="audio track base" value="c6d3d868"/>
<Option name="audio bus base" value="dbd1ea68"/>
<Option name="midi track base" value="ff8f8f3d"/>
@ -70,14 +72,14 @@
<Option name="GhostTrackZeroLine" value="e500e566"/>
<Option name="ImageTrack" value="ddddd8ff"/>
<Option name="MarkerTrack" value="ddddd8ff"/>
<Option name="ZeroLine" value="b5b5b5ff"/>
<Option name="ZeroLine" value="bdbdbd8d"/>
<Option name="GainLine" value="00bc20ff"/>
<Option name="GainLineInactive" value="9fbca4c5"/>
<Option name="RecordingRect" value="e5c6c6ff"/>
<Option name="SelectionRect" value="e8f4d377"/>
<Option name="Selection" value="636363b2"/>
<Option name="VestigialFrame" value="44007c0f"/>
<Option name="TimeAxisFrame" value="44007c0f"/>
<Option name="VestigialFrame" value="00000092"/>
<Option name="TimeAxisFrame" value="000000cb"/>
<Option name="NameHighlightFill" value="0000ffff"/>
<Option name="NameHighlightOutline" value="7c00ff96"/>
<Option name="FrameHandle" value="7c00ff96"/>
@ -85,10 +87,9 @@
<Option name="TrimHandle" value="1900ff44"/>
<Option name="EditPoint" value="0000ffff"/>
<Option name="PlayHead" value="ff0000ff"/>
<Option name="MeterColorBase" value="0000ffff"/>
<Option name="MeterColorBase" value="0000ffff"/>
<Option name="MeterColorMid" value="73f9baff"/>
<Option name="MeterColorTop" value="00fd5dff"/>
<Option name="MeterColorClip" value="ff0000ff"/>
</Canvas>
</Ardour>

View file

@ -1178,14 +1178,15 @@ AudioRegionView::set_frame_color ()
uint32_t r,g,b,a;
if (_selected && should_show_selection) {
frame->property_fill_color_rgba() = ARDOUR_UI::config()->canvasvar_WaveForm.get();
UINT_TO_RGBA(ARDOUR_UI::config()->canvasvar_SelectedFrameBase.get(), &r, &g, &b, &a);
frame->property_fill_color_rgba() = RGBA_TO_UINT(r, g, b, fill_opacity ? fill_opacity : a);
UINT_TO_RGBA(ARDOUR_UI::config()->canvasvar_FrameBase.get(), &r, &g, &b, &a);
for (vector<ArdourCanvas::WaveView*>::iterator w = waves.begin(); w != waves.end(); ++w) {
if (_region->muted()) {
(*w)->property_wave_color() = RGBA_TO_UINT(r, g, b, MUTED_ALPHA);
(*w)->property_wave_color() = UINT_RGBA_CHANGE_A(ARDOUR_UI::config()->canvasvar_SelectedWaveForm.get(), MUTED_ALPHA);
} else {
(*w)->property_wave_color() = RGBA_TO_UINT(r, g, b, fill_opacity ? fill_opacity : a);// Lets still use the theme's opacity value if Opaque is not set
(*w)->property_wave_color() = ARDOUR_UI::config()->canvasvar_SelectedWaveForm.get();
(*w)->property_fill_color() = ARDOUR_UI::config()->canvasvar_SelectedWaveFormFill.get();
}
}
} else {

View file

@ -1,5 +1,7 @@
CANVAS_VARIABLE(canvasvar_WaveForm, "waveform outline")
CANVAS_VARIABLE(canvasvar_WaveFormFill, "waveform fill")
CANVAS_VARIABLE(canvasvar_SelectedWaveForm, "selected waveform outline")
CANVAS_VARIABLE(canvasvar_SelectedWaveFormFill, "selected waveform fill")
CANVAS_VARIABLE(canvasvar_WaveFormClip, "clipped waveform")
CANVAS_VARIABLE(canvasvar_FrameBase, "region base")
CANVAS_VARIABLE(canvasvar_SelectedFrameBase, "selected region base")