From 597785bbc6fc9252b815a280e03f70ee107068ae Mon Sep 17 00:00:00 2001 From: Aleksa Vučković Date: Thu, 20 Jan 2022 23:11:39 +0100 Subject: boxdraw patch --- st.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'st.h') diff --git a/st.h b/st.h index 78762a2..a575602 100644 --- a/st.h +++ b/st.h @@ -33,6 +33,7 @@ enum glyph_attribute { ATTR_WRAP = 1 << 8, ATTR_WIDE = 1 << 9, ATTR_WDUMMY = 1 << 10, + ATTR_BOXDRAW = 1 << 11, ATTR_BOLD_FAINT = ATTR_BOLD | ATTR_FAINT, }; @@ -113,6 +114,16 @@ void *xmalloc(size_t); void *xrealloc(void *, size_t); char *xstrdup(const char *); +int isboxdraw(Rune); +ushort boxdrawindex(const Glyph *); +#ifdef XFT_VERSION +/* only exposed to x.c, otherwise we'll need Xft.h for the types */ +void boxdraw_xinit(Display *, Colormap, XftDraw *, Visual *); +void drawboxes(int, int, int, int, XftColor *, XftColor *, const XftGlyphFontSpec *, int); +#endif + +int xgetcolor(int x, unsigned char *r, unsigned char *g, unsigned char *b); + /* config.h globals */ extern char *utmp; extern char *scroll; @@ -125,5 +136,6 @@ extern char *termname; extern unsigned int tabspaces; extern unsigned int defaultfg; extern unsigned int defaultbg; +extern const int boxdraw, boxdraw_bold, boxdraw_braille; extern unsigned int defaultcs; extern float alpha; -- cgit v1.2.3