1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-11 09:31:13 +02:00

bug 601:fix black text for (show name in waveform) option. Patch by Steve Daulton.

This commit is contained in:
mchinen 2013-05-19 09:11:27 +00:00
parent 7863f52986
commit c51e2493eb

View File

@ -321,9 +321,6 @@ void TrackArtist::DrawTracks(TrackList * tracks,
dc.DrawRectangle(clip); dc.DrawRectangle(clip);
#endif #endif
wxFont labelFont(12, wxSWISS, wxNORMAL, wxNORMAL);
dc.SetFont(labelFont);
dc.SetTextForeground(wxColour(255, 255, 0));
gPrefs->Read(wxT("/GUI/ShowTrackNameInWaveform"), &mbShowTrackNameInWaveform, false); gPrefs->Read(wxT("/GUI/ShowTrackNameInWaveform"), &mbShowTrackNameInWaveform, false);
t = iter.StartWith(start); t = iter.StartWith(start);
@ -419,8 +416,12 @@ void TrackArtist::DrawTrack(const Track * t,
DrawSpectrum(wt, dc, r, viewInfo, true, false); DrawSpectrum(wt, dc, r, viewInfo, true, false);
break; break;
} }
if (mbShowTrackNameInWaveform && wt->GetChannel() != Track::RightChannel) // so left or mono only if (mbShowTrackNameInWaveform && wt->GetChannel() != Track::RightChannel) { // so left or mono only
wxFont labelFont(12, wxSWISS, wxNORMAL, wxNORMAL);
dc.SetFont(labelFont);
dc.SetTextForeground(wxColour(255, 255, 0));
dc.DrawText (wt->GetName(), r.x+10, r.y); // move right 10 pixels to avoid overwriting <- symbol dc.DrawText (wt->GetName(), r.x+10, r.y); // move right 10 pixels to avoid overwriting <- symbol
}
break; // case Wave break; // case Wave
} }
#ifdef USE_MIDI #ifdef USE_MIDI