[PATCH 4/7] scanner: fix wrapped text to start with tabs and not space
y
y
Thu Feb 9 09:27:50 PST 2012
From: Tiago Vignatti <tiago.vignatti at intel.com>
Signed-off-by: Tiago Vignatti <tiago.vignatti at intel.com>
---
src/scanner.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/scanner.c b/src/scanner.c
index 13bb0cf..22596f8 100644
--- a/src/scanner.c
+++ b/src/scanner.c
@@ -165,8 +165,11 @@ desc_dump(char *src, int startcol)
if (col + len > 72 && isspace(src[i])) {
if (src[i+1]) {
putchar('\n');
- for (j = 0; j < startcol; j++)
- putchar(' ');
+ for (j = 0; j < startcol; j++) {
+ /* assuming a tab has 8 spaces */
+ if (j % 8 == 0)
+ printf("\t");
+ }
putchar(' ');
putchar('*');
putchar(' ');
--
1.7.5.4
More information about the wayland-devel
mailing list