From 4c954be7a6d86b21da512fc533eb3362ac737221 Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Mon, 31 May 2021 17:10:05 +0200 Subject: config: add boolean option tweak.pua-double-width When enabled, PUA (Private Usage Area) codepoints are always treated as double-width glyphs, regardless of the actual glyph width. Requires allow-overflowing-double-width-glyphs=yes --- config.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'config.c') diff --git a/config.c b/config.c index 92ef0c99..17d6ce5f 100644 --- a/config.c +++ b/config.c @@ -2005,6 +2005,12 @@ parse_section_tweak( LOG_WARN("tweak: disabled overflowing double-width glyphs"); } + else if (strcmp(key, "pua-double-width") == 0) { + conf->tweak.pua_double_width = str_to_bool(value); + if (conf->tweak.pua_double_width) + LOG_WARN("tweak: PUA double width glyphs enabled"); + } + else if (strcmp(key, "damage-whole-window") == 0) { conf->tweak.damage_whole_window = str_to_bool(value); if (conf->tweak.damage_whole_window) @@ -2573,6 +2579,7 @@ config_load(struct config *conf, const char *conf_path, .damage_whole_window = false, .box_drawing_base_thickness = 0.04, .box_drawing_solid_shades = true, + .pua_double_width = false, }, .notifications = tll_init(), -- cgit v1.3