]> Pileus Git - ~andy/gtk/blob - gtk/gtkaboutdialog.h
gtk: Use const instead G_CONST_RETURN
[~andy/gtk] / gtk / gtkaboutdialog.h
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 the Gnome Library; see the file COPYING.LIB.  If not,
19    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20    Boston, MA 02111-1307, USA.
21
22    Author: Anders Carlsson <andersca@codefactory.se>
23 */
24
25 #if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
26 #error "Only <gtk/gtk.h> can be included directly."
27 #endif
28
29 #ifndef __GTK_ABOUT_DIALOG_H__
30 #define __GTK_ABOUT_DIALOG_H__
31
32 #include <gtk/gtkdialog.h>
33
34 G_BEGIN_DECLS
35
36 #define GTK_TYPE_ABOUT_DIALOG            (gtk_about_dialog_get_type ())
37 #define GTK_ABOUT_DIALOG(object)         (G_TYPE_CHECK_INSTANCE_CAST ((object), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialog))
38 #define GTK_ABOUT_DIALOG_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialogClass))
39 #define GTK_IS_ABOUT_DIALOG(object)      (G_TYPE_CHECK_INSTANCE_TYPE ((object), GTK_TYPE_ABOUT_DIALOG))
40 #define GTK_IS_ABOUT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ABOUT_DIALOG))
41 #define GTK_ABOUT_DIALOG_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_ABOUT_DIALOG, GtkAboutDialogClass))
42
43 typedef struct _GtkAboutDialog        GtkAboutDialog;
44 typedef struct _GtkAboutDialogClass   GtkAboutDialogClass;
45 typedef struct _GtkAboutDialogPrivate GtkAboutDialogPrivate;
46
47 /**
48  * GtkLicense:
49  * @GTK_LICENSE_UNKNOWN: No license specified
50  * @GTK_LICENSE_CUSTOM: A license text is going to be specified by the
51  *   developer
52  * @GTK_LICENSE_GPL_2_0: The GNU General Public License, version 2.0
53  * @GTK_LICENSE_GPL_3_0: The GNU General Public License, version 3.0
54  * @GTK_LICENSE_LGPL_2_1: The GNU Lesser General Public License, version 2.1
55  * @GTK_LICENSE_LGPL_3_0: The GNU Lesser General Public License, version 3.0
56  * @GTK_LICENSE_BSD: The BSD standard license
57  * @GTK_LICENSE_MIT_X11: The MIT/X11 standard license
58  * @GTK_LICENSE_ARTISTIC: The Artistic License, version 2.0
59  *
60  * The type of license for an application.
61  *
62  * This enumeration can be expanded at later date.
63  *
64  * Since: 3.0
65  */
66 typedef enum {
67   GTK_LICENSE_UNKNOWN,
68   GTK_LICENSE_CUSTOM,
69
70   GTK_LICENSE_GPL_2_0,
71   GTK_LICENSE_GPL_3_0,
72
73   GTK_LICENSE_LGPL_2_1,
74   GTK_LICENSE_LGPL_3_0,
75
76   GTK_LICENSE_BSD,
77   GTK_LICENSE_MIT_X11,
78
79   GTK_LICENSE_ARTISTIC
80 } GtkLicense;
81
82 /**
83  * GtkAboutDialog:
84  *
85  * The <structname>GtkAboutDialog</structname> struct contains
86  * only private fields and should not be directly accessed.
87  */
88 struct _GtkAboutDialog
89 {
90   GtkDialog parent_instance;
91
92   /*< private >*/
93   GtkAboutDialogPrivate *priv;
94 };
95
96 struct _GtkAboutDialogClass
97 {
98   GtkDialogClass parent_class;
99
100   gboolean (*activate_link) (GtkAboutDialog *dialog,
101                              const gchar    *uri);
102
103   /* Padding for future expansion */
104   void (*_gtk_reserved1) (void);
105   void (*_gtk_reserved2) (void);
106   void (*_gtk_reserved3) (void);
107   void (*_gtk_reserved4) (void);
108 };
109
110 GType                  gtk_about_dialog_get_type               (void) G_GNUC_CONST;
111 GtkWidget             *gtk_about_dialog_new                    (void);
112 void                   gtk_show_about_dialog                   (GtkWindow       *parent,
113                                                                 const gchar     *first_property_name,
114                                                                 ...) G_GNUC_NULL_TERMINATED;
115 const gchar *          gtk_about_dialog_get_program_name       (GtkAboutDialog  *about);
116 void                   gtk_about_dialog_set_program_name       (GtkAboutDialog  *about,
117                                                                 const gchar     *name);
118 const gchar *          gtk_about_dialog_get_version            (GtkAboutDialog  *about);
119 void                   gtk_about_dialog_set_version            (GtkAboutDialog  *about,
120                                                                 const gchar     *version);
121 const gchar *          gtk_about_dialog_get_copyright          (GtkAboutDialog  *about);
122 void                   gtk_about_dialog_set_copyright          (GtkAboutDialog  *about,
123                                                                 const gchar     *copyright);
124 const gchar *          gtk_about_dialog_get_comments           (GtkAboutDialog  *about);
125 void                   gtk_about_dialog_set_comments           (GtkAboutDialog  *about,
126                                                                 const gchar     *comments);
127 const gchar *          gtk_about_dialog_get_license            (GtkAboutDialog  *about);
128 void                   gtk_about_dialog_set_license            (GtkAboutDialog  *about,
129                                                                 const gchar     *license);
130 void                   gtk_about_dialog_set_license_type       (GtkAboutDialog  *about,
131                                                                 GtkLicense       license_type);
132 GtkLicense             gtk_about_dialog_get_license_type       (GtkAboutDialog  *about);
133
134 gboolean               gtk_about_dialog_get_wrap_license       (GtkAboutDialog  *about);
135 void                   gtk_about_dialog_set_wrap_license       (GtkAboutDialog  *about,
136                                                                 gboolean         wrap_license);
137
138 const gchar *          gtk_about_dialog_get_website            (GtkAboutDialog  *about);
139 void                   gtk_about_dialog_set_website            (GtkAboutDialog  *about,
140                                                                 const gchar     *website);
141 const gchar *          gtk_about_dialog_get_website_label      (GtkAboutDialog  *about);
142 void                   gtk_about_dialog_set_website_label      (GtkAboutDialog  *about,
143                                                                 const gchar     *website_label);
144 const gchar* const *   gtk_about_dialog_get_authors            (GtkAboutDialog  *about);
145 void                   gtk_about_dialog_set_authors            (GtkAboutDialog  *about,
146                                                                 const gchar    **authors);
147 const gchar* const *   gtk_about_dialog_get_documenters        (GtkAboutDialog  *about);
148 void                   gtk_about_dialog_set_documenters        (GtkAboutDialog  *about,
149                                                                 const gchar    **documenters);
150 const gchar* const *   gtk_about_dialog_get_artists            (GtkAboutDialog  *about);
151 void                   gtk_about_dialog_set_artists            (GtkAboutDialog  *about,
152                                                                 const gchar    **artists);
153 const gchar *          gtk_about_dialog_get_translator_credits (GtkAboutDialog  *about);
154 void                   gtk_about_dialog_set_translator_credits (GtkAboutDialog  *about,
155                                                                 const gchar     *translator_credits);
156 GdkPixbuf             *gtk_about_dialog_get_logo               (GtkAboutDialog  *about);
157 void                   gtk_about_dialog_set_logo               (GtkAboutDialog  *about,
158                                                                 GdkPixbuf       *logo);
159 const gchar *          gtk_about_dialog_get_logo_icon_name     (GtkAboutDialog  *about);
160 void                   gtk_about_dialog_set_logo_icon_name     (GtkAboutDialog  *about,
161                                                                 const gchar     *icon_name);
162
163 G_END_DECLS
164
165 #endif /* __GTK_ABOUT_DIALOG_H__ */
166
167