Github User Fetcher 1.0.0
C Application with Server and GUI
Loading...
Searching...
No Matches
gtkassistant.h
Go to the documentation of this file.
1/*
2 * GTK - The GIMP Toolkit
3 * Copyright (C) 1999 Red Hat, Inc.
4 * Copyright (C) 2002 Anders Carlsson <andersca@gnu.org>
5 * Copyright (C) 2003 Matthias Clasen <mclasen@redhat.com>
6 * Copyright (C) 2005 Carlos Garnacho Parro <carlosg@gnome.org>
7 *
8 * All rights reserved.
9 *
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation; either
13 * version 2 of the License, or (at your option) any later version.
14 *
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
22 */
23
24#pragma once
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/gtkwindow.h>
31
33
34#define GTK_TYPE_ASSISTANT (gtk_assistant_get_type ())
35#define GTK_ASSISTANT(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GTK_TYPE_ASSISTANT, GtkAssistant))
36#define GTK_IS_ASSISTANT(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GTK_TYPE_ASSISTANT))
37
38/**
39 * GtkAssistantPageType:
40 * @GTK_ASSISTANT_PAGE_CONTENT: The page has regular contents. Both the
41 * Back and forward buttons will be shown.
42 * @GTK_ASSISTANT_PAGE_INTRO: The page contains an introduction to the
43 * assistant task. Only the Forward button will be shown if there is a
44 * next page.
45 * @GTK_ASSISTANT_PAGE_CONFIRM: The page lets the user confirm or deny the
46 * changes. The Back and Apply buttons will be shown.
47 * @GTK_ASSISTANT_PAGE_SUMMARY: The page informs the user of the changes
48 * done. Only the Close button will be shown.
49 * @GTK_ASSISTANT_PAGE_PROGRESS: Used for tasks that take a long time to
50 * complete, blocks the assistant until the page is marked as complete.
51 * Only the back button will be shown.
52 * @GTK_ASSISTANT_PAGE_CUSTOM: Used for when other page types are not
53 * appropriate. No buttons will be shown, and the application must
54 * add its own buttons through gtk_assistant_add_action_widget().
55 *
56 * Determines the page role inside a `GtkAssistant`.
57 *
58 * The role is used to handle buttons sensitivity and visibility.
59 *
60 * Note that an assistant needs to end its page flow with a page of type
61 * %GTK_ASSISTANT_PAGE_CONFIRM, %GTK_ASSISTANT_PAGE_SUMMARY or
62 * %GTK_ASSISTANT_PAGE_PROGRESS to be correct.
63 *
64 * The Cancel button will only be shown if the page isn’t “committed”.
65 * See gtk_assistant_commit() for details.
66 */
76
77typedef struct _GtkAssistant GtkAssistant;
78
79#define GTK_TYPE_ASSISTANT_PAGE (gtk_assistant_page_get_type ())
80#define GTK_ASSISTANT_PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_ASSISTANT_PAGE, GtkAssistantPage))
81#define GTK_IS_ASSISTANT_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_ASSISTANT_PAGE))
82
83typedef struct _GtkAssistantPage GtkAssistantPage;
84
85/**
86 * GtkAssistantPageFunc:
87 * @current_page: The page number used to calculate the next page.
88 * @data: (closure): user data.
89 *
90 * Type of callback used to calculate the next page in a `GtkAssistant`.
91 *
92 * It’s called both for computing the next page when the user presses the
93 * “forward” button and for handling the behavior of the “last” button.
94 *
95 * See [method@Gtk.Assistant.set_forward_page_func].
96 *
97 * Returns: The next page number
98 */
99typedef int (*GtkAssistantPageFunc) (int current_page, gpointer data);
100
115 int page_num);
120 int page_num);
123 GtkWidget *page);
126 GtkWidget *page);
129 GtkWidget *page,
130 int position);
133 int page_num);
136 GtkAssistantPageFunc page_func,
137 gpointer data,
138 GDestroyNotify destroy);
141 GtkWidget *page,
145 GtkWidget *page);
148 GtkWidget *page,
149 const char *title);
152 GtkWidget *page);
153
156 GtkWidget *page,
157 gboolean complete);
160 GtkWidget *page);
163 GtkWidget *child);
166 GtkWidget *child);
167
172
175 GtkWidget *child);
178
180GListModel * gtk_assistant_get_pages (GtkAssistant *assistant);
181
183
185
#define GDK_DEPRECATED_IN_4_10
#define GDK_AVAILABLE_IN_ALL
#define G_END_DECLS
Definition gmacros.h:910
#define G_BEGIN_DECLS
Definition gmacros.h:909
#define G_GNUC_CONST
Definition gmacros.h:637
#define G_DEFINE_AUTOPTR_CLEANUP_FUNC(TypeName, func)
Definition gmacros.h:1400
GOBJECT_AVAILABLE_IN_ALL void g_object_unref(gpointer object)
GDK_AVAILABLE_IN_ALL GType gtk_assistant_page_get_type(void) G_GNUC_CONST
GDK_AVAILABLE_IN_ALL GType gtk_assistant_get_type(void) G_GNUC_CONST
GDK_DEPRECATED_IN_4_10 const char * gtk_assistant_get_page_title(GtkAssistant *assistant, GtkWidget *page)
GDK_DEPRECATED_IN_4_10 int gtk_assistant_get_current_page(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 GtkWidget * gtk_assistant_new(void)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_set_page_title(GtkAssistant *assistant, GtkWidget *page, const char *title)
GtkAssistantPageType
@ GTK_ASSISTANT_PAGE_CUSTOM
@ GTK_ASSISTANT_PAGE_CONFIRM
@ GTK_ASSISTANT_PAGE_SUMMARY
@ GTK_ASSISTANT_PAGE_PROGRESS
@ GTK_ASSISTANT_PAGE_INTRO
@ GTK_ASSISTANT_PAGE_CONTENT
GDK_DEPRECATED_IN_4_10 void gtk_assistant_set_page_type(GtkAssistant *assistant, GtkWidget *page, GtkAssistantPageType type)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_add_action_widget(GtkAssistant *assistant, GtkWidget *child)
GDK_DEPRECATED_IN_4_10 GtkAssistantPageType gtk_assistant_get_page_type(GtkAssistant *assistant, GtkWidget *page)
GDK_DEPRECATED_IN_4_10 int gtk_assistant_prepend_page(GtkAssistant *assistant, GtkWidget *page)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_previous_page(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 gboolean gtk_assistant_get_page_complete(GtkAssistant *assistant, GtkWidget *page)
GDK_DEPRECATED_IN_4_10 GtkWidget * gtk_assistant_page_get_child(GtkAssistantPage *page)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_remove_action_widget(GtkAssistant *assistant, GtkWidget *child)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_commit(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 GListModel * gtk_assistant_get_pages(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_set_page_complete(GtkAssistant *assistant, GtkWidget *page, gboolean complete)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_remove_page(GtkAssistant *assistant, int page_num)
GDK_DEPRECATED_IN_4_10 GtkWidget * gtk_assistant_get_nth_page(GtkAssistant *assistant, int page_num)
GDK_DEPRECATED_IN_4_10 GtkAssistantPage * gtk_assistant_get_page(GtkAssistant *assistant, GtkWidget *child)
GDK_DEPRECATED_IN_4_10 int gtk_assistant_get_n_pages(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_set_forward_page_func(GtkAssistant *assistant, GtkAssistantPageFunc page_func, gpointer data, GDestroyNotify destroy)
GDK_DEPRECATED_IN_4_10 int gtk_assistant_insert_page(GtkAssistant *assistant, GtkWidget *page, int position)
GDK_DEPRECATED_IN_4_10 int gtk_assistant_append_page(GtkAssistant *assistant, GtkWidget *page)
struct _GtkAssistantPage GtkAssistantPage
GDK_DEPRECATED_IN_4_10 void gtk_assistant_set_current_page(GtkAssistant *assistant, int page_num)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_update_buttons_state(GtkAssistant *assistant)
GDK_DEPRECATED_IN_4_10 void gtk_assistant_next_page(GtkAssistant *assistant)
struct _GtkAssistant GtkAssistant
int(* GtkAssistantPageFunc)(int current_page, gpointer data)
gsize GType
Definition gtype.h:427
gint gboolean
Definition gtypes.h:56
void * gpointer
Definition gtypes.h:109
void(* GDestroyNotify)(gpointer data)
Definition gtypes.h:140