Description
The GNOME icon list widget can hold a number of icons with captions.
You can make the icon captions in the icon list be editable (this is
configured at the widget creation time).
You can control the type of selection mode you desire by using
the gnome_icon_list_set_selection_mode() function.
Details
GNOME_ICON_LIST_IS_EDITABLE
#define GNOME_ICON_LIST_IS_EDITABLE 1 |
GNOME_ICON_LIST_STATIC_TEXT
#define GNOME_ICON_LIST_STATIC_TEXT 2 |
enum GnomeIconListMode
typedef enum {
GNOME_ICON_LIST_ICONS,
GNOME_ICON_LIST_TEXT_BELOW,
GNOME_ICON_LIST_TEXT_RIGHT
} GnomeIconListMode; |
gnome_icon_list_new ()
GtkWidget* gnome_icon_list_new (guint icon_width,
GtkAdjustment *adj,
gboolean is_editable); |
gnome_icon_list_new_flags ()
GtkWidget* gnome_icon_list_new_flags (guint icon_width,
GtkAdjustment *adj,
int flags); |
Creates a new GnomeIconList widget. Icons will be assumed to be at
most ICON_WIDTH pixels of width. Any text displayed for those icons
will be wrapped at this width as well.
The adjustment is used to pass an existing adjustment to be used to
control the icon list display. If ADJ is NULL, then a new adjustment
will be created.
Applications can use this adjustment stored inside the
GnomeIconList structure to construct scrollbars if they so desire.
if flags has the GNOME_ICON_LIST_IS_EDITABLE flag set, then the
text on the icons will be permited to be edited. If the name
changes the "text_changed" signal will be emitted.
if flags has the GNOME_ICON_LIST_STATIC_TEXT flags set, then the
text
Please note that the GnomeIconList starts life in Frozen state. You are
supposed to fall gnome_icon_list_thaw on it as soon as possible.
gnome_icon_list_construct ()
void gnome_icon_list_construct (GnomeIconList *gil,
guint icon_width,
GtkAdjustment *adj,
int flags); |
gnome_icon_list_set_hadjustment ()
void gnome_icon_list_set_hadjustment (GnomeIconList *gil,
GtkAdjustment *hadj); |
gnome_icon_list_set_vadjustment ()
void gnome_icon_list_set_vadjustment (GnomeIconList *gil,
GtkAdjustment *vadj); |
gnome_icon_list_freeze ()
Freezes any changes made to the GnomeIconList. This is useful
to avoid expensive computations to be performed if you are making
many changes to an existing icon list. For example, call this routine
before inserting a bunch of icons.
You can call this routine multiple times, you will have to call
gnome_icon_list_thaw an equivalent number of times to make any
changes done to the icon list to take place.
gnome_icon_list_thaw ()
If the freeze count reaches zero it will relayout any pending
layout changes that might have been delayed due to the icon list
be frozen by a call to gnome_icon_list_freeze.
gnome_icon_list_insert ()
void gnome_icon_list_insert (GnomeIconList *gil,
int pos,
const char *icon_filename,
const char *text); |
Inserts the at the POS index in the GIL icon list an icon which is
contained on the file icon_filename and with the TEXT string as its
label.
gnome_icon_list_insert_imlib ()
void gnome_icon_list_insert_imlib (GnomeIconList *gil,
int pos,
GdkImlibImage *im,
const char *text); |
Inserts the at the POS index in the GIL icon list an icon which is
on the IM imlib imageand with the TEXT string as its label.
gnome_icon_list_append ()
int gnome_icon_list_append (GnomeIconList *gil,
const char *icon_filename,
const char *text); |
Appends to the GIL icon list an icon which is contained on the file
icon_filename and with the TEXT string as its label.
gnome_icon_list_append_imlib ()
int gnome_icon_list_append_imlib (GnomeIconList *gil,
GdkImlibImage *im,
char *text); |
gnome_icon_list_clear ()
Clears the contents for the icon list.
gnome_icon_list_remove ()
Removes the icon at index position POS.
gnome_icon_list_set_selection_mode ()
void gnome_icon_list_set_selection_mode
(GnomeIconList *gil,
GtkSelectionMode mode); |
Sets the GnomeIconList selection mode, it can be any of the
modes defined in the GtkSelectionMode enumeration.
gnome_icon_list_select_icon ()
Selects the icon at index position POS.
gnome_icon_list_unselect_icon ()
void gnome_icon_list_unselect_icon (GnomeIconList *gil,
int pos); |
Removes the selection from the icon at the index position POS
gnome_icon_list_unselect_all ()
int gnome_icon_list_unselect_all (GnomeIconList *gil,
GdkEvent *event,
void *keep); |
Unselects all of the icons in the GIL icon list. EVENT is the event
that triggered the unselect action (or NULL if the event is not available).
The keep parameter is only used internally in the Icon LIst code, it can be NULL.
gnome_icon_list_set_icon_width ()
Use this routine to change the icon width
gnome_icon_list_set_row_spacing ()
void gnome_icon_list_set_row_spacing (GnomeIconList *gil,
int pixels); |
Sets the number of pixels for the inter-row spacing.
gnome_icon_list_set_col_spacing ()
void gnome_icon_list_set_col_spacing (GnomeIconList *gil,
int pixels); |
Sets the number of pixels for the inter-column spacing.
gnome_icon_list_set_text_spacing ()
void gnome_icon_list_set_text_spacing
(GnomeIconList *gil,
int pixels); |
Sets the number of pixels for the text spacing.
gnome_icon_list_set_icon_border ()
void gnome_icon_list_set_icon_border (GnomeIconList *gil,
int pixels); |
Sets the number of pixels for the icon borders
gnome_icon_list_set_separators ()
void gnome_icon_list_set_separators (GnomeIconList *gil,
const char *sep); |
Sets the separator characters used to optimally split this
string. See gnome-icon-text.h
gnome_icon_list_set_icon_data ()
void gnome_icon_list_set_icon_data (GnomeIconList *gil,
int pos,
gpointer data); |
gnome_icon_list_set_icon_data_full ()
void gnome_icon_list_set_icon_data_full
(GnomeIconList *gil,
int pos,
gpointer data,
GtkDestroyNotify destroy); |
gnome_icon_list_find_icon_from_data ()
int gnome_icon_list_find_icon_from_data
(GnomeIconList *gil,
gpointer data); |
gnome_icon_list_get_icon_data ()
gpointer gnome_icon_list_get_icon_data (GnomeIconList *gil,
int pos); |
gnome_icon_list_moveto ()
void gnome_icon_list_moveto (GnomeIconList *gil,
int pos,
double yalign); |
Makes the icon whose index is POS visible on the screen, the
YALIGN double controls the alignment of the icon inside the GnomeIconList
0.0 represents the top, while 1.0 represents the bottom.
gnome_icon_list_icon_is_visible ()
GtkVisibility gnome_icon_list_icon_is_visible
(GnomeIconList *gil,
int pos); |
gnome_icon_list_get_icon_at ()
int gnome_icon_list_get_icon_at (GnomeIconList *gil,
int x,
int y); |
gnome_icon_list_get_items_per_line ()