1 2@c %start of fragment 3 4@deftp Class <gtk-stock-item> 5Opaque pointer. 6 7This class defines no direct slots. 8 9@end deftp 10 11@deffn Function gtk-stock-add (items@tie{}@code{scm}) 12Registers each of the stock items in @var{items}. If an item already exists with 13the same stock ID as one of the @var{items}, the old item gets replaced. The 14stock items are copied, so GTK+ does not hold any pointer into @var{items} and 15@var{items} can be freed. Use @code{gtk-stock-add-static} if @var{items} is 16persistent and GTK+ need not copy the array. 17 18@table @var 19@item items 20a @code{<gtk-stock-item>} or array of items 21 22@item n-items 23number of @code{<gtk-stock-item>} in @var{items} 24 25@end table 26 27@end deffn 28 29@deffn Function gtk-stock-add-static (items@tie{}@code{<gtk-stock-item>}) (n_items@tie{}@code{unsigned-int}) 30Same as @code{gtk-stock-add}, but doesn't copy @var{items}, so @var{items} must 31persist until application exit. 32 33@table @var 34@item items 35a @code{<gtk-stock-item>} or array of @code{<gtk-stock-item>} 36 37@item n-items 38number of items 39 40@end table 41 42@end deffn 43 44@deffn Function gtk-stock-item-copy (self@tie{}@code{<gtk-stock-item>}) @result{}@tie{} (ret@tie{}@code{<gtk-stock-item>}) 45Copies a stock item, mostly useful for language bindings and not in 46applications. 47 48@table @var 49@item item 50a @code{<gtk-stock-item>} 51 52@item ret 53a new @code{<gtk-stock-item>} 54 55@end table 56 57@end deffn 58 59@deffn Function gtk-stock-list-ids @result{}@tie{} (ret@tie{}@code{gslist-of}) 60Retrieves a list of all known stock IDs added to a @code{<gtk-icon-factory>} or 61registered with @code{gtk-stock-add}. The list must be freed with 62@code{g-slist-free}, and each string in the list must be freed with 63@code{g-free}. 64 65@table @var 66@item ret 67a list of known stock IDs 68 69@end table 70 71@end deffn 72 73@deffn Function gtk-stock-lookup (stock_id@tie{}@code{mchars}) @result{}@tie{} (ret@tie{}@code{scm}) 74Fills @var{item} with the registered values for @var{stock-id}, returning 75@samp{@code{#t}} if @var{stock-id} was known. 76 77@table @var 78@item stock-id 79a stock item name 80 81@item item 82stock item to initialize with values 83 84@item ret 85@samp{@code{#t}} if @var{item} was initialized 86 87@end table 88 89@end deffn 90 91 92@c %end of fragment 93