Display Items<A NAME=32> </A>

Next: Advantages of Display Up: Tabular Listbox and Previous: tixTList - The

## Display Items

Before we rush to discuss how to create the items inside a TixTList widget, let's first spend some time on a very important topic about the Tix library: the repationship between the display items and their host widgets.

We can better define the terms by taking a quick preview of the TixHList widget, which will be covered in details in the next chapter. Let's compare the items displayed on the two widgets in figure 3-3. If we take a close look at the item that shows the `usr` directory in the TixTList widget on the left versus the TixHList widget on the right, we can see that this item appears exactly the same on both widgets.

If fact, all the items in these two widgets are of the same type: they all display an image next to a textual name. The only difference between these two widgets is how these items are arranged. The TixTList widget arranges the items in rows and columns, while the TixHList widget arranges the items in a hierachical format.

With this observation in mind, we can see a separation of tasks berween the widgets and the items they display. We call the TixHList and TixTList widgets in figure 3-3 host widgets: their task is to arrange the items according to their particular rules. However, they don't really care what these items display; they just treat the items as rectangle boxes. In contrast, these items, which are called display items in Tix terminology, controls the visual information they display, such as the images, text strings, colors, fonts, etc. However, they don't really care where on the host widget they will appear.

- Advantages of Display Items
- Display Items and Display Styles