Texts"

From Documentation
(Created page with '{{ZUMLReferencePageHeader}} Depending on component's implementation, the text nested in a XML element could be interpreted as the value of a component's particular property. For…')
 
m
Line 1: Line 1:
 
{{ZUMLReferencePageHeader}}
 
{{ZUMLReferencePageHeader}}
  
Depending on component's implementation, the text nested in a XML element could be interpreted as the value of a component's particular property. For example, <javadoc>org.zkoss.zul.Html</javadoc> is one of this kind of components, and
+
In general, a XML text is interpreted as a label component. For example,
 +
 
 +
<source lang="xml">
 +
<window>
 +
  Begin ${foo.whatever}
 +
</window>
 +
</source>
 +
 
 +
is equivalent to
 +
 
 +
<source lang="xml">
 +
<window>
 +
  <label value="Begin ${foo.whatever}"/>
 +
</window>
 +
</source>
 +
 
 +
However, a component can be designed to accept the nested text as the value of a component property. In other words, a component designer could decide to make ZK Loader interpret the nest text as the value of a predefined property. For example, <javadoc>org.zkoss.zul.Html</javadoc> is one of this kind of components, and
  
 
<source lang="xml">
 
<source lang="xml">
Line 13: Line 29:
 
</source>
 
</source>
  
It is designed to make it easy to specify multiple-line value, so it is usually used by particular components that requires the multi-line value. Here is a list of components that interprets the XML text as a property's value.
+
It is designed to make it easy to specify multiple-line value, so it is usually used by particular components that requires the multi-line value.
 +
 
 +
Here is a list of components that interprets the XML text as a property's value.
  
 
{| border='1px'
 
{| border='1px'

Revision as of 06:52, 5 November 2010

In general, a XML text is interpreted as a label component. For example,

<window>
  Begin ${foo.whatever}
</window>

is equivalent to

<window>
  <label value="Begin ${foo.whatever}"/>
</window>

However, a component can be designed to accept the nested text as the value of a component property. In other words, a component designer could decide to make ZK Loader interpret the nest text as the value of a predefined property. For example, Html is one of this kind of components, and

<html>Begin ${foo.whatever}</html>

is equivalent to

<html content="Begin ${foo.whatever}"/>

It is designed to make it easy to specify multiple-line value, so it is usually used by particular components that requires the multi-line value.

Here is a list of components that interprets the XML text as a property's value.

Component Name Property Name Method
a label A.setLabel(String)
button label Button.setLabel(String)
comboitem content Comboitem.setContent(String)
html content Html.setContent(String)
label value Label.setValue(String)
script content Script.setContent(String)
style content Style.setContent(String)

Version History

Last Update : 2010/11/5

Version Date Content
     



Last Update : 2010/11/05

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.