Only treat the first tab as the alignment point
parent
71b0536536
commit
0705f09310
11
ui.c
11
ui.c
|
@ -384,9 +384,14 @@ static void wordWrap(WINDOW *win, const char *str) {
|
||||||
struct Style style = Reset;
|
struct Style style = Reset;
|
||||||
while (*str) {
|
while (*str) {
|
||||||
if (*str == '\t') {
|
if (*str == '\t') {
|
||||||
waddch(win, ' ');
|
if (align) {
|
||||||
getyx(win, y, align);
|
waddch(win, '\t');
|
||||||
str++;
|
str++;
|
||||||
|
} else {
|
||||||
|
waddch(win, ' ');
|
||||||
|
getyx(win, y, align);
|
||||||
|
str++;
|
||||||
|
}
|
||||||
} else if (*str == ' ') {
|
} else if (*str == ' ') {
|
||||||
getyx(win, y, x);
|
getyx(win, y, x);
|
||||||
const char *word = &str[strspn(str, " ")];
|
const char *word = &str[strspn(str, " ")];
|
||||||
|
|
Loading…
Reference in New Issue