From 0bad744d68a0ac066c5e648c8fd1673d1459478f Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 16 Feb 2013 23:24:10 +0100 Subject: options: parse C-style escapes for some options Being able to insert newline characters ("\n") is useful for --osd-status-msg, and possibly also for anything that prints to the terminal. Espcially --term-osd-esc looks relatively useless without being able to specify escapes. Maybe parsing escapes should happen during command line / config parsing instead (for all options). --- DOCS/man/en/options.rst | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'DOCS') diff --git a/DOCS/man/en/options.rst b/DOCS/man/en/options.rst index b1d630f68e..14548f807c 100644 --- a/DOCS/man/en/options.rst +++ b/DOCS/man/en/options.rst @@ -1437,7 +1437,7 @@ --playing-msg= Print out a string before starting playback. The string is expanded for - properties, e.g. ``--playing-msg=file: \${filename}`` will print the string + properties, e.g. ``--playing-msg=file: ${filename}`` will print the string ``file:`` followed by a space and the currently played filename. The following expansions are supported: @@ -1445,7 +1445,7 @@ \${NAME} Expands to the value of the property ``NAME``. If ``NAME`` starts with ``=``, use the raw value of the property. If retrieving the property - fails, expand to an error string. (Use ``\${NAME:}`` with a trailing + fails, expand to an error string. (Use ``${NAME:}`` with a trailing ``:`` to expand to an empty string instead.) \${NAME:STR} Expands to the value of the property ``NAME``, or ``STR`` if the @@ -1456,14 +1456,19 @@ \${?NAME:STR} Expands to ``STR`` (recursively) if the property ``NAME`` is available. \$\$ - Expands to ``\$``. + Expands to ``$``. \$} Expands to ``}``. (To produce this character inside recursive expansion.) \$> - Disable property expansion and special handling of ``\$`` for the rest + Disable property expansion and special handling of ``$`` for the rest of the string. + This option also parses C-style escapes. Example: + + - ``\n`` becomes a newline character + - ``\\`` expands to ``\`` + --status-msg= Print out a custom string during playback instead of the standard status line. Expands properties. See ``--playing-msg``. -- cgit v1.2.3