Control *new_image_label(Window *w, Rect r, Image *img, int align); Control *add_image_label(Control *c, Rect r, Image *img, int align); void set_control_image(Control *c, Image *img); Image * get_control_image(Control *c);
The new_image_label function creates a control, which has the specified Image drawn within it. The control will appear on the specified window, at the rectangle given in window co-ordinates. The image is not copied by this function, so the image should not be released from memory or modified while it is being used by the control.
The image label control does not respond to user clicks or key events. It merely draws the specified image within its boundaries. The alignment of the image within the rectangle follows the alignment flags described in the entry for labels, except that the image will be scaled to fit the rectangle if an alignment of ALIGN_JUSTIFY or VALIGN_JUSTIFY is given.
The add_image_label function works in the same way as new_image_label, except that it attaches the image label to a control rather than directly to a window.
To change the image used by a control, call set_control_image, and to retrieve a pointer to the currently displayed image, use get_control_image.