Heinz-Jürgen Oertel <[EMAIL PROTECTED]> writes:
> Am Mittwoch, 2. November 2005 14:13 schrieb Rasmus Hahn: > > Hello, > > > > i am trying to get 2 preformatted sections with `groff -ms -Thtml ' > > (input at end), but only the first part is preformatted in html > > output. When using -Tps instead of -Thtml or not using the .NH in > > between the 2 sections it seems to work. Is this a bug or am i doing > > wrong? If a bug (seems to me), is the bug-groff list the place to > > post it; on first sight at the archives of bug-groff it looks rather > > like a spam collection database? > > > > Greetings - Rasmus > > > > --- groff input for -ms: ------------------------------- > > > > .NH 1 > > Head1 > > .LP > > .DS > > .ft C > > should be preformatted and is > > .R > > .DE > > > > .NH 1 > > Head2 > > .LP > > .DS > > .ft C > > should be preformatted but isnt > > .R > > .DE > > -------------------------------------------------------- > > > I get the same result. Seems to be a bug for me too. > Placing some text between .LP after the heading and .DS leads to correct > results. > > .NH 1 > Head2 > .LP > Text > .DS > > Heinz Hi, yes it is a bug, it looks like post-grohtml is not seeing the font change during the heading and therefore ignoring the second use of fixed font.. thanks for the report - below is a patch which fixes the bug, Gaius --- groff-cvs/src/devices/grohtml/post-html.cpp 2005-05-26 22:01:58.000000000 +0100 +++ groff-html/src/devices/grohtml/post-html.cpp 2005-11-07 10:28:34.000000000 +0000 @@ -2577,7 +2577,12 @@ determine_header_level(level); write_header(); - // finally set the output to neutral for after the header + /* + * finally set the output font to uninitialized, thus forcing + * the new paragraph to start a new font block. + */ + + output_style.f = 0; g = page_contents->glyphs.get_data(); page_contents->glyphs.move_left(); // so that next time we use old g } _______________________________________________ Groff mailing list Groff@gnu.org http://lists.gnu.org/mailman/listinfo/groff