Audacity 3.2.0
AudacityTextEntryDialog.h
Go to the documentation of this file.
1/*!********************************************************************
2
3 Audacity: A Digital Audio Editor
4
5 @file AudacityTextEntryDialog.h
6
7 Paul Licameli split from ErrorDialog.h
8
9 **********************************************************************/
10
11#ifndef __AUDACITY_TEXT_ENTRY_DIALOG__
12#define __AUDACITY_TEXT_ENTRY_DIALOG__
13
14#include <wx/textdlg.h> // to inherit
15#include "wxPanelWrapper.h" // to inherit
16
17/**************************************************************************/
21class WX_WRAPPERS_API AudacityTextEntryDialog
22 : public wxTabTraversalWrapper< wxTextEntryDialog >
23{
24public:
26 wxWindow *parent,
27 const TranslatableString& message,
28 const TranslatableString& caption, // don't use = wxGetTextFromUserPromptStr,
29 const wxString& value = {},
30 long style = wxTextEntryDialogStyle,
31 const wxPoint& pos = wxDefaultPosition)
33 parent,
34 message.Translation(), caption.Translation(), value, style, pos )
35 {}
36
37 void SetInsertionPointEnd();
38 bool Show(bool show = true) override;
39
40private:
41 bool mSetInsertionPointEnd{};
42};
43
44#endif // __AUDACITY_ERRORDIALOG__
Wrap wxTextEntryDialog so that caption IS translatable.
AudacityTextEntryDialog(wxWindow *parent, const TranslatableString &message, const TranslatableString &caption, const wxString &value={}, long style=wxTextEntryDialogStyle, const wxPoint &pos=wxDefaultPosition)
Holds a msgid for the translation catalog; may also bind format arguments.
wxString Translation() const
IMPORT_EXPORT_API ExportResult Show(ExportTask exportTask)