-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path2526.diff
67 lines (63 loc) · 2.55 KB
/
2526.diff
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
parent 78019b896ba0e59ba886ecf500747cbe77dbc7cb (4.7.5-189-g78019b8)
commit 184c812af135a66c5e60ed09741bf1fecfe01666
Author: Jan Engelhardt <jengelh@medozas.de>
Date: Thu Mar 31 02:52:16 2011 +0200
mcedit: use Office/Word-style tab markers
Less clutter on screen.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
---
src/editor/editdraw.c | 33 +++++----------------------------
1 files changed, 5 insertions(+), 28 deletions(-)
diff --git a/src/editor/editdraw.c b/src/editor/editdraw.c
index 7fbb294..679846e 100644
--- a/src/editor/editdraw.c
+++ b/src/editor/editdraw.c
@@ -426,41 +426,18 @@ edit_draw_this_line (WEdit * edit, long b, long row, long start_col, long end_co
if (tty_use_colors () &&
((visible_tabs || (visible_tws && q >= tws)) && enable_show_tabs_tws))
{
+ int m = (i - 1) / 2;
if (p->style & MOD_MARKED)
c = p->style;
else if (book_mark)
c |= book_mark << 16;
else
c = p->style | MOD_WHITESPACE;
- if (i > 2)
- {
- p->ch = '<';
+ while (i > 0) {
+ --i;
p->style = c;
- p++;
- while (--i > 1)
- {
- p->ch = '-';
- p->style = c;
- p++;
- }
- p->ch = '>';
- p->style = c;
- p++;
- }
- else if (i > 1)
- {
- p->ch = '<';
- p->style = c;
- p++;
- p->ch = '>';
- p->style = c;
- p++;
- }
- else
- {
- p->ch = '>';
- p->style = c;
- p++;
+ p->ch = (i != m) ? ' ' : 0x2192;
+ ++p;
}
}
else if (tty_use_colors () && visible_tws && q >= tws && enable_show_tabs_tws)
--
# Created with git-export-patch