Audacity  3.0.3
Enumerations | Functions | Variables
WaveTrackViewConstants Namespace Reference

Enumerations

enum  Display : int {
  MultiView = -1, Waveform = 0, MinDisplay = Waveform, obsoleteWaveformDBDisplay,
  Spectrum, obsolete1, obsolete2, obsolete3,
  obsolete4, MaxDisplay = Spectrum, NoDisplay
}
 
enum  SampleDisplay { LinearInterpolate = 0, StemPlot }
 
enum  ZoomPresets {
  kZoomToFit = 0, kZoomToSelection, kZoomDefault, kZoomMinutes,
  kZoomSeconds, kZoom5ths, kZoom10ths, kZoom20ths,
  kZoom50ths, kZoom100ths, kZoom500ths, kZoomMilliSeconds,
  kZoomSamples, kZoom4To1, kMaxZoom
}
 
enum  ZoomActions {
  kZoom1to1 = 1, kZoomTimes2, kZoomDiv2, kZoomHalfWave,
  kZoomInByDrag, kZoomIn, kZoomOut, kZoomReset
}
 

Functions

Display ConvertLegacyDisplayValue (int oldValue)
 

Variables

const EnumValueSymbol MultiViewSymbol
 String identifier for a preference for one of each type of view. More...
 

Enumeration Type Documentation

◆ Display

Enumerator
MultiView 

"Multi" is special, not really a view type on par with the others.

Waveform 
MinDisplay 
obsoleteWaveformDBDisplay 
Spectrum 
obsolete1 
obsolete2 
obsolete3 
obsolete4 
MaxDisplay 
NoDisplay 

Definition at line 18 of file WaveTrackViewConstants.h.

18  : int {
19 
20  MultiView = -1,
21 
22  // DO NOT REORDER OLD VALUES! Replace obsoletes with placeholders.
23 
24  Waveform = 0,
26 
28 
29  Spectrum,
30 
31  obsolete1, // was SpectrumLogDisplay
32  obsolete2, // was SpectralSelectionDisplay
33  obsolete3, // was SpectralSelectionLogDisplay
34  obsolete4, // was PitchDisplay
35 
36  // Add values here, and update MaxDisplay.
37 
39 
40  NoDisplay, // Preview track has no display
41  };

◆ SampleDisplay

Enumerator
LinearInterpolate 
StemPlot 

Definition at line 45 of file WaveTrackViewConstants.h.

45  {
47  StemPlot
48  };

◆ ZoomActions

Enumerator
kZoom1to1 
kZoomTimes2 
kZoomDiv2 
kZoomHalfWave 
kZoomInByDrag 
kZoomIn 
kZoomOut 
kZoomReset 

Definition at line 69 of file WaveTrackViewConstants.h.

69  {
70  // Note that these can be with or without spectrum view which
71  // adds a constant.
72  kZoom1to1 = 1,
74  kZoomDiv2,
77  kZoomIn,
78  kZoomOut,
80  };

◆ ZoomPresets

Enumerator
kZoomToFit 
kZoomToSelection 
kZoomDefault 
kZoomMinutes 
kZoomSeconds 
kZoom5ths 
kZoom10ths 
kZoom20ths 
kZoom50ths 
kZoom100ths 
kZoom500ths 
kZoomMilliSeconds 
kZoomSamples 
kZoom4To1 
kMaxZoom 

Definition at line 51 of file WaveTrackViewConstants.h.

51  {
52  kZoomToFit = 0,
57  kZoom5ths,
58  kZoom10ths,
59  kZoom20ths,
60  kZoom50ths,
65  kZoom4To1,
66  kMaxZoom,
67  };

Function Documentation

◆ ConvertLegacyDisplayValue()

WaveTrackViewConstants::Display WaveTrackViewConstants::ConvertLegacyDisplayValue ( int  oldValue)

Definition at line 16 of file WaveTrackViewConstants.cpp.

17 {
18  // Remap old values.
19  enum class OldValues {
20  Waveform,
21  WaveformDB,
22  Spectrogram,
23  SpectrogramLogF,
24  Pitch,
25  };
26 
27  Display newValue;
28  switch ((OldValues)oldValue) {
29  default:
31  newValue = Waveform; break;
32  case OldValues::WaveformDB:
33  newValue = obsoleteWaveformDBDisplay; break;
34  case OldValues::Spectrogram:
35  case OldValues::SpectrogramLogF:
36  case OldValues::Pitch:
37  newValue = Spectrum; break;
38  /*
39  case SpectrogramLogF:
40  newValue = WaveTrack::SpectrumLogDisplay; break;
41  case Pitch:
42  newValue = WaveTrack::PitchDisplay; break;
43  */
44  }
45  return newValue;
46 }

References obsoleteWaveformDBDisplay, Spectrum, and Waveform.

Referenced by TracksViewModeEnumSetting::Migrate().

Here is the caller graph for this function:

Variable Documentation

◆ MultiViewSymbol

const EnumValueSymbol WaveTrackViewConstants::MultiViewSymbol
extern
Initial value:
{
wxT("Multiview"), XXO("&Multi-view")
}

String identifier for a preference for one of each type of view.

Definition at line 105 of file WaveTrackViewConstants.cpp.

Referenced by DiscoverSubViewTypes(), and viewModeSetting().

WaveTrackViewConstants::kZoomToSelection
@ kZoomToSelection
Definition: WaveTrackViewConstants.h:53
WaveTrackViewConstants::NoDisplay
@ NoDisplay
Definition: WaveTrackViewConstants.h:40
WaveTrackViewConstants::kZoomTimes2
@ kZoomTimes2
Definition: WaveTrackViewConstants.h:73
WaveTrackViewConstants::obsoleteWaveformDBDisplay
@ obsoleteWaveformDBDisplay
Definition: WaveTrackViewConstants.h:27
WaveTrackViewConstants::kZoomSeconds
@ kZoomSeconds
Definition: WaveTrackViewConstants.h:56
WaveTrackViewConstants::kZoomDefault
@ kZoomDefault
Definition: WaveTrackViewConstants.h:54
WaveTrackViewConstants::obsolete3
@ obsolete3
Definition: WaveTrackViewConstants.h:33
WaveTrackViewConstants::kZoom1to1
@ kZoom1to1
Definition: WaveTrackViewConstants.h:72
WaveTrackViewConstants::MinDisplay
@ MinDisplay
Definition: WaveTrackViewConstants.h:25
WaveTrackViewConstants::Display
Display
Definition: WaveTrackViewConstants.h:18
WaveTrackViewConstants::MaxDisplay
@ MaxDisplay
Definition: WaveTrackViewConstants.h:38
WaveTrackViewConstants::kZoomDiv2
@ kZoomDiv2
Definition: WaveTrackViewConstants.h:74
WaveTrackViewConstants::obsolete4
@ obsolete4
Definition: WaveTrackViewConstants.h:34
XXO
#define XXO(s)
Definition: Internat.h:45
WaveTrackViewConstants::kZoom500ths
@ kZoom500ths
Definition: WaveTrackViewConstants.h:62
WaveTrackViewConstants::kZoom5ths
@ kZoom5ths
Definition: WaveTrackViewConstants.h:57
WaveTrackViewConstants::kZoomSamples
@ kZoomSamples
Definition: WaveTrackViewConstants.h:64
WaveTrackViewConstants::kZoom100ths
@ kZoom100ths
Definition: WaveTrackViewConstants.h:61
WaveTrackViewConstants::kZoomMinutes
@ kZoomMinutes
Definition: WaveTrackViewConstants.h:55
WaveTrackViewConstants::kZoomIn
@ kZoomIn
Definition: WaveTrackViewConstants.h:77
WaveTrackViewConstants::kZoomMilliSeconds
@ kZoomMilliSeconds
Definition: WaveTrackViewConstants.h:63
WaveTrackViewConstants::kZoom10ths
@ kZoom10ths
Definition: WaveTrackViewConstants.h:58
WaveTrackViewConstants::kZoomInByDrag
@ kZoomInByDrag
Definition: WaveTrackViewConstants.h:76
WaveTrackViewConstants::kZoomReset
@ kZoomReset
Definition: WaveTrackViewConstants.h:79
WaveTrackViewConstants::kZoom20ths
@ kZoom20ths
Definition: WaveTrackViewConstants.h:59
WaveTrackViewConstants::StemPlot
@ StemPlot
Definition: WaveTrackViewConstants.h:47
WaveTrackViewConstants::kMaxZoom
@ kMaxZoom
Definition: WaveTrackViewConstants.h:66
WaveTrackViewConstants::LinearInterpolate
@ LinearInterpolate
Definition: WaveTrackViewConstants.h:46
WaveTrackViewConstants::kZoomOut
@ kZoomOut
Definition: WaveTrackViewConstants.h:78
WaveTrackViewConstants::Spectrum
@ Spectrum
Definition: WaveTrackViewConstants.h:29
WaveTrackViewConstants::kZoom50ths
@ kZoom50ths
Definition: WaveTrackViewConstants.h:60
WaveTrackViewConstants::obsolete2
@ obsolete2
Definition: WaveTrackViewConstants.h:32
WaveTrackViewConstants::obsolete1
@ obsolete1
Definition: WaveTrackViewConstants.h:31
WaveTrackViewConstants::kZoom4To1
@ kZoom4To1
Definition: WaveTrackViewConstants.h:65
WaveTrackViewConstants::kZoomHalfWave
@ kZoomHalfWave
Definition: WaveTrackViewConstants.h:75
WaveTrackViewConstants::MultiView
@ MultiView
"Multi" is special, not really a view type on par with the others.
Definition: WaveTrackViewConstants.h:20
WaveTrackViewConstants::Waveform
@ Waveform
Definition: WaveTrackViewConstants.h:24
WaveTrackViewConstants::kZoomToFit
@ kZoomToFit
Definition: WaveTrackViewConstants.h:52