You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by goratz <go...@gmail.com> on 2017/02/20 09:08:45 UTC
TLF: problem with \n and TextAlign Justify
Hi all,
I have some troubles when I try to Justify a paragraph that has a "\n".
I will put a example:
I put the paragraphElement.textAlign = "Justify";
Text => "This is the line 1 \n and this is the line 2."
*What I expect:*
Line Length: ___________________________
Line 1: This is the line 1
Line 2: and this is the line 2.
*What I get:*
Line Length: ___________________________
Line 1: This is the line 1
Line 2: and this is the line 2.
I dont understand why the TLF justify the line that has a "\n". Can I
disable this?
Thank you very much.
--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/TLF-problem-with-n-and-TextAlign-Justify-tp59676.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.
Re: TLF: problem with \n and TextAlign Justify
Posted by Harbs <ha...@gmail.com>.
That does not make a new paragraph, but it can work if the tab settings are such so it left justifies the text.
> On Feb 21, 2017, at 10:04 AM, goratz <go...@gmail.com> wrote:
>
> Thank you Harbs,
>
> I tested putting a \t\n and then Justifys as expected.
>
> Thank you very much for you help.
>
>
>
> --
> View this message in context: http://apache-flex-development.2333347.n4.nabble.com/TLF-problem-with-n-and-TextAlign-Justify-tp59676p59697.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.
Re: TLF: problem with \n and TextAlign Justify
Posted by goratz <go...@gmail.com>.
Thank you Harbs,
I tested putting a \t\n and then Justifys as expected.
Thank you very much for you help.
--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/TLF-problem-with-n-and-TextAlign-Justify-tp59676p59697.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.
Re: TLF: problem with \n and TextAlign Justify
Posted by Harbs <ha...@gmail.com>.
“\n" is interpreted as a line break (soft return) in the same paragraph, not a new paragraph.
You need a new ParagraphElement to get the behavior you want.
Harbs
> On Feb 20, 2017, at 11:08 AM, goratz <go...@gmail.com> wrote:
>
> Hi all,
>
> I have some troubles when I try to Justify a paragraph that has a "\n".
>
> I will put a example:
> I put the paragraphElement.textAlign = "Justify";
> Text => "This is the line 1 \n and this is the line 2."
>
> *What I expect:*
> Line Length: ___________________________
> Line 1: This is the line 1
> Line 2: and this is the line 2.
>
> *What I get:*
> Line Length: ___________________________
> Line 1: This is the line 1
> Line 2: and this is the line 2.
>
> I dont understand why the TLF justify the line that has a "\n". Can I
> disable this?
>
> Thank you very much.
>
>
>
> --
> View this message in context: http://apache-flex-development.2333347.n4.nabble.com/TLF-problem-with-n-and-TextAlign-Justify-tp59676.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.