Skip to main content
Participant
September 6, 2010
Answered

How can I indent a whole paragraph?

  • September 6, 2010
  • 1 reply
  • 592 views

Hello Forum

I'm taking a first stab at TLF and TextFlow markup. All works fine so far, but I'm unable to create a paragraph with an offset to the left. I was looking at the "Text Layout Editor" Demo (http://labs.adobe.com/technologies/textlayout/demos/), and the Left Margin property is exactly what I'm after. It works in the Demo, but if I use leftMargin="20" in my Markup, it either doesn't work, or I get an Error during compile time, saying: Cannot resolve attribute 'marginLeft' for component type flashx.textLayout.elements.ParagraphElement.

Can somebody give me a hint how I can achieve this? Did I miss something obvious?

This topic has been closed for replies.
Correct answer stefan_van_dinther

I think the demo has been made with an older version of the tlf... marginLeft has been changed to paragraphStartIndent in the new tlf...

(to be more precise: marginLeft was part of the ParagraphFormat class which does not exist anymore, and paragraphStartIndent is now part of the TextLayoutFormat class)

1 reply

Participant
September 6, 2010

It seems like the paragraphStartIndent property is what I was looking for.

I'm still leaving this question as unanswered, maybe somebody can give me a clue why there's a discrepancy between the editor-demo and the implementation in Flex4?

stefan_van_dintherCorrect answer
Inspiring
September 7, 2010

I think the demo has been made with an older version of the tlf... marginLeft has been changed to paragraphStartIndent in the new tlf...

(to be more precise: marginLeft was part of the ParagraphFormat class which does not exist anymore, and paragraphStartIndent is now part of the TextLayoutFormat class)