From ff997a5ff2e561fbeac590b590bd8e7c6d2a920b Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Fri, 14 Nov 2025 12:29:18 -0600 Subject: apply boxdraw patch for perfect box-drawing character alignment Applied st-boxdraw_v2-0.8.5.diff with manual adjustments for st 0.9: - Added boxdraw.c to build sources - Added ATTR_BOXDRAW attribute flag (bit 13, after ATTR_SELECTED) - Integrated boxdraw detection in tsetchar() function - Modified xmakeglyphfontspecs() to use boxdraw for applicable characters - Adjusted indentation for harfbuzz integration compatibility Benefits: - Box-drawing characters now align perfectly regardless of font - Improved visual quality for tmux, tree, dialog output - Covers Unicode U2500-U259F (lines/blocks) and U28XX (braille) --- config.def.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'config.def.h') diff --git a/config.def.h b/config.def.h index 924178f..319facd 100644 --- a/config.def.h +++ b/config.def.h @@ -73,6 +73,18 @@ static unsigned int blinktimeout = 800; */ static unsigned int cursorthickness = 2; +/* + * 1: render most of the lines/blocks characters without using the font for + * perfect alignment between cells (U2500 - U259F except dashes/diagonals). + * Bold affects lines thickness if boxdraw_bold is not 0. Italic is ignored. + * 0: disable (render all U25XX glyphs normally from the font). + */ +const int boxdraw = 0; +const int boxdraw_bold = 0; + +/* braille (U28XX): 1: render as adjacent "pixels", 0: use font */ +const int boxdraw_braille = 0; + /* * bell volume. It must be a value between -100 and 100. Use 0 for disabling * it -- cgit v1.2.3