2002-04-24 Matthias Clasen * gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml: Updates. (#79001) 2002-04-23 Matthias Clasen * gtk/tmpl/gtksocket.sgml: Add link to XEmbed draft. (#67818) * gtk/tmpl/gtkdrawingarea.sgml: Fix a typo. * gtk/text_widget.sgml: Complete the fix for #79080. 2002-04-22 Matthias Clasen * gtk/tree_widget.sgml: Fix typo in "Simple Example". (#78661) 2002-04-21 Matthias Clasen * gtk/tmpl/gtktreemodel.sgml: * gtk/tmpl/gtkradiomenuitem.sgml: Fix crossreferences. (#78392) * gtk/gtk-sections.txt: Add GtkWidgetClass. (#78392) * gtk/tmpl/gtkwidget.sgml: Rewrite docs for gtk_widget_reset_rc_styles. (#75588) * gdk/tmpl/properties.sgml: Fix gdk_property_change docs. (#72312) * gtk/text_widget.sgml: Fix misleading example. (#79080) * gtk/tmpl/gtkdialog.sgml: Fix stock id in example. (#74439) Tue Apr 9 18:34:58 2002 Owen Taylor * gtk/gtkcontainer.c (_gtk_container_queue_resize): Always set the ALLOC_NEEDED and REQUEST_NEEDED flags up the hierarchy, even if we aren't currently in a resize container... we need this to properly handle size changes to widgets that are being moved from one heirarchy to another. (#78226) Tue Apr 9 21:41:24 2002 Kristian Rietveld Fixes #78110 * gtk/gtktreeselection.c (_gtk_tree_selection_internal_select_node): add override_browse_mode argument and implement, (gtk_tree_selection_unselect_path): always unselect the path, (toplevel): update uses of _gtk_tree_selection_internal_select_node * gtk/gtktreeview.c: update uses of _gtk_tree_selection_internal_select_node * gtk/gtktreeprivate.h (_gtk_tree_selection_internal_select_node): update prototype Tue Apr 9 21:39:44 2002 Kristian Rietveld Fixes #77862 * gtk/gtktreeprivate.h: add _gtk_tree_view_column_has_editable_cell * gtk/gtktreeviewcolumn.c (_gtk_tree_view_column_has_editable_cell): new function * gtk/gtktreeview.c (gtk_tree_view_button_press): send cell event on first click when cell isn't editable Tue Apr 9 21:37:31 2002 Kristian Rietveld * gtk/gtktreedatalist.c (_gtk_tree_data_list_check_type): add some types which were missing and useful to use (fixes #77870) 2002-04-09 Anders Carlsson * gtk/gtkfilesel.c (open_new_dir): Initialize error to NULL. 2002-04-08 Manish Singh * tests/testgtk.c: really revert testgtk.c Mon Apr 8 20:28:54 2002 Kristian Rietveld * gtk/gtktreeselection.c (gtk_tree_selection_select_path), (gtk_tree_selection_unselect_path), (gtk_tree_selection_path_is_selected): check the return value of _gtk_tree_view_find_node and return if it's TRUE. This makes those functions work somewhat saner on non-expanded trees. Fri Apr 5 18:28:56 2002 Kristian Rietveld * gtk/gtktreeselection.c (gtk_tree_selection_set_mode): free anchor row reference after unselecting the selection (fixes #76272) Fri Apr 5 18:27:48 2002 Kristian Rietveld * gtk/gtktreeview.c (gtk_tree_view_real_expand_row): only return when we don't have to open all children (fixes #75736) Fri Apr 5 18:24:24 2002 Kristian Rietveld * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear): unref cellrenderer after clearing the attributes of the renderer (fixes #75592) Fri Apr 5 05:55:14 2002 Jonathan Blandford * gtk/gtktreeview.c (gtk_tree_view_grab_focus): implement. (gtk_tree_view_move_cursor_up_down): check for focus (gtk_tree_view_move_cursor_page_up_down): ditto (gtk_tree_view_move_cursor_left_right): ditto (gtk_tree_view_move_cursor_start_end): ditto (gtk_tree_view_real_select_all): ditto (gtk_tree_view_real_unselect_all): ditto (gtk_tree_view_real_select_cursor_row): ditto (gtk_tree_view_real_toggle_cursor_row): ditto (gtk_tree_view_real_expand_collapse_cursor_row): ditto (gtk_tree_view_real_select_cursor_parent): ditto (gtk_tree_view_real_start_interactive_search): ditto * gtk/gtktreeviewcolumn.c: grab focus 2002-04-05 Alex Larsson * gdk/linux-fb/gdkkeyboard-fb.c (write_string): Fix undefined variable typo. Patch from Simon Floery Fri Apr 5 01:06:15 2002 Tim Janik * gdk/x11/gdkwindow-x11.c (set_text_property): fix segfault upon NULL return from gdk_utf8_to_string_target(). * gdk/x11/gdkselection-x11.c (gdk_utf8_to_string_target): fix return value comment to mention NULL returns upon EMFILE. Thu Apr 4 22:35:42 2002 Soeren Sandmann * tests/testgtk.c (menu_items): revert accidentally commited change to testgtk.c Thu Apr 4 22:28:08 2002 Soeren Sandmann * gtk/gtkmenuitem.c (gtk_menu_item_paint): Fix problem with menu titles being clipped (#75948) 2002-04-04 Tor Lillqvist * gdk/gdkrgb.c: Fix some bugs, and introduce a minor feature. (gdk_rgb_convert_4_pack): New function, for 16-color (4 bits per pixel) static visuals (fixes #858). (gdk_rgb_convert_gray4_pack, gdk_rgb_convert_gray4_d_pack): Fix same bugs in both functions: Odd start coordinate (partial byte) was not handled correctly. Also a partial final byte was not handled correctly. (gdk_rgb_do_colormaps): Use G_N_ELEMENTS. (gdk_rgb_create_info): For pseudocolor visuals, use the 2x2x2 colorcube only for depths 3 and 4. For static color, use it for depths 3..7 like before. (Depth 5..7 pseudocolor probably never occurs on X11. It doesn't normally occur on Win32 either, but there is experimental code in gdkvisual-win32.c to let the user restrict the size of palette used.) (gdk_rgb_init): Set gdk_rgb_verbose if the GDK_DEBUG_GDKRGB flag is set. (gdk_rgb_select_conv): Use gdk_rgb_convert_8 also for depths 5, 6 and 7 (see above). Use gdk_rgb_convert_4_pack for 4 bits per pixel static color. Tue Apr 2 11:10:13 2002 Jonathan Blandford * gtk/gtkliststore.c (gtk_list_store_set_sort_func): set the sort_func correctly, 77030 Tue Apr 2 13:44:27 2002 Tim Janik * configure.in: update version to 2.0.2, binary age 2, interface age 2. * NEWS: updates for 2.0.2. Mon Apr 1 22:20:24 2002 Kristian Rietveld * gtk/gtktreeview.c (gtk_tree_view_move_cursor_page_up_down): add check for y > tree_view->priv->height (fixes #76974) Mon Apr 1 22:19:39 2002 Kristian Rietveld * gtk/gtktreemodelsort.c (gtk_tree_model_sort_sort_level): get the stamp changes right this time Mon Apr 1 22:13:24 2002 Kristian Rietveld * gtk/gtktreemodel.c (gtk_tree_row_reference_free): only disconnect the ref callbacks when model == proxy (Thanks go to Manuel Clos Crespo for the remote debugging) Sat Mar 30 15:19:24 2002 Kristian Rietveld * gtk/gtktreemodelsort.c: revert the latest stamp increment changes, as it broke stuff for trees Fri Mar 29 18:15:12 2002 Owen Taylor * ===== Released 2.0.1 ====== Fri Mar 29 18:09:18 2002 Owen Taylor * gtk/gtkaccelgroup.c (gtk_accel_group_query): Call gdk_keyval_to_lower() on the key passed in, since we lowercase all other key vals passed in, so querying keyvals will otherwise fail if the caller used an uppercase accelerators (#76899, Vitaly Tishkov) Fri Mar 29 17:41:21 2002 Owen Taylor * gtk/gtkmain.c (load_modules): Fix screwup in handling of module path that was resulting in freed memory being accessed when both GTK_MODULES and a theme were set. (#76902, Johan Dahlin) Fri Mar 29 17:57:36 2002 Owen Taylor * gtk/gtkiconfactory.c (get_default_icons): Fix wrong stock id's for ADD/REMOVE. (#76915, Vitaly Tishkov) 2002-03-29 Hans Breuer * gtk/gtkmain.h : fix typo in gtk_init_check macro, which caused crashes if argc != 0 * gtk/stock-icons/makefile.msc : added new icons Fri Mar 29 20:17:35 2002 Kristian Rietveld * gtk/gtktreemodelsort.c (gtk_tree_model_sort_rows_reordered): remove call to gtk_tree_model_sort_increment_stamp (gtk_tree_model_sort_sort_level): always increment the stamp Fri Mar 29 00:19:41 2002 Owen Taylor * NEWS: Updates * configure.in: Version 2.0.1, binary, interface age 1. * configure.in (GDK_PIXBUF_VERSION): Up required versions of dependencies. * gtk/gtkiconfactory.c gtk/stock-icons/Makefile.am: Add stock_add/remove_16. Thu Mar 28 18:38:30 2002 Owen Taylor * gtk/gtk[hv]paned.c (gtk_[hv]paned_size_allocate): Don't show the window unless the widget is mapped. (#76742, Dennis Björklund, Soeren Sandmann) 2002-03-29 Hans Breuer Fixed dashed line issues (#74441) to an IMO reasonable extend. That is: use PS_USERSTYLE on WinNT (the next GDI limit appears to be with lines width > 50); Render horizontal and vertical dashed lines on Win9x 'by hand'. Dotted selection rectangles and Dia look nice ... * gdk/win32/gdkprivate-win32.h : add pen_dashes pointer and num_pen_dashes to _GdkGCWin32 * gdk/win32/gdkgc-win32.c : initialize pen_dashes and remove the guesses from dashes to windoze line styles. (predraw_set_forground) : always ExtCreatePen (PS_SOLID) on Win9x, which does not support PS_USERSTYLE. * gdk/win32/gdkdrawable-win32.c : new functions render_line_ . Use them if not running on NT in gdk_win32_draw_ () * gdk/win32/gdkkeys-win32.c (gdk_keyval_name) : return NULL for keyval == 0 to avoid to have zeros in all menu entries without accelerator. 2002-03-29 Jakub Steiner * gtk/stock-icons/stock_add_24.png: * gtk/stock-icons/stock_add_16.png: * gtk/stock-icons/stock_remove_24.png: * gtk/stock-icons/stock_remove_16.png: use a simple '+' and '-', works better. the old box was too clumsy Thu Mar 28 21:11:04 2002 Tim Janik * gtk/gtkfilesel.c (open_new_dir): when encountering non-UTF-8 file names, alert the user with g_message() instead of g_warning() and put out the actual conversion error. 2002-03-28 Dave Camp * gtk/gtktreeview.c (install_scroll_sync_handler): Don't install the handler if the widget isn't realized. 2002-03-28 Jakub Steiner * gtk/stock-icons/stock_font*: * gtk/stock-icons/stock_align*: * gtk/stock-icons/stock_text*: better solution to the dark theme problem. Also looks more pretty IMHO 2002-03-27 Matthias Clasen * configure.in: Try to find libpng via pkg-config first, since libpng-1.2.2 will come with a .pc file. Wed Mar 27 11:10:39 2002 Owen Taylor * gtk/gtknotebook.c (gtk_notebook_real_remove): Set page->last_focus_child to NULL as well as removing the weak reference, to deal with reentrancy in set_focus_child(). (#76634, Dennis Björklund) 2002-03-27 Murray Cumming * gtk/gtktreeview.c: Corrected registered return type of "move-cursor" signal. Had to add a marshaller to gtk/gtkmarshalers.list. Tue Mar 26 14:46:50 2002 Owen Taylor * gtk/gtkmenu.c (gtk_menu_popup): Shuffle the ordering around some more (position before realizing) fixing problems with arrows popping up at the wrong time (#73386), hopefully not introducing other problems. (Reported by Ettore Perrazoli, others) 2002-03-26 Dave Camp * gtk/gtktreeview.c (gtk_tree_view_button_press): Free the path after calling gtk_tree_view_row_activated() rather than before. 2002-03-25 Sven Neumann * gtk/gtkrc.c (gtk_rc_parse_font_name): free the style's font_description before assigning a new one. (gtk_rc_parse_stock): always unref the created icon_set. #76289 2002-03-25 Mark McLoughlin * gtk/gtkbindings.c: (gtk_binding_entry_add_signal), kill code duplicated in gtk_binding_entry_add_signall. Sun Mar 24 10:32:38 2002 Jonathan Blandford * gtk/gtktreemodel.c (gtk_tree_path_copy): Make path arg const, #75653 * gtk/gtkfontsel.c (gtk_font_selection_show_available_styles): fix a warning * gtk/gtktreeview.c (gtk_tree_view_button_press): remove the grab when we emit row_activated so that listeners of this signal can grab the mouse, #75629 2002-03-23 Havoc Pennington * gtk/gtktextlayout.c (gtk_text_layout_real_invalidate): invalidate the line containing start, even if the [start,end) range is empty (just invalidate [start,end], essentially). Partially fixes #72374 2002-03-23 Havoc Pennington * gtk/gtktextview.c (gtk_text_view_do_popup): end any selection in progress, patch from db@zigo.dhs.org, #74620 2002-03-23 Havoc Pennington * gtk/gtktextview.c (gtk_text_view_move_cursor_internal): extend selection for pageup/pagedown and ctrl+pageup/pagedown if shift is held. more of #53934 2002-03-23 Havoc Pennington * gtk/gtktextview.c (gtk_text_view_destroy_layout): disconnect layout handlers earlier in the function, to avoid possible reentrancy screwups (gtk_text_view_invalidate): Don't install idle handlers if layout == NULL, otherwise we get problems during finalization since clearing the buffer invalidates and puts the idle handlers back after we destroy the layout. #74660 (gtk_text_view_ensure_layout): Install the validation handlers right after creating the layout. * gtk/gtktexttagtable.c (foreach_unref): call _gtk_text_buffer_notify_will_remove_tag(), #75126 2002-03-22 Havoc Pennington * gdk/x11/gdkfont-x11.c (gdk_fontset_load): add more explanatory text to the error message about missing charsets, and use g_printerr() not g_warning() since this is typically not a programming error (we do not export any API to ask whether a font set will have missing charsets so apps realistically can't do anything other than try the gdk_fontset_load()) * gtk/gtktextview.c (gtk_text_view_key_press_event): return FALSE if the text view isn't editable and the user presses Return, so default buttons and such can be activated, #74937 * gtk/gtktextbuffer.c (paste_from_buffer): don't insert if the insertion point is not editable and the paste is interactive, #74125 * gtk/gtkwindow.c (gtk_window_move_resize): enhance the #if 0 debug spew * gtk/gtktextbuffer.c (cut_or_copy): only remove the previous cut/copied data right before replacing it, when we know we are going to replace it. Fixes #74049 2002-03-22 Richard Hult * gdk/gdkevents.c (gdk_event_get_root_coords): Fix typo, where x value was assigned to both x and y. Fri Mar 22 11:29:11 2002 Owen Taylor Partial fix for problem where keypad keys acted as shift-arrows in an entry rather than arrows (#74327) * gtk/gtkkeyhash.c (_gtk_key_hash_lookup): Sort lookup results by number of modifiers in the entry. Fixes problem where if a key matched both modified and unmodified key bindings ... e.g., the distinguishing key binding was consumed, then it was random which was used. * gtk/gtkbindings.c (gtk_binding_entries_sort_patterns): Catch the case where there are multiple entries from the same bindingset (with different modifiers), and use only the first entry, which, with the change in _gtk_key_hash_lookup() will be the preferred value. Fri Mar 22 10:56:19 2002 Owen Taylor * gtk/gtkaccelmap.c (gtk_accel_map_save_fd): Fix memory leak. (#74400, Morten Welinder.) * gtk/gtkaccelmap.c: Properly handle short returns from write() calls. (Handling EINTR isn't enough... that only handles the case where you were interrupted before you wrote a single byte.) * gdk/linux-fb/gdkmouse-fb.c gdk/linux-fb/gdkkeyboard-fb.c: Robustify against short returns from write() calls. Fri Mar 22 10:12:10 2002 Owen Taylor * gtk/gtktextview.c (gtk_text_view_paint): Change G_BREAKPOINT() to g_assert_not_reached (). (#75865, Ashok Venkiteswaran) 2002-03-22 Tor Lillqvist * gdk/win32/gdkgc-win32.c (gdk_win32_gc_set_dashes): Don't clear all of the pen_style, just the PS_STYLE_MASK. Seems to fix #74441, but that is just the special case of one-pixel wide one-pixel on-off dotted lines. To fully implement generic X11 style dashed lines a major rewrite would be needed. 2002-03-21 Matthias Clasen * gtk/gtkaccelgroup.c (gtk_accelerator_valid): Trivial typo fix. (Vitaly Tishkov, #75726) Thu Mar 21 10:04:05 2002 Owen Taylor * gdk/gdkwindow.c (gdk_window_real_get_depth): Remove some left over debugging code with a G_BREAKPOINT() in it. Wed Mar 20 19:33:31 2002 Owen Taylor * gtk/gtkcalendar.c (gtk_calendar_main_button): When changing months when the user clicks on a prev-month or next-month day, focus and select the new day. Ignore double clicks on prev-month, next-month days. (Based on suggestions from Andras Salamon, #74173) * gtk/gtkcalendar.c: Implement th01700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3230343432383833373231323236303434343638000000001800000000000000481c141e963f0a0d0400000015e1f72e64770034" ADD 134217747 "def" "/apps/nautilus" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3230343432383833373231323236303434343638000000001800000000000000481c141e963f0a0d0400000015e1f72e64770034" ADD 150994964 "def" "/system/gnome-vfs" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3230343432383833373231323236303434343638000000001800000000000000481c141e963f0a0d0400000015e1f72e64770034" CLIENTADD "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d3738303530313930373932313535333437300000000000001800000000000000aa339f6f8b3d48850400000096860fef60231737" ADD 167772181 "def" "/apps/nautilus" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d3738303530313930373932313535333437300000000000001800000000000000aa339f6f8b3d48850400000096860fef60231737" CLIENTADD "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d36313132313137333236333037393935383300000000000018000000000000008d73b7d1346083e8040000009196fd8de688604d" ADD 184549398 "def" "/apps/nautilus" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d36313132313137333236333037393935383300000000000018000000000000008d73b7d1346083e8040000009196fd8de688604d" CLIENTADD "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3135363339303134353031393239333638383337000000001800000000000000ddd33ce6282042d304000000e640a9f986363f72" ADD 201326615 "def" "/apps/nautilus" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3135363339303134353031393239333638383337000000001800000000000000ddd33ce6282042d304000000e640a9f986363f72" CLIENTADD "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002c0000002f746d702f6f726269742d6d617474686961732f6f72622d3131383231333939373238343433353033323400000000001800000000000000d4f6f197a3d8217704000000dd5fdd74d176f84c" ADD 218103832 "def" "/apps/nautilus" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002c0000002f746d702f6f726269742d6d617474686961732f6f72622d3131383231333939373238343433353033323400000000001800000000000000d4f6f197a3d8217704000000dd5fdd74d176f84c" ADD 234881049 "def" "/system/gnome-vfs" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d3738303530313930373932313535333437300000000000001800000000000000aa339f6f8b3d48850400000096860fef60231737" ADD 251658266 "def" "/system/gnome-vfs" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002d0000002f746d702f6f726269742d6d617474686961732f6f72622d3135363339303134353031393239333638383337000000001800000000000000ddd33ce6282042d304000000e640a9f986363f72" ADD 268435483 "def" "/system/gnome-vfs" "IOR:010000001700000049444c3a436f6e6669674c697374656e65723a312e30000001000000caaedfba54000000010100002b0000002f746d702f6f726269742d6d617474686961732f6f72622d36313132313137333236333037393935383300000000000018000000000000008d73b7d1346083e8040000009196fd8de688604d" ADD 285212700 "def" "/system/gnome-vfs" "" ALIGN="RIGHT" VALIGN="TOP" >Returns : a new GtkIconFactory


gtk_icon_factory_remove_default ()

void        gtk_icon_factory_remove_default (GtkIconFactory *factory);

Removes an icon factory from the list of default icon factories. Not normally used; you might use it for a library that can be unloaded or shut down.

factory : a GtkIconFactory previously added with gtk_icon_factory_add_default()


gtk_icon_set_add_source ()

void        gtk_icon_set_add_source         (GtkIconSet *icon_set,
                                             const GtkIconSource *source);

Icon sets have a list of GtkIconSource, which they use as base icons for rendering icons in different states and sizes. Icons are scaled, made to look insensitive, etc. in gtk_icon_set_render_icon(), but GtkIconSet needs base images to work with. The base images and when to use them are described by a GtkIconSource.

This function copies source, so you can reuse the same source immediately without affecting the icon set.

An example of when you'd use this function: a web browser's "Back to Previous Page" icon might point in a different direction in Hebrew and in English; it might look different when insensitive; and it might change size depending on toolbar mode (small/large icons). So a single icon set would contain all those variants of the icon, and you might add a separate source for each one.

You should nearly always add a "default" icon source with all fields wildcarded, which will be used as a fallback if no more specific source matches. GtkIconSet always prefers more specific icon sources to more generic icon sources. The order in which you add the sources to the icon set does not matter.

gtk_icon_set_new_from_pixbuf() creates a new icon set with a default icon source based on the given pixbuf.

icon_set : a GtkIconSet
source : a GtkIconSource


gtk_icon_set_copy ()

GtkIconSet* gtk_icon_set_copy               (GtkIconSet *icon_set);

Copies icon_set by value.

icon_set : a GtkIconSet
Returns : a new GtkIconSet identical to the first.


gtk_icon_set_new ()

GtkIconSet* gtk_icon_set_new                (void);

Creates a new GtkIconSet. A GtkIconSet represents a single icon in various sizes and widget states. It can provide a GdkPixbuf for a given size and state on request, and automatically caches some of the rendered GdkPixbuf objects.

Normally you would use gtk_widget_render_icon() instead of using GtkIconSet directly. The one case where you'd use GtkIconSet is to create application-specific icon sets to place in a GtkIconFactory.

Returns : a new GtkIconSet


gtk_icon_set_new_from_pixbuf ()

GtkIconSet* gtk_icon_set_new_from_pixbuf    (GdkPixbuf *pixbuf);

Creates a new GtkIconSet with pixbuf as the default/fallback source image. If you don't add any additional GtkIconSource to the icon set, all variants of the icon will be created from pixbuf, using scaling, pixelation, etc. as required to adjust the icon size or make the icon look insensitive/prelighted.

pixbuf : a GdkPixbuf
Returns : a new GtkIconSet


gtk_icon_set_ref ()

GtkIconSet* gtk_icon_set_ref                (GtkIconSet *icon_set);

Increments the reference count on icon_set.

icon_set : a GtkIconSet.
Returns : icon_set.


gtk_icon_set_render_icon ()

GdkPixbuf*  gtk_icon_set_render_icon        (GtkIconSet *icon_set,
                                             GtkStyle *style,
                                             GtkTextDirection direction,
                                             GtkStateType state,
                                             GtkIconSize size,
                                             GtkWidget *widget,
                                             const char *detail);

Renders an icon using gtk_style_render_icon(). In most cases, gtk_widget_render_icon() is better, since it automatically provides most of the arguments from the current widget settings. This function never returns NULL; if the icon can't be rendered (perhaps because an image file fails to load), a default "missing image" icon will be returned instead.

icon_set : a GtkIconSet
style : a GtkStyle associated with widget, or NULL
direction : text direction
state : widget state
size : icon size
widget : widget that will display the icon, or NULL
detail : detail to pass to the theme engine, or NULL
Returns : a GdkPixbuf to be displayed


gtk_icon_set_unref ()

void        gtk_icon_set_unref              (GtkIconSet *icon_set);

Decrements the reference count on icon_set, and frees memory if the reference count reaches 0.

icon_set : a GtkIconSet


gtk_icon_size_lookup ()

gboolean    gtk_icon_size_lookup            (GtkIconSize size,
                                             gint *width,
                                             gint *height);

Obtains the pixel size of a semantic icon size, normally size would be GTK_ICON_SIZE_MENU, GTK_ICON_SIZE_BUTTON, etc. This function isn't normally needed, gtk_widget_render_icon() is the usual way to get an icon for rendering, then just look at the size of the rendered pixbuf. The rendered pixbuf may not even correspond to the width/height returned by gtk_icon_size_lookup(), because themes are free to render the pixbuf however they like, including changing the usual size.

size : an icon size
width : location to store icon width
height : location to store icon height
Returns : TRUE if size was a valid size


gtk_icon_size_register ()

GtkIconSize gtk_icon_size_register          (const gchar *name,
                                             gint width,
                                             gint height);

Registers a new icon size, along the same lines as GTK_ICON_SIZE_MENU, etc. Returns the integer value for the size.

name : name of the icon size
width : the icon width
height : the icon height
Returns : integer value representing the size


gtk_icon_size_register_alias ()

void        gtk_icon_size_register_alias    (const gchar *alias,
                                             GtkIconSize target);

Registers alias as another name for target. So calling gtk_icon_size_from_name() with alias as argument will return target.

alias : an alias for target
target : an existing icon size


gtk_icon_size_from_name ()

GtkIconSize gtk_icon_size_from_name         (const gchar *name);

Looks up the icon size associated with name.

name : the name to look up.
Returns : the icon size with the given name.


gtk_icon_size_get_name ()

G_CONST_RETURN gchar* gtk_icon_size_get_name
                                            (GtkIconSize size);

Gets the canonical name of the given icon size. The returned string is statically allocated and should not be freed.

size : a GtkIconSize.
Returns : the name of the given icon size.


gtk_icon_set_get_sizes ()

void        gtk_icon_set_get_sizes          (GtkIconSet *icon_set,
                                             GtkIconSize **sizes,
                                             gint *n_sizes);

Obtains a list of icon sizes this icon set can render. The returned array must be freed with g_free().

icon_set : a GtkIconSet
sizes : return location for array of sizes
n_sizes : location to store number of elements in returned array


gtk_icon_source_get_direction ()

GtkTextDirection gtk_icon_source_get_direction
                                            (const GtkIconSource *source);

Obtains the text direction this icon source applies to. The return value is only useful/meaningful if the text direction is not wildcarded.

source : a GtkIconSource
Returns : text direction this source matches


gtk_icon_source_get_direction_wildcarded ()

gboolean    gtk_icon_source_get_direction_wildcarded
                                            (const GtkIconSource *source);

Gets the value set by gtk_icon_source_set_direction_wildcarded().

source : a GtkIconSource
Returns : TRUE if this icon source is a base for any text direction variant


gtk_icon_source_get_filename ()

G_CONST_RETURN gchar* gtk_icon_source_get_filename
                                            (const GtkIconSource *source);

Retrieves the source filename, or NULL if none is set. The filename is not a copy, and should not be modified or expected to persist beyond the lifetime of the icon source.

source : a GtkIconSource
Returns : image filename


gtk_icon_source_get_pixbuf ()

GdkPixbuf*  gtk_icon_source_get_pixbuf      (const GtkIconSource *source);

Retrieves the source pixbuf, or NULL if none is set. The reference count on the pixbuf is not incremented.

source : a GtkIconSource
Returns : source pixbuf


gtk_icon_source_get_size ()

GtkIconSize gtk_icon_source_get_size        (const GtkIconSource *source);

Obtains the icon size this source applies to. The return value is only useful/meaningful if the icon size is