[xsl] relative relative indents

Subject: [xsl] relative relative indents
From: "Bob Stayton" <bobs@xxxxxxxxxxxx>
Date: Sun, 26 Nov 2006 00:23:15 -0800
Is there a way to form relative relative indents in XSL-FO 1.0?
Here, the first "relative" means relative to the writing mode, and
the second "relative" means relative to the containing block.
I'm trying to create nested indents from nested source elements
in a language-independent stylesheet, and I'm not finding
the right property combination.

For example, in left-to-right writing mode, I can use margin-left
in nested fo:block elements:

<fo:block margin-left="1in">First block.
 <fo:block margin-left="1in">Second block.
   <fo:block margin-left="1in">Third block.

The third block will be indented 3in from the left region boundary.

But "margin-left" is an absolute property.  If I use this stylesheet
for a language in writing mode right-to-left, this does not have
the intended effect.  At first I thought that
space-start would be the corresponding property that is relative
to the writing-mode.  But space-start only applies to inline areas,
not block areas.

There doesn't seem to be a "margin-start" property, and start-indent
does not produce the same additive effect.  Is there any way to
accomplish this nesting of indents without having to resort to
using nested list-blocks or computing a sum for a start-indent?

Bob Stayton
Sagehill Enterprises
DocBook Consulting

Current Thread