[Date Prev][Date Next]
[Thread Prev][Thread Next]
[Date Index]
[Thread Index]
[New search]
Subject: Preserve linebreaks
From: "Fredrik Nyman" <fredrik@xxxxxxxxxxxxxxx>
Date: Wed, 30 Jun 2004 17:26:20 +0200
Delivered-to: jeremyg-freeframers:org-ffarchiv@freeframers.org
Organization: PacketFront Sweden AB
Reply-to: fredrik@xxxxxxxxxxxxxxx
Sender: owner-framers@xxxxxxxxx
Hi again! Ok, so my XML importing is starting to look good now (not least thanks to some you). But I have of course run my head into another annoying feature. I have some text that I want to preserve the exact layout of. I've tried using programlisting, literallayout and screen, making them format the text with a paragraph tag using Courier. It all works out ok, but I fail to get empty rows (only a linebreak) to be preserved in the output. Now, the output that I've put in programlisting/literallayout/screen is generated in such way that some rows consists of a single ASCII 10 character, which on UNIX systems is interpreted as a line-break. h (104) a (97) r (114) d (100) w (119) a (97) r (114) e (101) (10) <- End of previous row (10) <- Empty row T (84) <- Start of next row y (121) p (112) e (101) The rules for each of these three all include the preserve line breaks; statement. element "literallayout" { is fm element "LiteralLayout"; preserve line breaks; } element "programlisting" { is fm element "ProgramListing"; preserve line breaks; } element "screen" { preserve line breaks; is fm element "Screen"; } I've tried all three in the hope that they might work differently in this regard. Of course they do not.. :-( When I open the XML file in framemaker (windows, 7.0p578), it converts everything nicely including putting the expected paragraph format on the section with screen/literallayout/programlisting, but those rows that contain a single linebreak are removed so instead of Flags: R - Routed, A - Routing accelerated by hardware C - Classified by hardware, F - Forwarded by hardware Type Source Destination Flgs ------------------------------------------------------------------------ I get Flags: R - Routed, A - Routing accelerated by hardware C - Classified by hardware, F - Forwarded by hardware Type Source Destination Flgs ------------------------------------------------------------------------ If I start the empty row with a whitespace it works of course, but I'd rather avoid the tedious job of going through all files just to add a whitespace on any empty row (or writing a tool for it). Ideas, anyone? -- Fredrik Nyman PacketFront Sweden AB http://www.packetfront.com/ ** To unsubscribe, send a message to majordomo@xxxxxxxxx ** ** with "unsubscribe framers" (no quotes) in the body. **