Audacity 3.2.0
|
#include <NumericConverterFormatter.h>
Classes | |
struct | ConversionResult |
Public Member Functions | |
virtual | ~NumericConverterFormatter () |
virtual void | UpdateFormatForValue (double value, bool canShrink) |
Potentially updates the format so it can fit the value . Default implementation is empty. More... | |
virtual ConversionResult | ValueToString (double value, bool nearest) const =0 |
virtual std::optional< double > | StringToValue (const wxString &value) const =0 |
virtual double | SingleStep (double value, int digitIndex, bool upwards) const =0 |
const wxString & | GetPrefix () const |
const NumericFields & | GetFields () const |
const DigitInfos & | GetDigitInfos () const |
Public Member Functions inherited from Observer::Publisher< NumericConverterFormatChangedMessage > | |
Publisher (ExceptionPolicy *pPolicy=nullptr, Alloc a={}) | |
Constructor supporting type-erased custom allocation/deletion. More... | |
Publisher (Publisher &&)=default | |
Publisher & | operator= (Publisher &&)=default |
Subscription | Subscribe (Callback callback) |
Connect a callback to the Publisher; later-connected are called earlier. More... | |
Subscription | Subscribe (Object &obj, Return(Object::*callback)(Args...)) |
Overload of Subscribe takes an object and pointer-to-member-function. More... | |
Protected Attributes | |
wxString | mPrefix |
NumericFields | mFields |
DigitInfos | mDigits |
Additional Inherited Members | |
Public Types inherited from Observer::Publisher< NumericConverterFormatChangedMessage > | |
using | message_type = NumericConverterFormatChangedMessage |
using | CallbackReturn = std::conditional_t< true, void, bool > |
using | Callback = std::function< CallbackReturn(const NumericConverterFormatChangedMessage &) > |
Type of functions that can be connected to the Publisher. More... | |
Static Public Attributes inherited from Observer::Publisher< NumericConverterFormatChangedMessage > | |
static constexpr bool | notifies_all |
Protected Member Functions inherited from Observer::Publisher< NumericConverterFormatChangedMessage > | |
CallbackReturn | Publish (const NumericConverterFormatChangedMessage &message) |
Send a message to connected callbacks. More... | |
Definition at line 60 of file NumericConverterFormatter.h.
|
virtual |
Definition at line 57 of file NumericConverterFormatter.cpp.
const DigitInfos & NumericConverterFormatter::GetDigitInfos | ( | ) | const |
const NumericFields & NumericConverterFormatter::GetFields | ( | ) | const |
const wxString & NumericConverterFormatter::GetPrefix | ( | ) | const |
|
pure virtual |
|
pure virtual |
|
virtual |
Potentially updates the format so it can fit the value
. Default implementation is empty.
Reimplemented in anonymous_namespace{BeatsNumericConverterFormatter.cpp}::BeatsFormatter.
Definition at line 61 of file NumericConverterFormatter.cpp.
|
pure virtual |
GetFields().size() == result.fieldValueStrings.size()
Implemented in anonymous_namespace{ParsedNumericConverterFormatter.cpp}::ParsedNumericConverterFormatter, and anonymous_namespace{BeatsNumericConverterFormatter.cpp}::BeatsFormatter.
|
protected |
Definition at line 90 of file NumericConverterFormatter.h.
Referenced by GetDigitInfos().
|
protected |
Definition at line 89 of file NumericConverterFormatter.h.
Referenced by GetFields().
|
protected |
Definition at line 87 of file NumericConverterFormatter.h.
Referenced by GetPrefix().