Sumary
pacer occupies a fixed amount of space in a layout, specified by its width and height
attributes. If the width is not specified, but height specified, a block level HTML element is rendered,
thereby introducing a new line effect. If width is specified, then, irrespective of the specified
value of height, it may not get shorter than the applicable line-height, in user agents that strictly support
standards mode HTML.
Code samples
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:tr="http://myfaces.apache.org/trinidad"
template="/pages/componentDemo.xhtml">
<ui:define name="demoContent">
<tr:outputText value="Above spacer"/>
<tr:spacer height="20px"/>
<tr:outputText value="Below spacer"/>
</ui:define>
</ui:composition>