zygo

ncurses gopher client
Log | Files | Refs

commit 8c2bbdd58a3c97aedd10042e6065588140214f8a
parent fec6c34d525b790f85b646d4986734a78041c472
Author: hhvn <dev@hhvn.uk>
Date:   Fri, 27 May 2022 21:45:25 +0100

Customizable seperators

Diffstat:
M.config.hhvn.h | 2++
Mconfig.def.h | 2++
Mzygo.c | 4++--
3 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/.config.hhvn.h b/.config.hhvn.h @@ -1,5 +1,7 @@ static char *plumber = "plumb"; static char *yanker = "xclip"; +static char *normsep = "│"; +static char *wrapsep = "/"; static int parallelplumb = 1; static int stimeout = 5; static int regexflags = REG_ICASE|REG_EXTENDED; diff --git a/config.def.h b/config.def.h @@ -1,5 +1,7 @@ static char *plumber = "xdg-open"; static char *yanker = "xclip"; +static char *normsep = "│"; /* separates link number/info and description */ +static char *wrapsep = "/"; /* same as above, but for wrapped lines */ static int parallelplumb = 0; static int stimeout = 5; static int regexflags = REG_ICASE|REG_EXTENDED; diff --git a/zygo.c b/zygo.c @@ -675,7 +675,7 @@ draw_line(Elem *e, int nwidth) { attron(COLOR_PAIR(getscheme(e)->pair)); printw("%s ", getscheme(e)->name); attroff(A_COLOR); - printw("| "); + printw("%s ", normsep); } else { attroff(A_COLOR); } @@ -699,7 +699,7 @@ draw_line(Elem *e, int nwidth) { x++; if (x == COLS) { if (nwidth) { - printw("%1$ *2$s / ", "", nwidth + 6); + printw("%1$ *2$s %3$s ", "", nwidth + 6, wrapsep); x = 9 + nwidth; } y++;