diff options
author | James Ross-Gowan <rossy@jrg.systems> | 2020-05-27 22:52:25 +1000 |
---|---|---|
committer | James Ross-Gowan <rossy@jrg.systems> | 2020-05-29 19:48:51 +1000 |
commit | 102a083171478c69a8d2dd7de7c40d7687a9e809 (patch) | |
tree | 8fc36e0fa3de1f1206ffbe69b35a1bef15fb7251 /osdep/getpid.h | |
parent | 27e41c69aa4f18c226d0975ddb82799e2e5ea565 (diff) | |
download | mpv-102a083171478c69a8d2dd7de7c40d7687a9e809.tar.bz2 mpv-102a083171478c69a8d2dd7de7c40d7687a9e809.tar.xz |
terminal-win: handle 'Change Window Title' OSC sequence
This should make --term-title work in Windows 8.1 and below.
OSC sequences are defined in ECMA-48. The 'Change Window Title' command,
as far as I can tell, is a de-facto standard defined by xterm[1]. In
either case, this code is probably still not standards-compliant.
This also changes mp_write_console_ansi to convert to UTF-16 before
parsing control sequences, because that made it easier to pass the OSC
param to SetConsoleTitleW. I think it's also more correct to do it this
way, even though it doesn't really matter much for our limited terminal
parsing. As a side-effect of this, mp_write_console_ansi no longer
mutates its argument.
[1]: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
Diffstat (limited to 'osdep/getpid.h')
0 files changed, 0 insertions, 0 deletions