2
// Generated by gtkmmproc -- DO NOT MODIFY!
3
#ifndef _GTKMM_ICONFACTORY_H
4
#define _GTKMM_ICONFACTORY_H
9
/* $Id: iconfactory.hg,v 1.1 2003/01/21 13:40:26 murrayc Exp $ */
11
/* Copyright (C) 1998-2002 The gtkmm Development Team
13
* This library is free software; you can redistribute it and/or
14
* modify it under the terms of the GNU Lesser General Public
15
* License as published by the Free Software Foundation; either
16
* version 2.1 of the License, or (at your option) any later version.
18
* This library is distributed in the hope that it will be useful,
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21
* Lesser General Public License for more details.
23
* You should have received a copy of the GNU Lesser General Public
24
* License along with this library; if not, write to the Free
25
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
29
#include <gtkmm/enums.h>
30
#include <glibmm/object.h>
31
#include <gtkmm/enums.h>
32
#include <gtkmm/iconset.h>
33
#include <gtkmm/stockid.h>
36
#ifndef DOXYGEN_SHOULD_SKIP_THIS
37
typedef struct _GtkIconFactory GtkIconFactory;
38
typedef struct _GtkIconFactoryClass GtkIconFactoryClass;
39
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
43
{ class IconFactory_Class; } // namespace Gtk
48
class IconFactory : public Glib::Object
51
#ifndef DOXYGEN_SHOULD_SKIP_THIS
54
typedef IconFactory CppObjectType;
55
typedef IconFactory_Class CppClassType;
56
typedef GtkIconFactory BaseObjectType;
57
typedef GtkIconFactoryClass BaseClassType;
59
private: friend class IconFactory_Class;
60
static CppClassType iconfactory_class_;
64
IconFactory(const IconFactory&);
65
IconFactory& operator=(const IconFactory&);
68
explicit IconFactory(const Glib::ConstructParams& construct_params);
69
explicit IconFactory(GtkIconFactory* castitem);
71
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
74
virtual ~IconFactory();
76
#ifndef DOXYGEN_SHOULD_SKIP_THIS
77
static GType get_type() G_GNUC_CONST;
80
static GType get_base_type() G_GNUC_CONST;
83
///Provides access to the underlying C GObject.
84
GtkIconFactory* gobj() { return reinterpret_cast<GtkIconFactory*>(gobject_); }
86
///Provides access to the underlying C GObject.
87
const GtkIconFactory* gobj() const { return reinterpret_cast<GtkIconFactory*>(gobject_); }
89
///Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
90
GtkIconFactory* gobj_copy();
101
static Glib::RefPtr<IconFactory> create();
104
/** Adds the given @a icon_set to the icon factory, under the name
105
* @a stock_id. @a stock_id should be namespaced for your application,
106
* e.g. "myapp-whatever-icon". Normally applications create a
107
* Gtk::IconFactory, then add it to the list of default factories with
108
* add_default(). Then they pass the @a stock_id to
109
* widgets such as Gtk::Image to display the icon. Themes can provide
110
* an icon with the same name (such as "myapp-whatever-icon") to
111
* override your application's default icons. If an icon already
112
* existed in @a factory for @a stock_id, it is unreferenced and replaced
113
* with the new @a icon_set.
114
* @param stock_id Icon name.
115
* @param icon_set Icon set.
117
void add(const Gtk::StockID& stock_id, const Glib::RefPtr<IconSet>& icon_set);
119
/** Adds an icon factory to the list of icon factories searched by
120
* Gtk::Style::lookup_icon_set(). This means that, for example,
121
* the Image::Image(const Gtk::StockID& stock_id, IconSize size) constructor will be able to find icons in @a factory.
122
* There will normally be an icon factory added for each library or
123
* application that comes with icons. The default icon factories
124
* can be overridden by themes.
128
/** Removes an icon factory from the list of default icon
129
* factories. Not normally used; you might use it for a library that
130
* can be unloaded or shut down.
132
void remove_default();
138
//C++ methods used to invoke GTK+ virtual functions:
141
//GTK+ Virtual Functions (override these to change behaviour):
143
//Default Signal Handlers::
153
/** A Glib::wrap() method for this object.
155
* @param object The C instance.
156
* @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
157
* @result A C++ instance that wraps this C instance.
159
* @relates Gtk::IconFactory
161
Glib::RefPtr<Gtk::IconFactory> wrap(GtkIconFactory* object, bool take_copy = false);
165
#endif /* _GTKMM_ICONFACTORY_H */