Lines Matching defs:item

31  * This is a List widget.  It allows the user to select an item in a list and
390 * Description: Converts Xcoord to item number of item containing that
394 * Returns: the item number.
398 CvtToItem(w, xloc, yloc, item)
401 int *item;
432 *item = one + another;
433 if (*item >= lw->list.nitems) return(OUT_OF_RANGE);
438 * Description: Find the corners of the rectangle in item space.
462 * Description: returns TRUE if the item passed is in the given rectangle.
464 * ul, lr - corners of the rectangle in item space.
465 * item - item to check.
466 * Returns: TRUE if the item passed is in the given rectangle.
470 ItemInRectangle(w, ul, lr, item)
472 int ul, lr, item;
478 if (item < ul || item > lr)
485 mod_item = item % things;
494 * Paints the color of the background for the given item. It performs
498 * x, y - ul corner of the area item occupies.
544 * maximum of all item lengths). If the user does specify, say, 80 pixel
567 * paints the name of the item in the appropriate location.
569 * item - the item to draw.
574 PaintItemName(w, item)
576 int item;
587 x = lw->list.col_width * (item / lw->list.nrows)
589 y = lw->list.row_height * (item % lw->list.nrows)
593 x = lw->list.col_width * (item % lw->list.ncols)
595 y = lw->list.row_height * (item / lw->list.ncols)
604 if (item == lw->list.is_highlighted) {
605 if (item == lw->list.highlight) {
619 if (item == lw->list.highlight) {
622 lw->list.is_highlighted = item;
640 str = lw->list.list[item]; /* draw it */
669 int item; /* an item to work with. */
681 for (item = ul_item; (item <= lr_item && item < lw->list.nitems) ; item++)
682 if (ItemInRectangle(w, ul_item, lr_item, item))
683 PaintItemName(w, item);
759 * lays out the item in the list.
860 * then the name of the item is also put in CUT_BUFFER0. */
871 int item, item_len;
875 * Find item and if out of range then unhighlight and return.
877 * If the current item is unhighlighted then the user has aborted the
881 if ( ((CvtToItem(w, event->xbutton.x, event->xbutton.y, &item))
882 == OUT_OF_RANGE) || (lw->list.highlight != item) ) {
887 item_len = strlen(lw->list.list[item]);
890 XStoreBytes(XtDisplay(w), lw->list.list[item], item_len);
896 ret_value.string = lw->list.list[item];
897 ret_value.list_index = item;
931 int item;
934 if ( (CvtToItem(w, event->xbutton.x, event->xbutton.y, &item))
936 XawListUnhighlight(w); /* Unhighlight current item. */
937 else if ( lw->list.is_highlighted != item ) /* If this item is not */
938 XawListHighlight(w, item); /* highlighted then do it. */
1152 * Description: Highlights the given item.
1154 * item - the item to hightlight.
1160 XawListHighlight(Widget w, int item)
1162 XawListHighlight(w, item)
1164 int item;
1170 lw->list.highlight = item;
1173 PaintItemName(w, item); /* HIGHLIGHT this one. */