source: trunk/third/gtk/gtk/gtkprogressbar.h @ 14482

Revision 14482, 3.3 KB checked in by ghudson, 24 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r14481, which included commits to RCS files with non-trunk default branches.
Line 
1/* GTK - The GIMP Toolkit
2 * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12 * Library General Public License for more details.
13 *
14 * You should have received a copy of the GNU Library General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
18 */
19
20/*
21 * Modified by the GTK+ Team and others 1997-1999.  See the AUTHORS
22 * file for a list of people on the GTK+ Team.  See the ChangeLog
23 * files for a list of changes.  These files are distributed with
24 * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
25 */
26
27#ifndef __GTK_PROGRESS_BAR_H__
28#define __GTK_PROGRESS_BAR_H__
29
30
31#include <gdk/gdk.h>
32#include <gtk/gtkprogress.h>
33
34
35#ifdef __cplusplus
36extern "C" {
37#endif /* __cplusplus */
38
39
40#define GTK_TYPE_PROGRESS_BAR            (gtk_progress_bar_get_type ())
41#define GTK_PROGRESS_BAR(obj)            (GTK_CHECK_CAST ((obj), GTK_TYPE_PROGRESS_BAR, GtkProgressBar))
42#define GTK_PROGRESS_BAR_CLASS(klass)    (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PROGRESS_BAR, GtkProgressBarClass))
43#define GTK_IS_PROGRESS_BAR(obj)         (GTK_CHECK_TYPE ((obj), GTK_TYPE_PROGRESS_BAR))
44#define GTK_IS_PROGRESS_BAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PROGRESS_BAR))
45
46
47typedef struct _GtkProgressBar       GtkProgressBar;
48typedef struct _GtkProgressBarClass  GtkProgressBarClass;
49
50typedef enum
51{
52  GTK_PROGRESS_CONTINUOUS,
53  GTK_PROGRESS_DISCRETE
54} GtkProgressBarStyle;
55
56typedef enum
57{
58  GTK_PROGRESS_LEFT_TO_RIGHT,
59  GTK_PROGRESS_RIGHT_TO_LEFT,
60  GTK_PROGRESS_BOTTOM_TO_TOP,
61  GTK_PROGRESS_TOP_TO_BOTTOM
62} GtkProgressBarOrientation;
63
64struct _GtkProgressBar
65{
66  GtkProgress progress;
67
68  GtkProgressBarStyle bar_style;
69  GtkProgressBarOrientation orientation;
70
71  guint blocks;
72  gint  in_block;
73
74  gint  activity_pos;
75  guint activity_step;
76  guint activity_blocks;
77  guint activity_dir : 1;
78};
79
80struct _GtkProgressBarClass
81{
82  GtkProgressClass parent_class;
83};
84
85
86GtkType    gtk_progress_bar_get_type             (void);
87GtkWidget* gtk_progress_bar_new                  (void);
88GtkWidget* gtk_progress_bar_new_with_adjustment  (GtkAdjustment  *adjustment);
89void       gtk_progress_bar_set_bar_style        (GtkProgressBar *pbar,
90                                                  GtkProgressBarStyle style);
91void       gtk_progress_bar_set_discrete_blocks  (GtkProgressBar *pbar,
92                                                  guint           blocks);
93void       gtk_progress_bar_set_activity_step    (GtkProgressBar *pbar,
94                                                  guint           step);
95void       gtk_progress_bar_set_activity_blocks  (GtkProgressBar *pbar,
96                                                  guint           blocks);
97void       gtk_progress_bar_set_orientation      (GtkProgressBar *pbar,
98                                                  GtkProgressBarOrientation orientation);
99void       gtk_progress_bar_update               (GtkProgressBar *pbar,
100                                                  gfloat          percentage);
101
102
103#ifdef __cplusplus
104}
105#endif /* __cplusplus */
106
107
108#endif /* __GTK_PROGRESS_BAR_H__ */
Note: See TracBrowser for help on using the repository browser.