X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=makedoc.c;h=4829215364295c680419f4b29ee2bd236d73752d;hp=3652332ca917ab6d7b72f8fe6f86f235dce16f16;hb=308c7080ccca40d4865d8810f5528331d9ed61ff;hpb=6ae7bf50506bd40e5469719299464bdf5bc867bd diff --git a/makedoc.c b/makedoc.c index 3652332..4829215 100644 --- a/makedoc.c +++ b/makedoc.c @@ -191,7 +191,7 @@ static void add_var (const char *name) { outbuf = realloc (outbuf, (++outcount) * sizeof (var_t)); outbuf[outcount - 1].seen = 0; - outbuf[outcount - 1].name = strdup (name); + outbuf[outcount - 1].name = strdup(name); outbuf[outcount - 1].descr = NULL; } @@ -207,7 +207,7 @@ static int add_s (const char *s) } if (lold == 0) - outbuf[outcount - 1].descr = strdup (s); + outbuf[outcount - 1].descr = strdup(s); else { outbuf[outcount - 1].descr = realloc (outbuf[outcount - 1].descr, lold + lnew + 1); @@ -608,14 +608,17 @@ static int sgml_fputc (int c) return add_s ("<"); case '>': return add_s (">"); +#if 0 case '$': return add_s ("$"); case '_': return add_s ("_"); case '%': return add_s ("%"); +#endif case '&': return add_s ("&"); +#if 0 case '\\': return add_s ("\"); case '"': @@ -626,6 +629,7 @@ static int sgml_fputc (int c) return add_s ("]"); case '~': return add_s ("˜"); +#endif default: return add_c (c); } @@ -733,13 +737,11 @@ static void print_confline (const char *varname, int type, const char *val) /* SGML based manual */ case F_SGML: { - add_s ("\n\n"); + add_s ("\n<muttng-doc:vardef name=\""); sgml_fputs (varname); - add_s ("\nType: "); + add_s ("\">\nType: "); add_s (type2human (type)); - add_s ("\n\n"); + add_s ("\n"); if (type == DT_STR || type == DT_RX || type == DT_ADDR || type == DT_PATH) { @@ -1161,7 +1163,7 @@ static int print_it (int special, char *str, int docstat) } case SP_END_SECT: { - add_s ("\n"); + add_s ("\n"); break; } case SP_STR: @@ -1198,7 +1200,7 @@ void print_ref (int output_dollar, const char *ref) sgml_id_fputs (ref); add_s ("\">\n"); if (output_dollar) - add_s ("$"); + add_s ("$"); sgml_fputs (ref); add_s (""); break;