From 52d5c7f7c4fdc5cbf175bb70c32e88a374045280 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Fri, 23 Apr 2004 17:20:07 +0000 Subject: Enhance the text backend to support configurable quote characters, configurable emphasis characters, various other configurable bits which have been marked FIXME in the code for a while, and also to warn when a code paragraph line is too long (because that was the only other thing labelled FIXME). Fallback options are implemented, and defaults set accordingly. A UTF-8 text output file now looks like proper UTF-8. [originally from svn r4128] --- error.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'error.c') diff --git a/error.c b/error.c index 42eea37..0e90f0c 100644 --- a/error.c +++ b/error.c @@ -16,6 +16,7 @@ static void do_error(int code, va_list ap) { char error[1024]; char c; + int i, j; char *sp, *sp2; wchar_t *wsp; filepos fpos, fpos2; @@ -221,6 +222,14 @@ static void do_error(int code, va_list ap) { " node names; removing", c); flags = FILEPOS; break; + case err_text_codeline: + fpos = *va_arg(ap, filepos *); + i = va_arg(ap, int); + j = va_arg(ap, int); + sprintf(error, "warning: code paragraph line is %d chars wide, wider" + " than body width %d", i, j); + flags = FILEPOS; + break; case err_whatever: sp = va_arg(ap, char *); vsprintf(error, sp, ap); -- cgit v1.1