1/* GTK - The GIMP Toolkit
2
3 Copyright (C) 2001 CodeFactory AB
4 Copyright (C) 2001 Anders Carlsson <andersca@codefactory.se>
5 Copyright (C) 2003, 2004 Matthias Clasen <mclasen@redhat.com>
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 <andersca@codefactory.se>
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
32G_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
41typedef struct _GtkAboutDialog GtkAboutDialog;
42typedef struct _GtkAboutDialogClass GtkAboutDialogClass;
43typedef 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 * @GTK_LICENSE_BSD_3: The 3-clause BSD licence. Since: 3.24.20.
64 * @GTK_LICENSE_APACHE_2_0: The Apache License, version 2.0. Since: 3.24.20.
65 * @GTK_LICENSE_MPL_2_0: The Mozilla Public License, version 2.0. Since: 3.24.20.
66 *
67 * The type of license for an application.
68 *
69 * This enumeration can be expanded at later date.
70 *
71 * Since: 3.0
72 */
73typedef enum {
74 GTK_LICENSE_UNKNOWN,
75 GTK_LICENSE_CUSTOM,
76
77 GTK_LICENSE_GPL_2_0,
78 GTK_LICENSE_GPL_3_0,
79
80 GTK_LICENSE_LGPL_2_1,
81 GTK_LICENSE_LGPL_3_0,
82
83 GTK_LICENSE_BSD,
84 GTK_LICENSE_MIT_X11,
85
86 GTK_LICENSE_ARTISTIC,
87
88 GTK_LICENSE_GPL_2_0_ONLY,
89 GTK_LICENSE_GPL_3_0_ONLY,
90 GTK_LICENSE_LGPL_2_1_ONLY,
91 GTK_LICENSE_LGPL_3_0_ONLY,
92
93 GTK_LICENSE_AGPL_3_0,
94 GTK_LICENSE_AGPL_3_0_ONLY,
95
96 GTK_LICENSE_BSD_3,
97 GTK_LICENSE_APACHE_2_0,
98 GTK_LICENSE_MPL_2_0
99} GtkLicense;
100
101/**
102 * GtkAboutDialog:
103 *
104 * The #GtkAboutDialog-struct contains
105 * only private fields and should not be directly accessed.
106 */
107struct _GtkAboutDialog
108{
109 GtkDialog parent_instance;
110
111 /*< private >*/
112 GtkAboutDialogPrivate *priv;
113};
114
115struct _GtkAboutDialogClass
116{
117 GtkDialogClass parent_class;
118
119 gboolean (*activate_link) (GtkAboutDialog *dialog,
120 const gchar *uri);
121
122 /* Padding for future expansion */
123 void (*_gtk_reserved1) (void);
124 void (*_gtk_reserved2) (void);
125 void (*_gtk_reserved3) (void);
126 void (*_gtk_reserved4) (void);
127};
128
129GDK_AVAILABLE_IN_ALL
130GType gtk_about_dialog_get_type (void) G_GNUC_CONST;
131GDK_AVAILABLE_IN_ALL
132GtkWidget *gtk_about_dialog_new (void);
133GDK_AVAILABLE_IN_ALL
134void gtk_show_about_dialog (GtkWindow *parent,
135 const gchar *first_property_name,
136 ...) G_GNUC_NULL_TERMINATED;
137GDK_AVAILABLE_IN_ALL
138const gchar * gtk_about_dialog_get_program_name (GtkAboutDialog *about);
139GDK_AVAILABLE_IN_ALL
140void gtk_about_dialog_set_program_name (GtkAboutDialog *about,
141 const gchar *name);
142GDK_AVAILABLE_IN_ALL
143const gchar * gtk_about_dialog_get_version (GtkAboutDialog *about);
144GDK_AVAILABLE_IN_ALL
145void gtk_about_dialog_set_version (GtkAboutDialog *about,
146 const gchar *version);
147GDK_AVAILABLE_IN_ALL
148const gchar * gtk_about_dialog_get_copyright (GtkAboutDialog *about);
149GDK_AVAILABLE_IN_ALL
150void gtk_about_dialog_set_copyright (GtkAboutDialog *about,
151 const gchar *copyright);
152GDK_AVAILABLE_IN_ALL
153const gchar * gtk_about_dialog_get_comments (GtkAboutDialog *about);
154GDK_AVAILABLE_IN_ALL
155void gtk_about_dialog_set_comments (GtkAboutDialog *about,
156 const gchar *comments);
157GDK_AVAILABLE_IN_ALL
158const gchar * gtk_about_dialog_get_license (GtkAboutDialog *about);
159GDK_AVAILABLE_IN_ALL
160void gtk_about_dialog_set_license (GtkAboutDialog *about,
161 const gchar *license);
162GDK_AVAILABLE_IN_ALL
163void gtk_about_dialog_set_license_type (GtkAboutDialog *about,
164 GtkLicense license_type);
165GDK_AVAILABLE_IN_ALL
166GtkLicense gtk_about_dialog_get_license_type (GtkAboutDialog *about);
167
168GDK_AVAILABLE_IN_ALL
169gboolean gtk_about_dialog_get_wrap_license (GtkAboutDialog *about);
170GDK_AVAILABLE_IN_ALL
171void gtk_about_dialog_set_wrap_license (GtkAboutDialog *about,
172 gboolean wrap_license);
173
174GDK_AVAILABLE_IN_ALL
175const gchar * gtk_about_dialog_get_website (GtkAboutDialog *about);
176GDK_AVAILABLE_IN_ALL
177void gtk_about_dialog_set_website (GtkAboutDialog *about,
178 const gchar *website);
179GDK_AVAILABLE_IN_ALL
180const gchar * gtk_about_dialog_get_website_label (GtkAboutDialog *about);
181GDK_AVAILABLE_IN_ALL
182void gtk_about_dialog_set_website_label (GtkAboutDialog *about,
183 const gchar *website_label);
184GDK_AVAILABLE_IN_ALL
185const gchar* const * gtk_about_dialog_get_authors (GtkAboutDialog *about);
186GDK_AVAILABLE_IN_ALL
187void gtk_about_dialog_set_authors (GtkAboutDialog *about,
188 const gchar **authors);
189GDK_AVAILABLE_IN_ALL
190const gchar* const * gtk_about_dialog_get_documenters (GtkAboutDialog *about);
191GDK_AVAILABLE_IN_ALL
192void gtk_about_dialog_set_documenters (GtkAboutDialog *about,
193 const gchar **documenters);
194GDK_AVAILABLE_IN_ALL
195const gchar* const * gtk_about_dialog_get_artists (GtkAboutDialog *about);
196GDK_AVAILABLE_IN_ALL
197void gtk_about_dialog_set_artists (GtkAboutDialog *about,
198 const gchar **artists);
199GDK_AVAILABLE_IN_ALL
200const gchar * gtk_about_dialog_get_translator_credits (GtkAboutDialog *about);
201GDK_AVAILABLE_IN_ALL
202void gtk_about_dialog_set_translator_credits (GtkAboutDialog *about,
203 const gchar *translator_credits);
204GDK_AVAILABLE_IN_ALL
205GdkPixbuf * (GtkAboutDialog *about);
206GDK_AVAILABLE_IN_ALL
207void (GtkAboutDialog *about,
208 GdkPixbuf *);
209GDK_AVAILABLE_IN_ALL
210const gchar * gtk_about_dialog_get_logo_icon_name (GtkAboutDialog *about);
211GDK_AVAILABLE_IN_ALL
212void gtk_about_dialog_set_logo_icon_name (GtkAboutDialog *about,
213 const gchar *icon_name);
214GDK_AVAILABLE_IN_3_4
215void gtk_about_dialog_add_credit_section (GtkAboutDialog *about,
216 const gchar *section_name,
217 const gchar **people);
218
219G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkAboutDialog, g_object_unref)
220
221G_END_DECLS
222
223#endif /* __GTK_ABOUT_DIALOG_H__ */
224
225
226

source code of include/gtk-3.0/gtk/gtkaboutdialog.h