From d1f1f8d600d26e5bb01736ad53269bed555043d5 Mon Sep 17 00:00:00 2001 From: Kristaps Dzonsons Date: Fri, 24 Dec 2010 00:46:49 +0000 Subject: Drastically fix -T[x]html's handling of font-escape mode changes (i.e., using \fI or \fP). Now, using these modes will cause a font to be rendered for each word; furthermore, setting mode within a word will do the correct thing. Second, make -man use real font tags (B, I, SMALL) to set its font instead of using font modes and fix up the pre-macro unsetting of the current mode. This fixes how roff.7 wasn't validating (

closing out a font mode) and has been checked against gcc.1 (more will come). I considered failure to validate OUR manual to be a show-stopper for the up-coming release. --- html.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'html.h') diff --git a/html.h b/html.h index 2d11280b..63575902 100644 --- a/html.h +++ b/html.h @@ -1,4 +1,4 @@ -/* $Id: html.h,v 1.34 2010/12/22 11:15:16 kristaps Exp $ */ +/* $Id: html.h,v 1.35 2010/12/24 00:46:49 kristaps Exp $ */ /* * Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons * @@ -50,6 +50,7 @@ enum htmltag { TAG_I, TAG_U, TAG_CODE, + TAG_SMALL, TAG_MAX }; @@ -123,9 +124,9 @@ struct html { char *style; char buf[BUFSIZ]; size_t buflen; - struct tag *metaf; - enum htmlfont metal; - enum htmlfont metac; + struct tag *metaf; /* current open font scope */ + enum htmlfont metal; /* last used font */ + enum htmlfont metac; /* current font mode */ enum htmltype type; }; @@ -133,7 +134,6 @@ struct roffsu; void print_gen_decls(struct html *); void print_gen_head(struct html *); -struct tag *print_ofont(struct html *, enum htmlfont); struct tag *print_otag(struct html *, enum htmltag, int, const struct htmlpair *); void print_tagq(struct html *, const struct tag *); -- cgit v1.2.3