14#ifndef __AUDACITY_COLOR__
15#define __AUDACITY_COLOR__
22class wxGraphicsContext;
29 ColorGradientUnselected = 0,
40 static void Arrow(wxDC & dc, wxCoord x, wxCoord y,
int width,
bool down =
true);
44 static void Line(wxDC & dc, wxCoord x1, wxCoord y1, wxCoord x2, wxCoord y2);
47 static void Lines(wxDC &dc,
size_t nPoints,
const wxPoint points[]);
49 static void DrawFocus(wxDC & dc, wxRect & r);
50 static void Bevel(wxDC & dc,
bool up,
const wxRect & r);
52 (wxDC & dc,
bool up,
const wxRect & r,
bool bSel=
false,
bool bHighlight =
false);
56 static void DrawHStretch(wxDC& dc,
const wxRect& rect, wxBitmap& bitmap);
57 static void DrawFrame(wxDC& dc,
const wxRect& r, wxBitmap& bitmap);
61 static void ButtonStretch(wxDC& dc,
bool up,
const wxRect& r,
bool selected =
false,
bool highlight =
false);
62 static void BevelTrackInfo(wxDC & dc,
bool up,
const wxRect & r,
bool highlight =
false);
63 static wxColour Blend(
const wxColour & c1,
const wxColour & c2);
65 static void UseThemeColour( wxDC * dc,
int iBrush,
int iPen=-1,
int alpha = 255 );
66 static void UseThemeColour( wxGraphicsContext * gc,
int iBrush,
int iPen=-1,
int alpha = 255 );
67 static void TrackPanelBackground(wxDC * dc,
bool selected);
69 static void Light(wxDC * dc,
bool selected,
bool highlight =
false);
70 static void Medium(wxDC * dc,
bool selected);
71 static void MediumTrackInfo(wxDC * dc,
bool selected);
72 static void Dark(wxDC * dc,
bool selected,
bool highlight =
false);
74 static void CursorColor(wxDC * dc);
75 static void IndicatorColor(wxDC * dc,
bool bIsNotRecording);
77 static void Mute(wxDC * dc,
bool on,
bool selected,
bool soloing);
78 static void Solo(wxDC * dc,
bool on,
bool selected);
84 static void MIDIChannel(wxDC * dc,
int channel );
85 static void LightMIDIChannel(wxDC * dc,
int channel );
86 static void DarkMIDIChannel(wxDC * dc,
int channel );
88 static void TrackFocusPen(wxDC * dc,
int level );
89 static void SnapGuidePen(wxDC * dc);
91 static void PreComputeGradient();
93 static void ApplyUpdatedImages();
97 static wxBrush lightBrush[2];
98 static wxBrush mediumBrush[2];
99 static wxBrush darkBrush[2];
100 static wxPen lightPen[2];
101 static wxPen mediumPen[2];
102 static wxPen darkPen[2];
105 static wxPen indicatorPen[2];
106 static wxBrush indicatorBrush[2];
108 static wxBrush playRegionBrush[1];
110 static wxBrush muteBrush[2];
129 static wxPen trackFocusPens[3];
136 static const int colorSchemes = 4;
137 static const int gradientSteps = 256;
138 static unsigned char gradient_pre[ColorGradientTotal][colorSchemes][gradientSteps][3];
154 unsigned char * __restrict red,
155 unsigned char * __restrict green,
156 unsigned char * __restrict blue) {
void GetColorGradient(float value, AColor::ColorGradientChoice selected, int colorScheme, unsigned char *__restrict red, unsigned char *__restrict green, unsigned char *__restrict blue)
AColor Manages color brushes and pens.
static wxBrush labelSelectedBrush
static wxPen WideEnvelopePen
@ ColorGradientTimeAndFrequencySelected
@ ColorGradientTimeSelected
static wxPen labelSurroundPen
static wxBrush envelopeBrush
static wxBrush labelTextNormalBrush
static wxBrush labelTextEditBrush
static const int gradientSteps
static wxBrush labelSyncLockSelBrush
static unsigned char gradient_pre[ColorGradientTotal][colorSchemes][gradientSteps][3]
static wxPen labelSelectedPen
static wxBrush tooltipBrush
static wxBrush labelUnselectedBrush
static wxPen snapGuidePen
static wxBrush spareBrush
static wxPen labelUnselectedPen
static bool gradient_inited
static wxPen labelSyncLockSelPen