version 1.11, 2014/04/01 08:31:00 |
version 1.12, 2014/04/01 11:58:32 |
Line 817 ordinary(struct state *st, const char *buf, size_t sta |
|
Line 817 ordinary(struct state *st, const char *buf, size_t sta |
|
printf("\\&"); |
printf("\\&"); |
else if ('\n' == last && '\'' == buf[start]) |
else if ('\n' == last && '\'' == buf[start]) |
printf("\\&"); |
printf("\\&"); |
|
#if notyet |
|
/* |
|
* If we're in the SYNOPSIS, have square |
|
* brackets indicate that we're opening and |
|
* closing an optional context. |
|
*/ |
|
if (SECT_SYNOPSIS == st->sect) { |
|
if ('[' == buf[start] || |
|
']' == buf[start]) { |
|
if (last != '\n') |
|
putchar('\n'); |
|
if ('[' == buf[start]) |
|
printf(".Oo\n"); |
|
else |
|
printf(".Oc\n"); |
|
start++; |
|
continue; |
|
} |
|
} |
|
#endif |
putchar(last = buf[start++]); |
putchar(last = buf[start++]); |
if ('\\' == last) |
if ('\\' == last) |
putchar('e'); |
putchar('e'); |
Line 861 ordinary(struct state *st, const char *buf, size_t sta |
|
Line 881 ordinary(struct state *st, const char *buf, size_t sta |
|
for ( ; start < end; start++) |
for ( ; start < end; start++) |
if (' ' != buf[start] && '\t' != buf[start]) |
if (' ' != buf[start] && '\t' != buf[start]) |
break; |
break; |
} else if (start < end) { |
} |
/* |
|
* Default: print the character. |
|
* Escape initial control characters. |
|
*/ |
|
if ('\n' == last && '.' == buf[start]) |
|
printf("\\&"); |
|
else if ('\n' == last && '\'' == buf[start]) |
|
printf("\\&"); |
|
putchar(last = buf[start++]); |
|
if ('\\' == last) |
|
putchar('e'); |
|
} |
|
} |
} |
|
|
if (last != '\n') |
if (last != '\n') |