Audacity 3.2.0
Public Member Functions | Static Public Attributes | Private Member Functions | List of all members
ImportExportPrefs Class Referencefinal

A PrefsPanel used to select import and export options. More...

#include <ImportExportPrefs.h>

Inheritance diagram for ImportExportPrefs:
[legend]
Collaboration diagram for ImportExportPrefs:
[legend]

Public Member Functions

 ImportExportPrefs (wxWindow *parent, wxWindowID winid)
 
 ~ImportExportPrefs ()
 
ComponentInterfaceSymbol GetSymbol () const override
 
TranslatableString GetDescription () const override
 
bool Commit () override
 
ManualPageID HelpPageName () override
 If not empty string, the Help button is added below the panel. More...
 
void PopulateOrExchange (ShuttleGui &S) override
 
- Public Member Functions inherited from PrefsPanel
 PrefsPanel (wxWindow *parent, wxWindowID winid, const TranslatableString &title)
 
virtual ~PrefsPanel ()
 
virtual void Preview ()
 
virtual bool Commit ()=0
 
virtual PluginPath GetPath () const override
 
virtual VendorSymbol GetVendor () const override
 
virtual wxString GetVersion () const override
 
virtual bool ShowsPreviewButton ()
 
virtual void PopulateOrExchange (ShuttleGui &WXUNUSED(S))
 
virtual ManualPageID HelpPageName ()
 If not empty string, the Help button is added below the panel. More...
 
virtual void Cancel ()
 
- Public Member Functions inherited from wxPanelWrapper
 wxPanelWrapper ()
 
 wxPanelWrapper (wxWindow *parent, wxWindowID winid=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL|wxNO_BORDER, const TranslatableString &name=XO("Panel"))
 
bool Create (wxWindow *parent, wxWindowID winid=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL|wxNO_BORDER, const TranslatableString &name=XO("Panel"))
 
void SetLabel (const TranslatableString &label)
 
void SetName (const TranslatableString &name)
 
void SetToolTip (const TranslatableString &toolTip)
 
void SetName ()
 
- Public Member Functions inherited from wxTabTraversalWrapper< wxPanel >
 wxTabTraversalWrapper (Args &&... args)
 
 wxTabTraversalWrapper (const wxTabTraversalWrapper &)=delete
 
 wxTabTraversalWrapper (wxTabTraversalWrapper &&)=delete
 
wxTabTraversalWrapperoperator= (const wxTabTraversalWrapper &)=delete
 
wxTabTraversalWrapperoperator= (wxTabTraversalWrapper &&)=delete
 

Static Public Attributes

static EnumSetting< bool > ExportDownMixSetting
 
static EnumSetting< bool > LabelStyleSetting
 
static EnumSetting< bool > AllegroStyleSetting
 

Private Member Functions

void Populate ()
 Creates the dialog and its contents. More...
 

Additional Inherited Members

- Public Types inherited from PrefsPanel
using Factories = std::vector< PrefsPanel::PrefsNode >
 
using Factory = std::function< PrefsPanel *(wxWindow *parent, wxWindowID winid, AudacityProject *) >
 
- Static Public Member Functions inherited from PrefsPanel
static FactoriesDefaultFactories ()
 

Detailed Description

A PrefsPanel used to select import and export options.

Definition at line 26 of file ImportExportPrefs.h.

Constructor & Destructor Documentation

◆ ImportExportPrefs()

ImportExportPrefs::ImportExportPrefs ( wxWindow *  parent,
wxWindowID  winid 
)

Definition at line 26 of file ImportExportPrefs.cpp.

27: PrefsPanel(parent, winid, XO("Import / Export"))
28{
29 Populate();
30}
XO("Cut/Copy/Paste")
void Populate()
Creates the dialog and its contents.
PrefsPanel(wxWindow *parent, wxWindowID winid, const TranslatableString &title)
Definition: PrefsPanel.h:94

References Populate().

Here is the call graph for this function:

◆ ~ImportExportPrefs()

ImportExportPrefs::~ImportExportPrefs ( )

Definition at line 32 of file ImportExportPrefs.cpp.

33{
34}

Member Function Documentation

◆ Commit()

bool ImportExportPrefs::Commit ( )
overridevirtual

Implements PrefsPanel.

Definition at line 174 of file ImportExportPrefs.cpp.

175{
178
179 return true;
180}
@ eIsSavingToPrefs
Definition: ShuttleGui.h:47
#define S(N)
Definition: ToChars.cpp:64
void PopulateOrExchange(ShuttleGui &S) override
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:625

References eIsSavingToPrefs, PopulateOrExchange(), and S.

Here is the call graph for this function:

◆ GetDescription()

TranslatableString ImportExportPrefs::GetDescription ( ) const
overridevirtual

Implements ComponentInterface.

Definition at line 41 of file ImportExportPrefs.cpp.

42{
43 return XO("Preferences for ImportExport");
44}

References XO().

Here is the call graph for this function:

◆ GetSymbol()

ComponentInterfaceSymbol ImportExportPrefs::GetSymbol ( ) const
overridevirtual

Implements ComponentInterface.

Definition at line 36 of file ImportExportPrefs.cpp.

37{
39}
#define IMPORT_EXPORT_PREFS_PLUGIN_SYMBOL

References IMPORT_EXPORT_PREFS_PLUGIN_SYMBOL.

◆ HelpPageName()

ManualPageID ImportExportPrefs::HelpPageName ( )
overridevirtual

If not empty string, the Help button is added below the panel.

Default returns empty string.

Reimplemented from PrefsPanel.

Definition at line 46 of file ImportExportPrefs.cpp.

47{
48 return "Import_-_Export_Preferences";
49}

◆ Populate()

void ImportExportPrefs::Populate ( )
private

Creates the dialog and its contents.

Definition at line 52 of file ImportExportPrefs.cpp.

53{
54 //------------------------- Main section --------------------
55 // Now construct the GUI itself.
56 // Use 'eIsCreatingFromPrefs' so that the GUI is
57 // initialised with values from gPrefs.
60 // ----------------------- End of main section --------------
61}
@ eIsCreatingFromPrefs
Definition: ShuttleGui.h:46

References eIsCreatingFromPrefs, PopulateOrExchange(), and S.

Referenced by ImportExportPrefs().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PopulateOrExchange()

void ImportExportPrefs::PopulateOrExchange ( ShuttleGui S)
override

Definition at line 106 of file ImportExportPrefs.cpp.

107{
108 S.SetBorder(2);
109 S.StartScroller();
110
111 S.StartStatic(XO("When exporting tracks to an audio file"));
112 {
113 // Bug 2692: Place button group in panel so tabbing will work and,
114 // on the Mac, VoiceOver will announce as radio buttons.
115 S.StartPanel();
116 {
117 S.StartRadioButtonGroup(ImportExportPrefs::ExportDownMixSetting);
118 {
119 S.TieRadioButton();
120 S.TieRadioButton();
121 }
122 S.EndRadioButtonGroup();
123 }
124 S.EndPanel();
125
126 S.TieCheckBox(XXO("S&how Metadata Tags editor before export"),
127 {wxT("/AudioFiles/ShowId3Dialog"),
128 true});
129 /* i18n-hint 'blank space' is space on the tracks with no audio in it*/
130 S.TieCheckBox(XXO("&Ignore blank space at the beginning"),
131 {wxT("/AudioFiles/SkipSilenceAtBeginning"),
132 false});
133 }
134 S.EndStatic();
135
136 S.StartStatic(XO("Exported Label Style:"));
137 {
138 // Bug 2692: Place button group in panel so tabbing will work and,
139 // on the Mac, VoiceOver will announce as radio buttons.
140 S.StartPanel();
141 {
142 S.StartRadioButtonGroup(ImportExportPrefs::LabelStyleSetting);
143 {
144 S.TieRadioButton();
145 S.TieRadioButton();
146 }
147 S.EndRadioButtonGroup();
148 }
149 S.EndPanel();
150 }
151 S.EndStatic();
152
153#ifdef USE_MIDI
154 S.StartStatic(XO("Exported Allegro (.gro) files save time as:"));
155 {
156 // Bug 2692: Place button group in panel so tabbing will work and,
157 // on the Mac, VoiceOver will announce as radio buttons.
158 S.StartPanel();
159 {
160 S.StartRadioButtonGroup(ImportExportPrefs::AllegroStyleSetting);
161 {
162 S.TieRadioButton();
163 S.TieRadioButton();
164 }
165 S.EndRadioButtonGroup();
166 }
167 S.EndPanel();
168 }
169 S.EndStatic();
170#endif
171 S.EndScroller();
172}
wxT("CloseDown"))
XXO("&Cut/Copy/Paste Toolbar")
static EnumSetting< bool > LabelStyleSetting
static EnumSetting< bool > AllegroStyleSetting
static EnumSetting< bool > ExportDownMixSetting

References AllegroStyleSetting, ExportDownMixSetting, LabelStyleSetting, S, wxT(), XO(), and XXO().

Referenced by Commit(), and Populate().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ AllegroStyleSetting

EnumSetting< bool > ImportExportPrefs::AllegroStyleSetting
static
Initial value:
{
wxT("/FileFormats/AllegroStyleChoice"),
{
EnumValueSymbol{ wxT("Seconds"), XXO("&Seconds") },
EnumValueSymbol{ wxT("Beats"), XXO("&Beats") },
},
0,
{
true, false,
},
wxT("/FileFormats/AllegroStyle"),
}
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...

Definition at line 31 of file ImportExportPrefs.h.

Referenced by NoteTrack::ExportAllegro(), and PopulateOrExchange().

◆ ExportDownMixSetting

EnumSetting< bool > ImportExportPrefs::ExportDownMixSetting
static
Initial value:
{
wxT("/FileFormats/ExportDownMixChoice"),
{
EnumValueSymbol{ wxT("MixDown"), XXO("&Mix down to Stereo or Mono") },
EnumValueSymbol{ wxT("Custom"), XXO("&Use Advanced Mixing Options") },
},
0,
{
true, false,
},
wxT("/FileFormats/ExportDownMix"),
}

Definition at line 29 of file ImportExportPrefs.h.

Referenced by Exporter::CheckMix(), and PopulateOrExchange().

◆ LabelStyleSetting

EnumSetting< bool > ImportExportPrefs::LabelStyleSetting
static
Initial value:
{
wxT("/FileFormats/LabelStyleChoice"),
{
EnumValueSymbol{ wxT("Standard"), XXO("S&tandard") },
EnumValueSymbol{ wxT("Extended"), XXO("E&xtended (with frequency ranges)") },
},
0,
{
true, false,
},
}

Definition at line 30 of file ImportExportPrefs.h.

Referenced by LabelStruct::Export(), and PopulateOrExchange().


The documentation for this class was generated from the following files: