1 | /* GTK - The GIMP Toolkit |
2 | |
3 | Copyright (C) 2001 CodeFactory AB |
4 | Copyright (C) 2001 Anders Carlsson <[email protected]> |
5 | Copyright (C) 2003, 2004 Matthias Clasen <[email protected]> |
6 | |
7 | This library is free software; you can redistribute it and/or |
8 | modify it under the terms of the GNU Library General Public License as |
9 | published by the Free Software Foundation; either version 2 of the |
10 | License, or (at your option) any later version. |
11 | |
12 | This library is distributed in the hope that it will be useful, |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
15 | Library General Public License for more details. |
16 | |
17 | You should have received a copy of the GNU Library General Public |
18 | License along with this library. If not, see <http://www.gnu.org/licenses/>. |
19 | |
20 | Author: Anders Carlsson <[email protected]> |
21 | */ |
22 | |
23 | #ifndef __GTK_ABOUT_DIALOG_H__ |
24 | #define __GTK_ABOUT_DIALOG_H__ |
25 | |
26 | #if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION) |
27 | #error "Only <gtk/gtk.h> can be included directly." |
28 | #endif |
29 | |
30 | #include <gtk/gtkdialog.h> |
31 | |
32 | G_BEGIN_DECLS |
33 | |
34 | #define GTK_TYPE_ABOUT_DIALOG (gtk_about_dialog_get_type ()) |
35 | #define GTK_ABOUT_DIALOG(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialog)) |
36 | #define GTK_ABOUT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialogClass)) |
37 | #define GTK_IS_ABOUT_DIALOG(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GTK_TYPE_ABOUT_DIALOG)) |
38 | #define GTK_IS_ABOUT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ABOUT_DIALOG)) |
39 | #define GTK_ABOUT_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialogClass)) |
40 | |
41 | typedef struct _GtkAboutDialog GtkAboutDialog; |
42 | typedef struct _GtkAboutDialogClass GtkAboutDialogClass; |
43 | typedef struct _GtkAboutDialogPrivate GtkAboutDialogPrivate; |
44 | |
45 | /** |
46 | * GtkLicense: |
47 | * @GTK_LICENSE_UNKNOWN: No license specified |
48 | * @GTK_LICENSE_CUSTOM: A license text is going to be specified by the |
49 | * developer |
50 | * @GTK_LICENSE_GPL_2_0: The GNU General Public License, version 2.0 or later |
51 | * @GTK_LICENSE_GPL_3_0: The GNU General Public License, version 3.0 or later |
52 | * @GTK_LICENSE_LGPL_2_1: The GNU Lesser General Public License, version 2.1 or later |
53 | * @GTK_LICENSE_LGPL_3_0: The GNU Lesser General Public License, version 3.0 or later |
54 | * @GTK_LICENSE_BSD: The BSD standard license |
55 | * @GTK_LICENSE_MIT_X11: The MIT/X11 standard license |
56 | * @GTK_LICENSE_ARTISTIC: The Artistic License, version 2.0 |
57 | * @GTK_LICENSE_GPL_2_0_ONLY: The GNU General Public License, version 2.0 only. Since 3.12. |
58 | * @GTK_LICENSE_GPL_3_0_ONLY: The GNU General Public License, version 3.0 only. Since 3.12. |
59 | * @GTK_LICENSE_LGPL_2_1_ONLY: The GNU Lesser General Public License, version 2.1 only. Since 3.12. |
60 | * @GTK_LICENSE_LGPL_3_0_ONLY: The GNU Lesser General Public License, version 3.0 only. Since 3.12. |
61 | * @GTK_LICENSE_AGPL_3_0: The GNU Affero General Public License, version 3.0 or later. Since: 3.22. |
62 | * @GTK_LICENSE_AGPL_3_0_ONLY: The GNU Affero General Public License, version 3.0 only. Since: 3.22.27. |
63 | * |
64 | * The type of license for an application. |
65 | * |
66 | * This enumeration can be expanded at later date. |
67 | * |
68 | * Since: 3.0 |
69 | */ |
70 | typedef enum { |
71 | GTK_LICENSE_UNKNOWN, |
72 | GTK_LICENSE_CUSTOM, |
73 | |
74 | GTK_LICENSE_GPL_2_0, |
75 | GTK_LICENSE_GPL_3_0, |
76 | |
77 | GTK_LICENSE_LGPL_2_1, |
78 | GTK_LICENSE_LGPL_3_0, |
79 | |
80 | GTK_LICENSE_BSD, |
81 | GTK_LICENSE_MIT_X11, |
82 | |
83 | GTK_LICENSE_ARTISTIC, |
84 | |
85 | GTK_LICENSE_GPL_2_0_ONLY, |
86 | GTK_LICENSE_GPL_3_0_ONLY, |
87 | GTK_LICENSE_LGPL_2_1_ONLY, |
88 | GTK_LICENSE_LGPL_3_0_ONLY, |
89 | |
90 | GTK_LICENSE_AGPL_3_0, |
91 | GTK_LICENSE_AGPL_3_0_ONLY |
92 | } GtkLicense; |
93 | |
94 | /** |
95 | * GtkAboutDialog: |
96 | * |
97 | * The #GtkAboutDialog-struct contains |
98 | * only private fields and should not be directly accessed. |
99 | */ |
100 | struct _GtkAboutDialog |
101 | { |
102 | GtkDialog parent_instance; |
103 | |
104 | /*< private >*/ |
105 | GtkAboutDialogPrivate *priv; |
106 | }; |
107 | |
108 | struct _GtkAboutDialogClass |
109 | { |
110 | GtkDialogClass parent_class; |
111 | |
112 | gboolean (*activate_link) (GtkAboutDialog *dialog, |
113 | const gchar *uri); |
114 | |
115 | /* Padding for future expansion */ |
116 | void (*_gtk_reserved1) (void); |
117 | void (*_gtk_reserved2) (void); |
118 | void (*_gtk_reserved3) (void); |
119 | void (*_gtk_reserved4) (void); |
120 | }; |
121 | |
122 | GDK_AVAILABLE_IN_ALL |
123 | GType gtk_about_dialog_get_type (void) G_GNUC_CONST; |
124 | GDK_AVAILABLE_IN_ALL |
125 | GtkWidget *gtk_about_dialog_new (void); |
126 | GDK_AVAILABLE_IN_ALL |
127 | void gtk_show_about_dialog (GtkWindow *parent, |
128 | const gchar *first_property_name, |
129 | ...) G_GNUC_NULL_TERMINATED; |
130 | GDK_AVAILABLE_IN_ALL |
131 | const gchar * gtk_about_dialog_get_program_name (GtkAboutDialog *about); |
132 | GDK_AVAILABLE_IN_ALL |
133 | void gtk_about_dialog_set_program_name (GtkAboutDialog *about, |
134 | const gchar *name); |
135 | GDK_AVAILABLE_IN_ALL |
136 | const gchar * gtk_about_dialog_get_version (GtkAboutDialog *about); |
137 | GDK_AVAILABLE_IN_ALL |
138 | void gtk_about_dialog_set_version (GtkAboutDialog *about, |
139 | const gchar *version); |
140 | GDK_AVAILABLE_IN_ALL |
141 | const gchar * gtk_about_dialog_get_copyright (GtkAboutDialog *about); |
142 | GDK_AVAILABLE_IN_ALL |
143 | void gtk_about_dialog_set_copyright (GtkAboutDialog *about, |
144 | const gchar *copyright); |
145 | GDK_AVAILABLE_IN_ALL |
146 | const gchar * (GtkAboutDialog *about); |
147 | GDK_AVAILABLE_IN_ALL |
148 | void (GtkAboutDialog *about, |
149 | const gchar *); |
150 | GDK_AVAILABLE_IN_ALL |
151 | const gchar * gtk_about_dialog_get_license (GtkAboutDialog *about); |
152 | GDK_AVAILABLE_IN_ALL |
153 | void gtk_about_dialog_set_license (GtkAboutDialog *about, |
154 | const gchar *license); |
155 | GDK_AVAILABLE_IN_ALL |
156 | void gtk_about_dialog_set_license_type (GtkAboutDialog *about, |
157 | GtkLicense license_type); |
158 | GDK_AVAILABLE_IN_ALL |
159 | GtkLicense gtk_about_dialog_get_license_type (GtkAboutDialog *about); |
160 | |
161 | GDK_AVAILABLE_IN_ALL |
162 | gboolean gtk_about_dialog_get_wrap_license (GtkAboutDialog *about); |
163 | GDK_AVAILABLE_IN_ALL |
164 | void gtk_about_dialog_set_wrap_license (GtkAboutDialog *about, |
165 | gboolean wrap_license); |
166 | |
167 | GDK_AVAILABLE_IN_ALL |
168 | const gchar * gtk_about_dialog_get_website (GtkAboutDialog *about); |
169 | GDK_AVAILABLE_IN_ALL |
170 | void gtk_about_dialog_set_website (GtkAboutDialog *about, |
171 | const gchar *website); |
172 | GDK_AVAILABLE_IN_ALL |
173 | const gchar * gtk_about_dialog_get_website_label (GtkAboutDialog *about); |
174 | GDK_AVAILABLE_IN_ALL |
175 | void gtk_about_dialog_set_website_label (GtkAboutDialog *about, |
176 | const gchar *website_label); |
177 | GDK_AVAILABLE_IN_ALL |
178 | const gchar* const * gtk_about_dialog_get_authors (GtkAboutDialog *about); |
179 | GDK_AVAILABLE_IN_ALL |
180 | void gtk_about_dialog_set_authors (GtkAboutDialog *about, |
181 | const gchar **authors); |
182 | GDK_AVAILABLE_IN_ALL |
183 | const gchar* const * gtk_about_dialog_get_documenters (GtkAboutDialog *about); |
184 | GDK_AVAILABLE_IN_ALL |
185 | void gtk_about_dialog_set_documenters (GtkAboutDialog *about, |
186 | const gchar **documenters); |
187 | GDK_AVAILABLE_IN_ALL |
188 | const gchar* const * gtk_about_dialog_get_artists (GtkAboutDialog *about); |
189 | GDK_AVAILABLE_IN_ALL |
190 | void gtk_about_dialog_set_artists (GtkAboutDialog *about, |
191 | const gchar **artists); |
192 | GDK_AVAILABLE_IN_ALL |
193 | const gchar * gtk_about_dialog_get_translator_credits (GtkAboutDialog *about); |
194 | GDK_AVAILABLE_IN_ALL |
195 | void gtk_about_dialog_set_translator_credits (GtkAboutDialog *about, |
196 | const gchar *translator_credits); |
197 | GDK_AVAILABLE_IN_ALL |
198 | GdkPixbuf *gtk_about_dialog_get_logo (GtkAboutDialog *about); |
199 | GDK_AVAILABLE_IN_ALL |
200 | void gtk_about_dialog_set_logo (GtkAboutDialog *about, |
201 | GdkPixbuf *logo); |
202 | GDK_AVAILABLE_IN_ALL |
203 | const gchar * gtk_about_dialog_get_logo_icon_name (GtkAboutDialog *about); |
204 | GDK_AVAILABLE_IN_ALL |
205 | void gtk_about_dialog_set_logo_icon_name (GtkAboutDialog *about, |
206 | const gchar *icon_name); |
207 | GDK_AVAILABLE_IN_3_4 |
208 | void gtk_about_dialog_add_credit_section (GtkAboutDialog *about, |
209 | const gchar *section_name, |
210 | const gchar **people); |
211 | |
212 | G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkAboutDialog, g_object_unref) |
213 | |
214 | G_END_DECLS |
215 | |
216 | #endif /* __GTK_ABOUT_DIALOG_H__ */ |
217 | |
218 | |
219 | |