diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2022-01-04 21:01:36 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2022-01-13 12:42:11 +0000 |
| commit | 44aad0941fff3e314ae42c3c578cfa6d61913198 (patch) | |
| tree | a9da3a943e3ef9e61ba99553b79dd4cd7f7448d6 /dcs.c | |
| parent | scripts: generate-builtin-terminfo: add custom capability ‘Co’ (diff) | |
dcs: xtgettcap: handle boolean capabilities
Reply with DCS 1 + r <cap> ST
Diffstat (limited to 'dcs.c')
| -rw-r--r-- | dcs.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -99,6 +99,14 @@ xtgettcap_reply(struct terminal *term, const char *hex_cap_name, size_t len) if (entry == NULL) goto err; + if (entry->value == NULL) { + /* Boolean */ + term_to_slave(term, "\033P1+r", 5); + term_to_slave(term, hex_cap_name, len); + term_to_slave(term, "\033\\", 2); + goto out; + } + /* * Reply format: * \EP 1 + r cap=value \E\\ |
