Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 8

PtGenListAddItems()

Add items to a list

Synopsis:

void PtGenListAddItems( PtWidget_t *list, 
                        PtGenListItem_t *items,
                        PtGenListItem_t *after );

Description:

This function adds items to the PtGenList widget pointed to by list. The arguments are:

items
A pointer to a list of PtGenListItem_t structures linked with the next field (the prev field is ignored).
after
If after is NULL, add the items at the beginning of the list. If after isn't NULL, it must point to an item in the widget and items is added after that item.

In all selection modes except Pt_SELECTION_MODE_RANGE, if there's no current item in the widget and some of the added items have the Pt_LIST_ITEM_CURRENT flag set, the first of them becomes the current item (see Current item in the description of PtGenList). In all other items, the flag is cleared.

If no item is currently selected and the mode is set to Pt_SELECTION_MODE_SINGLE, the first of the added items having the Pt_LIST_ITEM_SELECTED flag set becomes the selected item. This flag on all other items is cleared.

In Pt_SELECTION_MODE_MULTIPLE mode and Pt_SELECTION_MODE_NONE mode, all items with the Pt_LIST_ITEM_SELECTED flag are selected.

In Pt_SELECTION_MODE_RANGE mode, the behavior depends on whether there's a selected range in the widget and how the after item is located relative to the selected range. In particular, if you remove a range of items and then reinsert them in the same place, the selected range is restored. However, the “direction” of the range may be reversed.

If no items are selected in Pt_SELECTION_MODE_RANGE mode but a range of added items has the Pt_LIST_ITEM_SELECTED flag set, these items become the selected range. The first or last item in this range becomes the current item, depending on the setting of the Pt_LIST_ITEM_CURRENT flag of the first selected item.

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

PtGenList, PtGenListItem_t


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 146

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/widget_ref/pt/ptgenlistadditems.html on line 146