Audacity 3.2.0
NumericConverterFormats.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: GPL-2.0-or-later */
2/**********************************************************************
3
4 Audacity: A Digital Audio Editor
5
6 @file NumericConverterFormats.h
7
8 Dmitry Vedenko
9
10 **********************************************************************/
11#pragma once
12
15
17
19{
21{
23 const NumericConverterType& type, const NumericFormatSymbol& symbol);
24};
25
27NUMERIC_FORMATS_API NumericFormatSymbol Default(const NumericConverterType& type);
28
30NUMERIC_FORMATS_API NumericFormatSymbol Lookup(
31 const FormatterContext& context, const NumericConverterType& type,
32 const NumericFormatID& formatIdentifier);
33
35NUMERIC_FORMATS_API NumericFormatSymbol TimeAndSampleFormat();
36NUMERIC_FORMATS_API NumericFormatSymbol SecondsFormat();
38NUMERIC_FORMATS_API NumericFormatSymbol HundredthsFormat();
39NUMERIC_FORMATS_API NumericFormatSymbol MillisecondsFormat();
40NUMERIC_FORMATS_API NumericFormatSymbol HertzFormat();
41NUMERIC_FORMATS_API NumericFormatSymbol OctavesFormat();
42
44NUMERIC_FORMATS_API NumericFormatID
45GetBestDurationFormat(const NumericFormatID& timeFormat);
46}
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
A context in which formatter operates.
An explicitly nonlocalized string, not meant for the user to see.
Definition: Identifier.h:22
NUMERIC_FORMATS_API NumericFormatSymbol HoursMinsSecondsFormat()
NUMERIC_FORMATS_API NumericFormatSymbol MillisecondsFormat()
NUMERIC_FORMATS_API NumericFormatSymbol HundredthsFormat()
NUMERIC_FORMATS_API NumericFormatSymbol DefaultSelectionFormat()
NUMERIC_FORMATS_API NumericFormatSymbol HertzFormat()
NUMERIC_FORMATS_API NumericFormatSymbol SecondsFormat()
NumericFormatSymbol Default(const NumericConverterType &type)
Returns the default format for the type or empty symbol, if no default symbol is registered.
NUMERIC_FORMATS_API NumericFormatSymbol OctavesFormat()
NUMERIC_FORMATS_API NumericFormatSymbol Lookup(const FormatterContext &context, const NumericConverterType &type, const NumericFormatID &formatIdentifier)
Looks up the format, returns Default for the type if the format is not registered.
NUMERIC_FORMATS_API NumericFormatID GetBestDurationFormat(const NumericFormatID &timeFormat)
Return the best duration format for the given time format. Currently is an identity function.
NUMERIC_FORMATS_API NumericFormatSymbol TimeAndSampleFormat()
DefaultFormatRegistrator(const NumericConverterType &type, const NumericFormatSymbol &symbol)