Revision history [back]

Oke,

Look here : Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" pre=true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" pre=true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = This seems the same.\n \
                       But it react differently.

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.

This fiddle shows this example.

More docs :
http://en.wikibooks.org/wiki/ZK/How-Tos/FrequentlyAskedQuestions#Howtospecifyline-breakinLabel.27sattribute

and here in the docs : http://books.zkoss.org/wiki/ZKComponentReference/EssentialComponents/Label#Pre.2CHyphen.2CMaxlengthand_Multiline

greetz chill.

Oke,

Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" pre=true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" pre=true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = This seems the same.\n \
                       But it react differently.

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.

This fiddle shows this example.

More docs :
http://en.wikibooks.org/wiki/ZK/How-Tos/FrequentlyAskedQuestions#Howtospecifyline-breakinLabel.27sattribute http://books.zkoss.org/wiki/ZKComponentReference/EssentialComponents/Label#Pre.2CHyphen.2CMaxlengthand_Multiline

greetz chill.

Oke,

Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" pre=true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = {
                        This seems the same.\n \
same.
                        But it react differently.
                       }

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.

This fiddle shows this example.

edit: corrected the prop file,added more doc and tested myself => working.

More docs :
Frequently Asked Questions : How to specify line break in Labelhttp://en.wikibooks.org/wiki/ZK/How-Tos/FrequentlyAskedQuestions#Howtospecifyline-breakinLabel.27sattribute Maxlength and Multiline http://books.zkoss.org/wiki/ZKComponentReference/EssentialComponents/Label#Pre.2CHyphen.2CMaxlengthand_MultilineThe Format of Properties Files

greetz chill.

Oke,

Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" pre=true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = {
                        This seems the same.
                        But it react differently.
                       }

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.

This fiddle shows this example.

edit: corrected the prop file,added more doc and tested myself => working.

More docs :
Frequently Asked Questions : How to specify line break in Label
Maxlength and Multiline
The Format of Properties Files

greetz chill.

Oke,

Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" pre=true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = {
                        This seems the same.
                        But it react differently.
                       }

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.

This fiddle shows this example.

edit: corrected the prop file,added more doc and tested myself => working.

More docs :
Frequently Asked Questions : How to specify line break in Label
Maxlength and Multiline
The Format of Properties Files

greetz chill.

Oke,

Lol third or fourth time I edit this answer(drafts weren't saved :s).

You make a mistake by your testing.

Wrong :

<label multiline="true" value="Burak\nASDASD"/>

Your value is set direct and never parsed again to explain it fast and simple.

Correct :

<label multiline="true" value="${labels.historybox.last7days}"/>

and prop file :

historybox.last7days = {
                        This seems the same.
                        But it react differently.
                       }

Explication prop file :

The \n says its a new line. The \ say's the reader to continue reading in the next line.
This has nothing to do with the text, just for the reader not to stop reading the prop.
see the last documentation link, format of the prop file.

This fiddle shows this example.

edit: corrected the prop file,added more doc and tested myself => working.

More docs :
Frequently Asked Questions : How to specify line break in Label
Maxlength and Multiline
The Format of Properties Files

greetz chill.

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More