![]() |
![]() |
![]() |
GNOME UI Library Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Signals |
#include <libgnomeui/libgnomeui.h> enum GnomeIconListMode; struct GnomeIconList; GtkWidget * gnome_icon_list_new (guint icon_width
,GtkAdjustment *adj
,int flags
); void gnome_icon_list_construct (GnomeIconList *gil
,guint icon_width
,GtkAdjustment *adj
,int flags
); void gnome_icon_list_set_hadjustment (GnomeIconList *gil
,GtkAdjustment *hadj
); void gnome_icon_list_set_vadjustment (GnomeIconList *gil
,GtkAdjustment *vadj
); void gnome_icon_list_freeze (GnomeIconList *gil
); void gnome_icon_list_thaw (GnomeIconList *gil
); void gnome_icon_list_insert (GnomeIconList *gil
,int pos
,const char *icon_filename
,const char *text
); void gnome_icon_list_insert_pixbuf (GnomeIconList *gil
,int pos
,GdkPixbuf *im
,const char *icon_filename
,const char *text
); int gnome_icon_list_append (GnomeIconList *gil
,const char *icon_filename
,const char *text
); int gnome_icon_list_append_pixbuf (GnomeIconList *gil
,GdkPixbuf *im
,const char *icon_filename
,const char *text
); void gnome_icon_list_clear (GnomeIconList *gil
); void gnome_icon_list_remove (GnomeIconList *gil
,int pos
); guint gnome_icon_list_get_num_icons (GnomeIconList *gil
); GtkSelectionMode gnome_icon_list_get_selection_mode (GnomeIconList *gil
); void gnome_icon_list_set_selection_mode (GnomeIconList *gil
,GtkSelectionMode mode
); void gnome_icon_list_select_icon (GnomeIconList *gil
,int pos
); void gnome_icon_list_select_all (GnomeIconList *gil
); void gnome_icon_list_unselect_icon (GnomeIconList *gil
,int pos
); int gnome_icon_list_unselect_all (GnomeIconList *gil
); GList * gnome_icon_list_get_selection (GnomeIconList *gil
); void gnome_icon_list_focus_icon (GnomeIconList *gil
,gint idx
); void gnome_icon_list_set_icon_width (GnomeIconList *gil
,int w
); void gnome_icon_list_set_row_spacing (GnomeIconList *gil
,int pixels
); void gnome_icon_list_set_col_spacing (GnomeIconList *gil
,int pixels
); void gnome_icon_list_set_text_spacing (GnomeIconList *gil
,int pixels
); void gnome_icon_list_set_icon_border (GnomeIconList *gil
,int pixels
); void gnome_icon_list_set_separators (GnomeIconList *gil
,const char *sep
); gchar * gnome_icon_list_get_icon_filename (GnomeIconList *gil
,int idx
); int gnome_icon_list_find_icon_from_filename (GnomeIconList *gil
,const char *filename
); void gnome_icon_list_set_icon_data (GnomeIconList *gil
,int idx
,gpointer data
); void gnome_icon_list_set_icon_data_full (GnomeIconList *gil
,int pos
,gpointer data
,GDestroyNotify destroy
); int gnome_icon_list_find_icon_from_data (GnomeIconList *gil
,gpointer data
); gpointer gnome_icon_list_get_icon_data (GnomeIconList *gil
,int pos
); void gnome_icon_list_moveto (GnomeIconList *gil
,int pos
,double yalign
); GtkVisibility gnome_icon_list_icon_is_visible (GnomeIconList *gil
,int pos
); int gnome_icon_list_get_icon_at (GnomeIconList *gil
,int x
,int y
); int gnome_icon_list_get_items_per_line (GnomeIconList *gil
); GnomeIconTextItem * gnome_icon_list_get_icon_text_item (GnomeIconList *gil
,int idx
); GnomeCanvasPixbuf * gnome_icon_list_get_icon_pixbuf_item (GnomeIconList *gil
,int idx
);
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkContainer +----GtkLayout +----GnomeCanvas +----GnomeIconList
"focus-icon" :Run First
"move-cursor" :Action
"select-icon" :Run First
"text-changed" :Run Last
"toggle-cursor-selection" :Action
"unselect-icon" :Run First
typedef enum { GNOME_ICON_LIST_ICONS, GNOME_ICON_LIST_TEXT_BELOW, GNOME_ICON_LIST_TEXT_RIGHT } GnomeIconListMode;
GnomeIconListMode
is deprecated and should not be used in newly-written code.
struct GnomeIconList;
GnomeIconList
is deprecated and should not be used in newly-written code.
GtkWidget * gnome_icon_list_new (guint icon_width
,GtkAdjustment *adj
,int flags
);
gnome_icon_list_new
is deprecated and should not be used in newly-written code.
void gnome_icon_list_construct (GnomeIconList *gil
,guint icon_width
,GtkAdjustment *adj
,int flags
);
gnome_icon_list_construct
is deprecated and should not be used in newly-written code.
Constructor for the icon list, to be used by derived classes.
|
An icon list. |
|
Width for the icon columns. |
|
A combination of GNOME_ICON_LIST_IS_EDITABLE and GNOME_ICON_LIST_STATIC_TEXT . |
void gnome_icon_list_set_hadjustment (GnomeIconList *gil
,GtkAdjustment *hadj
);
gnome_icon_list_set_hadjustment
is deprecated and should not be used in newly-written code.
Sets the adjustment to be used for horizontal scrolling. This is normally not required, as the icon list can be simply inserted in a &GtkScrolledWindow and scrolling will be handled automatically.
|
An icon list. |
|
Adjustment to be used for horizontal scrolling. |
void gnome_icon_list_set_vadjustment (GnomeIconList *gil
,GtkAdjustment *vadj
);
gnome_icon_list_set_vadjustment
is deprecated and should not be used in newly-written code.
Sets the adjustment to be used for vertical scrolling. This is normally not required, as the icon list can be simply inserted in a &GtkScrolledWindow and scrolling will be handled automatically.
|
An icon list. |
|
Adjustment to be used for horizontal scrolling. |
void gnome_icon_list_freeze (GnomeIconList *gil
);
gnome_icon_list_freeze
is deprecated and should not be used in newly-written code.
Freezes an icon list so that any changes made to it will not be
reflected on the screen until it is thawed with gnome_icon_list_thaw()
.
It is recommended to freeze the icon list before inserting or deleting
many icons, for example, so that the layout process will only be executed
once, when the icon list is finally thawed.
You can call this function multiple times, but it must be balanced with the
same number of calls to gnome_icon_list_thaw()
before the changes will take
effect.
|
An icon list. |
void gnome_icon_list_thaw (GnomeIconList *gil
);
gnome_icon_list_thaw
is deprecated and should not be used in newly-written code.
Thaws the icon list and performs any pending layout operations. This
is to be used in conjunction with gnome_icon_list_freeze()
.
|
An icon list. |
void gnome_icon_list_insert (GnomeIconList *gil
,int pos
,const char *icon_filename
,const char *text
);
gnome_icon_list_insert
is deprecated and should not be used in newly-written code.
Inserts an icon in the specified icon list. The icon's image is loaded
from the specified file, and it is inserted at the pos
index.
|
An icon list. |
|
Position at which the new icon should be inserted. |
|
Name of the file that holds the icon's image. |
|
Text to be used for the icon's caption. |
void gnome_icon_list_insert_pixbuf (GnomeIconList *gil
,int pos
,GdkPixbuf *im
,const char *icon_filename
,const char *text
);
gnome_icon_list_insert_pixbuf
is deprecated and should not be used in newly-written code.
Inserts an icon in the specified icon list. The icon is created from the
specified Imlib image, and it is inserted at the pos
index.
|
An icon list. |
|
Position at which the new icon should be inserted. |
|
Pixbuf image with the icon image. |
|
Filename of the image file. |
|
Text to be used for the icon's caption. |
int gnome_icon_list_append (GnomeIconList *gil
,const char *icon_filename
,const char *text
);
gnome_icon_list_append
is deprecated and should not be used in newly-written code.
Appends an icon to the specified icon list. The icon's image is loaded from
the specified file, and it is inserted at the pos
index.
|
An icon list. |
|
Name of the file that holds the icon's image. |
|
Text to be used for the icon's caption. |
int gnome_icon_list_append_pixbuf (GnomeIconList *gil
,GdkPixbuf *im
,const char *icon_filename
,const char *text
);
gnome_icon_list_append_pixbuf
is deprecated and should not be used in newly-written code.
Appends an icon to the specified icon list. The icon is created from the specified Imlib image.
|
An icon list. |
|
Pixbuf image with the icon image. |
|
Filename of the image file. |
|
Text to be used for the icon's caption. |
void gnome_icon_list_clear (GnomeIconList *gil
);
gnome_icon_list_clear
is deprecated and should not be used in newly-written code.
Clears the contents for the icon list by removing all the icons. If destroy handlers were specified for any of the icons, they will be called with the appropriate data.
|
An icon list. |
void gnome_icon_list_remove (GnomeIconList *gil
,int pos
);
gnome_icon_list_remove
is deprecated and should not be used in newly-written code.
Removes the icon at index position pos
. If a destroy handler was specified
for that icon, it will be called with the appropriate data.
|
An icon list. |
|
Index of the icon that should be removed. |
guint gnome_icon_list_get_num_icons (GnomeIconList *gil
);
gnome_icon_list_get_num_icons
is deprecated and should not be used in newly-written code.
|
An icon list. |
Returns : |
The number of icons in the icon list. |
GtkSelectionMode gnome_icon_list_get_selection_mode (GnomeIconList *gil
);
gnome_icon_list_get_selection_mode
is deprecated and should not be used in newly-written code.
|
An icon list. |
Returns : |
The current selection mode for an icon list. |
void gnome_icon_list_set_selection_mode (GnomeIconList *gil
,GtkSelectionMode mode
);
gnome_icon_list_set_selection_mode
is deprecated and should not be used in newly-written code.
Sets the selection mode for an icon list. The GTK_SELECTION_MULTIPLE
and
GTK_SELECTION_EXTENDED
modes are considered equivalent.
|
An icon list. |
|
New selection mode. |
void gnome_icon_list_select_icon (GnomeIconList *gil
,int pos
);
gnome_icon_list_select_icon
is deprecated and should not be used in newly-written code.
Selects the icon at the index specified by pos
.
|
An icon list. |
|
Index of the icon to be selected. |
void gnome_icon_list_select_all (GnomeIconList *gil
);
gnome_icon_list_select_all
is deprecated and should not be used in newly-written code.
|
An icon list. |
void gnome_icon_list_unselect_icon (GnomeIconList *gil
,int pos
);
gnome_icon_list_unselect_icon
is deprecated and should not be used in newly-written code.
Unselects the icon at the index specified by pos
.
|
An icon list. |
|
Index of the icon to be unselected. |
int gnome_icon_list_unselect_all (GnomeIconList *gil
);
gnome_icon_list_unselect_all
is deprecated and should not be used in newly-written code.
|
An icon list. |
Returns : |
The number of icons in the icon list |
GList * gnome_icon_list_get_selection (GnomeIconList *gil
);
gnome_icon_list_get_selection
is deprecated and should not be used in newly-written code.
|
An icon list. |
Returns : |
A list of integers with the indices of the currently selected icons. |
void gnome_icon_list_focus_icon (GnomeIconList *gil
,gint idx
);
gnome_icon_list_focus_icon
is deprecated and should not be used in newly-written code.
void gnome_icon_list_set_icon_width (GnomeIconList *gil
,int w
);
gnome_icon_list_set_icon_width
is deprecated and should not be used in newly-written code.
Sets the amount of horizontal space allocated to the icons, i.e. the column width of the icon list.
|
An icon list. |
|
New width for the icon columns. |
void gnome_icon_list_set_row_spacing (GnomeIconList *gil
,int pixels
);
gnome_icon_list_set_row_spacing
is deprecated and should not be used in newly-written code.
Sets the spacing to be used between rows of icons.
|
An icon list. |
|
Number of pixels for inter-row spacing. |
void gnome_icon_list_set_col_spacing (GnomeIconList *gil
,int pixels
);
gnome_icon_list_set_col_spacing
is deprecated and should not be used in newly-written code.
Sets the spacing to be used between columns of icons.
|
An icon list. |
|
Number of pixels for inter-column spacing. |
void gnome_icon_list_set_text_spacing (GnomeIconList *gil
,int pixels
);
gnome_icon_list_set_text_spacing
is deprecated and should not be used in newly-written code.
Sets the spacing to be used between an icon's image and its text caption.
|
An icon list. |
|
Number of pixels between an icon's image and its caption. |
void gnome_icon_list_set_icon_border (GnomeIconList *gil
,int pixels
);
gnome_icon_list_set_icon_border
is deprecated and should not be used in newly-written code.
Sets the width of the border to be displayed around an icon's image. This is currently not implemented.
|
An icon list. |
|
Number of border pixels to be used around an icon's image. |
void gnome_icon_list_set_separators (GnomeIconList *gil
,const char *sep
);
gnome_icon_list_set_separators
is deprecated and should not be used in newly-written code.
Sets the characters that can be used as word separators when doing word-wrapping in the icon text captions.
|
An icon list. |
|
String with characters to be used as word separators. |
gchar * gnome_icon_list_get_icon_filename (GnomeIconList *gil
,int idx
);
gnome_icon_list_get_icon_filename
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
Index of an icon . |
Returns : |
The filename of the icon with index idx . |
int gnome_icon_list_find_icon_from_filename (GnomeIconList *gil
,const char *filename
);
gnome_icon_list_find_icon_from_filename
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
Filename of an icon. |
Returns : |
The index of the icon whose filename is filename or -1 if
there is no icon with this filename. |
void gnome_icon_list_set_icon_data (GnomeIconList *gil
,int idx
,gpointer data
);
gnome_icon_list_set_icon_data
is deprecated and should not be used in newly-written code.
void gnome_icon_list_set_icon_data_full (GnomeIconList *gil
,int pos
,gpointer data
,GDestroyNotify destroy
);
gnome_icon_list_set_icon_data_full
is deprecated and should not be used in newly-written code.
Associates the data
pointer to the icon at the index specified by pos
. The
destroy
argument points to a function that will be called when the icon is
destroyed, or NULL if no function is to be called when this happens.
|
An icon list. |
|
Index of an icon. |
|
User data to set on the icon. |
|
Destroy notification handler for the icon. |
int gnome_icon_list_find_icon_from_data (GnomeIconList *gil
,gpointer data
);
gnome_icon_list_find_icon_from_data
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
Data pointer associated to an icon. |
Returns : |
The index of the icon whose user data has been set to data ,
or -1 if no icon has this data associated to it. |
gpointer gnome_icon_list_get_icon_data (GnomeIconList *gil
,int pos
);
gnome_icon_list_get_icon_data
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
Index of an icon. |
Returns : |
The user data pointer associated to the icon at the index specified
by pos . |
void gnome_icon_list_moveto (GnomeIconList *gil
,int pos
,double yalign
);
gnome_icon_list_moveto
is deprecated and should not be used in newly-written code.
Makes the icon whose index is pos
be visible on the screen. The icon list
gets scrolled so that the icon is visible. An alignment of 0.0 represents
the top of the visible part of the icon list, and 1.0 represents the bottom.
An icon can be centered on the icon list.
|
An icon list. |
|
Index of an icon. |
|
Vertical alignment of the icon. |
GtkVisibility gnome_icon_list_icon_is_visible (GnomeIconList *gil
,int pos
);
gnome_icon_list_icon_is_visible
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
Index of an icon. |
Returns : |
Whether the icon at the index specified by pos is visible. This
will be GTK_VISIBILITY_NONE if the icon is not visible at all,
GTK_VISIBILITY_PARTIAL if the icon is at least partially shown, and
GTK_VISIBILITY_FULL if the icon is fully visible. |
int gnome_icon_list_get_icon_at (GnomeIconList *gil
,int x
,int y
);
gnome_icon_list_get_icon_at
is deprecated and should not be used in newly-written code.
|
An icon list. |
|
X position in the icon list window. |
|
Y position in the icon list window. |
Returns : |
The index of the icon that is under the specified coordinates, which are relative to the icon list's window. If there is no icon in that position, -1 is returned. |
int gnome_icon_list_get_items_per_line (GnomeIconList *gil
);
gnome_icon_list_get_items_per_line
is deprecated and should not be used in newly-written code.
|
An icon list. |
Returns : |
The number of icons that fit in a line or row. |
GnomeIconTextItem * gnome_icon_list_get_icon_text_item (GnomeIconList *gil
,int idx
);
gnome_icon_list_get_icon_text_item
is deprecated and should not be used in newly-written code.
GnomeCanvasPixbuf * gnome_icon_list_get_icon_pixbuf_item (GnomeIconList *gil
,int idx
);
gnome_icon_list_get_icon_pixbuf_item
is deprecated and should not be used in newly-written code.
"focus-icon"
signalvoid user_function (GnomeIconList *iconlist,
gint arg1,
gpointer user_data) : Run First
|
the object which received the signal. |
|
user data set when the signal handler was connected. |
"move-cursor"
signalvoid user_function (GnomeIconList *iconlist,
GtkDirectionType arg1,
gboolean arg2,
gpointer user_data) : Action
|
the object which received the signal. |
|
user data set when the signal handler was connected. |
"select-icon"
signalvoid user_function (GnomeIconList *iconlist,
gint arg1,
GdkEvent *arg2,
gpointer user_data) : Run First
|
the object which received the signal. |
|
user data set when the signal handler was connected. |
"text-changed"
signalgboolean user_function (GnomeIconList *iconlist,
gint arg1,
gchar *arg2,
gpointer user_data) : Run Last
|
the object which received the signal. |
|
user data set when the signal handler was connected. |
"toggle-cursor-selection"
signalvoid user_function (GnomeIconList *iconlist,
gpointer user_data) : Action
|
the object which received the signal. |
|
user data set when the signal handler was connected. |
"unselect-icon"
signalvoid user_function (GnomeIconList *iconlist,
gint arg1,
GdkEvent *arg2,
gpointer user_data) : Run First
|
the object which received the signal. |
|
user data set when the signal handler was connected. |