Adobe 65030365 - FrameMaker - PC Developer's Manual page 468

Structure application developer's guide
Hide thumbs Also See for 65030365 - FrameMaker - PC:
Table of Contents

Advertisement

26
p r e s e r v e l i n e b r e a k s
Arguments
None
Details
For an element using this rule, the software writes a an RE (line break) immediately after
the open tag and immediately before the close tag.
For an element using this rule, on export, FrameMaker writes a space character entity
reference and an RE (line break) for each necessary line break in the markup file. See
the "line break" rule for information on how FrameMaker determines where to put these
line breaks by default. Forced returns (shift-return) translate as RE characters (line
breaks) in the markup file.
For SGML, the space character entity uses the ISO entities reference (&#SPACE).
For XML, no entity reference is written for the space character.
For XML, this rule adds the xml:space attribute to the affected elements, with a value
of preserved. This attribute directs XML applications to respect the whitespace
characters in the element's content. On import this attribute is retained—if the EDD for
your template doesn't specify an xml:space attribute for the given element, then that
attribute will be invalid. You can either define this attribute in your EDD, or use read/write
rules to drop the attribute on import.
For export and import to have the same results, preserve line breaks must be
specified for the same elements. For example, assume you use preserve line
breaks on export for an element named Code. FrameMaker writes a space character
entity reference and an RE (line break) when a line approaches the maximum line length,
and it writes RE characters (line breaks) for forced returns. Now assume you remove
preserve line breaks from the rules for the Code element. On import, FrameMaker will
translate as spaces the space character entity reference/RE pairs, and as spaces any
RE characters (line breaks) not removed by the parser (default behavior). Thus the
forced returns (shift-return) are lost and the imported file is not the same as the exported
file.
When importing markup, preserve line breaks overrides the line break is
space rule, if that rule is set. On import, preserve line breaks has the same effect
for the specified element as the line break is forced return rule.
Examples
The following rule preserves line breaks on import and export for the element named
code:
fm element "code" {
}
Read/Write Rules Reference
is fm element "Code";
preserve line breaks;
450

Advertisement

Table of Contents
loading

This manual is also suitable for:

Framemaker 7.1

Table of Contents