Magazine
 
JSF Tags: Tomahawk Tags

<title>t:popup example</title>
<style type=”text/css”>
<!—
.popClass{
background-color:#F1F1F1;
}
—>
</style>
</head>
<body >
<h:form>
<t:popup styleClass=”popClass”
closePopupOnExitingElement=”true”
closePopupOnExitingPopup=”true”
displayAtDistanceX=”0"
displayAtDistanceY=”0">
<h:outputText value=”JSF tutorials and
examples.” style=”font-weight:bold;”/>
<f:facet name=”popup”>
<h:panelGrid columns=”1" >
<h:commandLink value=”http://
roseindia.net/jsf” />
<h:commandLink value=”http://
myfaces.apache.org” />
</h:panelGrid>
</f:facet>
</t:popup>
</h:form>
</body>
</html>
</f:view>

Rendered Output :



6. Tomahawk dataScroller tag :


The data scroller component of tomahawk is one of the very useful component. This component can take the reference of the

  UIData component like dataTable, dataList in its “for” attribute. dataScroller tag renders a component that provides the facility to navigate through the data by scrolling.

Code Description:

In the code below, the data scroller component for a data table has been created that helps to navigate from one set of data to the other by clicking various navigation links. There are three types of links to move one by one, fast forward and move to the last directly. In this example, faststep attribute has been set to the value 2 so fast forward link will take you two page ahead directly. paginatorMaxPages attribute sets the number of pages to be shown in the component to navigate directly clicking on them.

<%@ taglib uri=”http://java.sun.com/jsf/
html” prefix=”h”%>
<%@ taglib uri=”http://java.sun.com/jsf/
core” prefix=”f”%>
<%@ taglib uri=”http://
myfaces.apache.org/tomahawk”
prefix=”t”%>
<html>
<head>
<meta http-equiv=”Content-Type”
content=”text/html; charset=iso-8859-1">
<title>t:dataScroller example</title>
<style type=”text/css”>
<!—
body{
margin-top:30;
}
.TableRow1 {
background-color: #D0E6E0;
}
.TableRow2 {
background-color: #E8F7F1;
}
.TableColumn {
text-align: center
}
.TableClass {

Sept 2007 | Java Jazz Up | 19
 
previous
index
next
 
Pages: 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, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53 , 54, 55, 56, 57,

58
, 59, 60, 61, 62, 63 , 64, 65 , 66 , 67 , 68 , 69 , 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,   Download PDF