Listbox Renderer"
From Documentation
m |
|||
Line 1: | Line 1: | ||
{{ZKDevelopersReferencePageHeader}} | {{ZKDevelopersReferencePageHeader}} | ||
− | Here we describe how to implement a custom renderer for a listbox (<javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc>). For the | + | Here we describe how to implement a custom renderer for a listbox (<javadoc type="interface">org.zkoss.zul.ListitemRenderer</javadoc>). For the concepts 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. |
Revision as of 10:18, 22 July 2011
Here we describe how to implement a custom renderer for a listbox (ListitemRenderer). For the concepts 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
Version | Date | Content |
---|---|---|