ADOBE FRAMEMAKER 10
MIF Reference
156
LevelFormatRule statement
The LevelFormatRule statement contains statements that specify an element’s formatting on the basis of the level
to which the element is nested within specific types of ancestor elements.
The
LevelFormatRule statement contains a CountElements statement listing the tags of elements to count
among the element’s ancestors and a statement specifying the tag of the element at which to stop counting. The
LevelFormatRule
statement also contains an If statement, zero or more ElseIf statements, and an optional Else
statement. The If, ElseIf, and Else statements define the formatting applied to the element at specified levels
of nesting within the ancestor elements specified by the
CountElements statement.
The
LevelFormatRule statement must appear in a format rules statement, such as an EDTextFormatRules or
EDEndElementRules
statement.
Syntax
If, ElseIf, and Else statements
If, ElseIf, and Else statements specify clauses within ContextFormatRule and LevelFormatRule state-
ments. In a
ContextFormatRule statement, they specify a context and one or more statements that define how to
change formatting when the context applies. If an
If or ElseIf statement does not include a Context or Level
statement, or the Context or Level statement contains an empty string, this indicates that the If or ElseIf
statement applies in all contexts.
In a
ContextFormatRule statement, If and ElseIf, and Else statements take the following form:
<LevelFormatRule
Begin level format rule
<CountElements
Optional list of elements to count among the element’s ancestors
<CountElement
tagstring
>
Tag of element to count
<CountElement
tagstring
>
Additional statements as needed
…
>
End of CountElements statement
<StopCountingAt
tagstring
>
Optional tag of element at which to stop counting
<If…>
An If clause (see “If, ElseIf, and Else statements” on page 156)
<ElseIf…>
An optional ElseIf clause (see “If, ElseIf, and Else statements” on
page 156)
<ElseIf…>
Additional statements as needed
…
<Else…>
An optional Else clause (see “If, ElseIf, and Else statements” on
page 156)
>
End of LevelFormatRule
<If
Begin If clause
<Context
contextstring>
String specifying a context, such as Section < Section. If this
context applies to the element, the following formatting statements are
used to format the element.