summaryrefslogtreecommitdiffstats
path: root/DOCS/man/osc.rst
diff options
context:
space:
mode:
authorGuido Cella <guido@guidocella.xyz>2022-05-11 08:51:39 +0200
committerKacper Michajłow <kasper93@gmail.com>2024-03-21 03:20:14 +0100
commitc84bb1ce67f2dd3adb974c49a66d28c0cf55d39d (patch)
treedf016fd647a5486114442b20956f7b72b2de7a56 /DOCS/man/osc.rst
parentd6610a5b2f34e398e2ceba2a4da2b79e556b1c9e (diff)
downloadmpv-c84bb1ce67f2dd3adb974c49a66d28c0cf55d39d.tar.bz2
mpv-c84bb1ce67f2dd3adb974c49a66d28c0cf55d39d.tar.xz
osc.lua: escape text
Escape all messages in osc.lua, because other than the title they weren't being escaped at all. If for example you did mpv foo.mp4 '{\fs50}bar.mp4' and script-message osc-playlist, it would just render the second entry as bar.mp4 in big text. The title was escaped partially, now the escaping is complete because: - It escapes \. Backslashes at the end of the title are escaped instead of being stripped, and \n, \N and \h are now printed verbatim. In particular, "\\n" is no longer converted to space and is printed verbatim instead which is more correct. - Newlines ("\n", not the "\\n" escape sequence) are converted to spaces instead of rendering them and messing up the text positioning within the OSC. - Spaces at the start are preserved. Fixes #11209, fixes #11275.
Diffstat (limited to 'DOCS/man/osc.rst')
-rw-r--r--DOCS/man/osc.rst2
1 files changed, 1 insertions, 1 deletions
diff --git a/DOCS/man/osc.rst b/DOCS/man/osc.rst
index 61591b7023..9ed338a965 100644
--- a/DOCS/man/osc.rst
+++ b/DOCS/man/osc.rst
@@ -307,7 +307,7 @@ Configurable Options
String that supports property expansion that will be displayed as
OSC title.
- ASS tags are escaped, and newlines and trailing slashes are stripped.
+ ASS tags are escaped and newlines are converted to spaces.
``tooltipborder``
Default: 1