Pages: 1
Print
Author Topic: "Left indent" extension property in CSS  (Read 4575 times)
Allison
Member

Posts: 5


« on: June 10, 2009, 11:23:55 AM »

Hello,

The XMetaL Customization Guide contains this information about a left indent extension property:

"Left indent - Use this property to display the element(s) indicated at a set distance from the left margin, regardless of the position of any ancestor element."

Can anyone give me an example of how to make this work?  I don't seem to be using the correct CSS syntax.  I am in 4.6, if that makes a difference.

Many thanks!

Allison
Logged
Derek Read
Program Manager (XMetaL)
Administrator
Member

Posts: 2621



WWW
« Reply #1 on: June 10, 2009, 11:57:11 AM »

Perhaps to understand this it would help to compare it to margin-left, which is standard CSS.

Try adding the following to the end of the journalist.css and creating a new Journalist "Article" using the template provided for that demo:

Sect1 {left-indent: 4em;}
Para {left-indent: 4em;}


Both Sect1 and Para should appear 4em from the left edge of the document.

Now, for comparison purposes use some standard CSS:

Sect1 {margin-left: 4em;}
Para {margin-left: 4em;}


Sect1 appears 4em from the left edge of it's parent element Article, which by default is not indented so in effect Sect1 is moved over 4em to the right. Para in turn appears 4em from the left edge of its parent, which in this case is Sect1, so to total effect on Para in this case is to move it 8em to the right.

History:
The reason this proprietary CSS property was added was primarily to support some of our government clients (US House of Reps, Congress, etc). They produce legal documents (including Federal Bills and other similar legislation) where indentation from the left margin has specific legal significance. It was difficult to track all the cumulative effects produced using padding or margin properties on selectors. This property was added so they could be sure when they specify a value it was always relative to the left edge of the document (which I believe is the same way their printing systems probably specify these things).

This was a very special case and we do not normally stray from the W3C CSS recommendations unless there is a very compelling argument to do so.
Logged
Allison
Member

Posts: 5


« Reply #2 on: July 11, 2009, 01:22:14 PM »

Thank you so much!!  That is EXACTLY what I was hoping that property would do.  Many thanks for the clarification.
Logged
Pages: 1
Print
Jump to: