mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
[plain] one level of indentation less
This commit is contained in:
parent
d43028a0cf
commit
b1317c3e46
@ -857,24 +857,23 @@ fixup_tables(struct plain_renderer *renderer)
|
||||
struct line *next_line = y < renderer->lineno - 1 ? &renderer->document->data[y + 1] : NULL;
|
||||
|
||||
for (x = 0; x < line->length; x++) {
|
||||
#ifdef CONFIG_UTF8
|
||||
unicode_val_T ch = line->chars[x].data;
|
||||
#else
|
||||
unsigned char ch = line->chars[x].data;
|
||||
#endif
|
||||
if (ch == '+' || ch == '-' || ch == '|') {
|
||||
int dir;
|
||||
#ifdef CONFIG_UTF8
|
||||
unicode_val_T prev_char = x > 0 ? line->chars[x - 1].data : ' ';
|
||||
unicode_val_T next_char = x < line->length - 1 ? line->chars[x + 1].data : ' ';
|
||||
unicode_val_T up_char = (prev_line && x < prev_line->length) ? prev_line->chars[x].data : ' ';
|
||||
unicode_val_T down_char = (next_line && x < next_line->length) ? next_line->chars[x].data : ' ';
|
||||
unicode_val_T ch = line->chars[x].data;
|
||||
unicode_val_T prev_char, next_char, up_char, down_char;
|
||||
#else
|
||||
unsigned char prev_char = x > 0 ? line->chars[x - 1].data : ' ';
|
||||
unsigned char next_char = x < line->length - 1 ? line->chars[x + 1].data : ' ';
|
||||
unsigned char up_char = (prev_line && x < prev_line->length) ? prev_line->chars[x].data : ' ';
|
||||
unsigned char down_char = (next_line && x < next_line->length) ? next_line->chars[x].data : ' ';
|
||||
unsigned char ch = line->chars[x].data;
|
||||
unsigned char prev_char, next_char, up_char, down_char;
|
||||
#endif
|
||||
if (ch != '+' && ch != '-' && ch != '|') {
|
||||
continue;
|
||||
}
|
||||
|
||||
prev_char = x > 0 ? line->chars[x - 1].data : ' ';
|
||||
next_char = x < line->length - 1 ? line->chars[x + 1].data : ' ';
|
||||
up_char = (prev_line && x < prev_line->length) ? prev_line->chars[x].data : ' ';
|
||||
down_char = (next_line && x < next_line->length) ? next_line->chars[x].data : ' ';
|
||||
|
||||
switch (ch) {
|
||||
case '+':
|
||||
dir = 0;
|
||||
@ -951,7 +950,6 @@ fixup_tables(struct plain_renderer *renderer)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user