mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-10-22 07:21:21 +00:00
fmt conversion: remove boost::format from documentation
This commit is contained in:
parent
8ac0abf3a0
commit
6ce65a23a7
@ -44,17 +44,17 @@ nanosecond precision.
|
|||||||
# Outputting messages to the user #
|
# Outputting messages to the user #
|
||||||
|
|
||||||
There are basically four functions that output stuff: `mxinfo()`,
|
There are basically four functions that output stuff: `mxinfo()`,
|
||||||
`mxverb()`, `mxwarn()` and `mxerror()`. Each takes either a string or
|
`mxverb()`, `mxwarn()` and `mxerror()`. Each takes a
|
||||||
an argument produced by `boost::format()` (see
|
string. Formatting is done via the `fmt::format()` if required (see
|
||||||
[the Boost::Format documentation](http://www.boost.org/doc/libs/1_47_0/libs/format/doc/format.html)
|
[the fmt documentation](http://fmtlib.net/latest/index.html) if you're
|
||||||
if you're not familiar with it), and `mxverb()` also takes a verbosity
|
not familiar with it), and `mxverb()` also takes a verbosity level
|
||||||
level argument.
|
argument.
|
||||||
|
|
||||||
`mxinfo()` is supposed to be used for messages that are always
|
`mxinfo()` is supposed to be used for messages that are always
|
||||||
output. Its messages must be translatable by using the `_()` macro,
|
output. Its messages must be translatable by using the `Y()` macro,
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
mxinfo(boost::format(_("Hello, %1%\n")) % user_name);
|
mxinfo(fmt::format(Y("Hello, {0}\n")) % user_name);
|
||||||
|
|
||||||
The same applies to `mxwarn()` and `mxerror()`. However, both prefix
|
The same applies to `mxwarn()` and `mxerror()`. However, both prefix
|
||||||
their messages with "Warning:" and "Error:" respectively. Also they
|
their messages with "Warning:" and "Error:" respectively. Also they
|
||||||
|
Loading…
Reference in New Issue
Block a user