Listbox Renderer"

From Documentation
m
Line 3: Line 3:
 
Here we describe how to implement a custom renderer for a listbox (<javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc>). For the concept about component, model and renderer, please refer to [[ZK_Developer's_Reference/MVC/Model/List_Model#Model-driven_Display|the Model-driven Display section]].
 
Here we describe how to implement a custom renderer for a listbox (<javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc>). For the concept about component, model and renderer, please refer to [[ZK_Developer's_Reference/MVC/Model/List_Model#Model-driven_Display|the Model-driven Display section]].
  
When a listbox (<javadoc>org.zkoss.zul.Listbox<javadoc>) is assigned with a model, a default renderer is assigned too. The default renderer will assume the listbox is a single column, and it converted the element into a string. If you want to display multiple columns or retrieve a particular field of the element, you have to implement <javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc> to handle the rendering.
+
When a listbox (<javadoc>org.zkoss.zul.Listbox</javadoc>) is assigned with a model, a default renderer is assigned too. The default renderer will assume the listbox is a single column, and it converted the element into a string. If you want to display multiple columns or retrieve a particular field of the element, you have to implement <javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc> to handle the rendering.
  
 
=Version History=
 
=Version History=

Revision as of 06:14, 31 December 2010


Listbox Renderer


Here we describe how to implement a custom renderer for a listbox (ListitemRenderer). For the concept about component, model and renderer, please refer to the Model-driven Display section.

When a listbox (Listbox) is assigned with a model, a default renderer is assigned too. The default renderer will assume the listbox is a single column, and it converted the element into a string. If you want to display multiple columns or retrieve a particular field of the element, you have to implement ListitemRenderer to handle the rendering.

Version History

Last Update : 2010/12/31


Version Date Content
     



Last Update : 2010/12/31

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