Audacity
3.2.0
src
commands
HelpCommand.h
Go to the documentation of this file.
1
/**********************************************************************
2
3
Audacity - A Digital Audio Editor
4
Copyright 1999-2018 Audacity Team
5
License: wxwidgets
6
7
Dan Horgan
8
James Crook
9
10
******************************************************************/
/*******************************************************************/
19
20
#ifndef __HELPCOMMAND__
21
#define __HELPCOMMAND__
22
23
#include "
CommandType.h
"
24
#include "
Command.h
"
25
26
class
HelpCommand
:
public
AudacityCommand
27
{
28
public
:
29
static
const
ComponentInterfaceSymbol
Symbol
;
30
int
mFormat
;
31
32
// ComponentInterface overrides
33
ComponentInterfaceSymbol
GetSymbol
()
const override
{
return
Symbol
;};
34
TranslatableString
GetDescription
()
const override
{
return
XO
(
"Gives help on a command."
);};
35
template
<
bool
Const>
bool
VisitSettings
(
SettingsVisitorBase<Const>
&
S
);
36
bool
VisitSettings
(
SettingsVisitor
&
S
)
override
;
37
bool
VisitSettings
(
ConstSettingsVisitor
&
S
)
override
;
38
void
PopulateOrExchange
(
ShuttleGui
&
S
)
override
;
39
bool
Apply
(
const
CommandContext
& context)
override
;
40
bool
ApplyInner
(
const
CommandContext
& context);
41
42
// AudacityCommand overrides
43
ManualPageID
ManualPage
()
override
{
return
L
"Extra_Menu:_Scriptables_II#help"
;}
44
public
:
45
wxString
mCommandName
;
46
};
47
48
class
CommentCommand
:
public
AudacityCommand
49
{
50
public
:
51
static
const
ComponentInterfaceSymbol
Symbol
;
52
int
mFormat
;
53
54
// ComponentInterface overrides
55
ComponentInterfaceSymbol
GetSymbol
()
const override
{
return
Symbol
;};
56
TranslatableString
GetDescription
()
const override
{
return
XO
(
"For comments in a macro."
);};
57
template
<
bool
Const>
bool
VisitSettings
(
SettingsVisitorBase<Const>
&
S
);
58
bool
VisitSettings
(
SettingsVisitor
&
S
)
override
;
59
bool
VisitSettings
(
ConstSettingsVisitor
&
S
)
override
;
60
void
PopulateOrExchange
(
ShuttleGui
&
S
)
override
;
61
bool
Apply
(
const
CommandContext
& context)
override
{
62
return
true
;
63
};
64
// AudacityCommand overrides
65
ManualPageID
ManualPage
()
override
{
return
L
"Extra_Menu:_Scriptables_II#comment"
;}
66
public
:
67
wxString
mComment
;
68
};
69
70
71
#endif
/* End of include guard: __HELPCOMMAND__ */
Command.h
Contains declaration of Command base class.
CommandType.h
Contains declarations for CommandType class.
XO
XO("Cut/Copy/Paste")
S
#define S(N)
Definition:
ToChars.cpp:64
AudacityCommand
Base class for command in Audacity.
Definition:
AudacityCommand.h:40
CommandContext
CommandContext provides additional information to an 'Apply()' command. It provides the project,...
Definition:
CommandContext.h:37
CommentCommand
Definition:
HelpCommand.h:49
CommentCommand::PopulateOrExchange
void PopulateOrExchange(ShuttleGui &S) override
Definition:
HelpCommand.cpp:130
CommentCommand::Apply
bool Apply(const CommandContext &context) override
Definition:
HelpCommand.h:61
CommentCommand::GetDescription
TranslatableString GetDescription() const override
Definition:
HelpCommand.h:56
CommentCommand::ManualPage
ManualPageID ManualPage() override
Definition:
HelpCommand.h:65
CommentCommand::mComment
wxString mComment
Definition:
HelpCommand.h:67
CommentCommand::mFormat
int mFormat
Definition:
HelpCommand.h:52
CommentCommand::Symbol
static const ComponentInterfaceSymbol Symbol
Definition:
HelpCommand.h:51
CommentCommand::GetSymbol
ComponentInterfaceSymbol GetSymbol() const override
Definition:
HelpCommand.h:55
CommentCommand::VisitSettings
bool VisitSettings(SettingsVisitorBase< Const > &S)
Definition:
HelpCommand.cpp:119
ComponentInterfaceSymbol
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
Definition:
ComponentInterfaceSymbol.h:27
HelpCommand
Command to get help about other commands.
Definition:
HelpCommand.h:27
HelpCommand::PopulateOrExchange
void PopulateOrExchange(ShuttleGui &S) override
Definition:
HelpCommand.cpp:70
HelpCommand::mCommandName
wxString mCommandName
Definition:
HelpCommand.h:45
HelpCommand::GetDescription
TranslatableString GetDescription() const override
Definition:
HelpCommand.h:34
HelpCommand::Symbol
static const ComponentInterfaceSymbol Symbol
Definition:
HelpCommand.h:29
HelpCommand::Apply
bool Apply(const CommandContext &context) override
Definition:
HelpCommand.cpp:83
HelpCommand::ApplyInner
bool ApplyInner(const CommandContext &context)
Definition:
HelpCommand.cpp:109
HelpCommand::mFormat
int mFormat
Definition:
HelpCommand.h:30
HelpCommand::GetSymbol
ComponentInterfaceSymbol GetSymbol() const override
Definition:
HelpCommand.h:33
HelpCommand::VisitSettings
bool VisitSettings(SettingsVisitorBase< Const > &S)
Definition:
HelpCommand.cpp:59
HelpCommand::ManualPage
ManualPageID ManualPage() override
Definition:
HelpCommand.h:43
SettingsVisitorBase
Visitor of effect or command parameters. This is a base class with lots of virtual functions that do ...
Definition:
SettingsVisitor.h:79
ShuttleGui
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition:
ShuttleGui.h:640
TaggedIdentifier< ManualPageIDTag >
TranslatableString
Holds a msgid for the translation catalog; may also bind format arguments.
Definition:
TranslatableString.h:32
Generated by
1.9.3