Revision 16298,
1.3 KB
checked in by ghudson, 24 years ago
(diff) |
This commit was generated by cvs2svn to compensate for changes in r16297,
which included commits to RCS files with non-trunk default branches.
|
Line | |
---|
1 | /* Scroll menu: a scrolling menu (if it's beyond screen size) |
---|
2 | * (C) 2000 Eazel, Inc. |
---|
3 | * |
---|
4 | * Authors: George Lebl |
---|
5 | */ |
---|
6 | #ifndef SCROLL_MENU_H |
---|
7 | #define SCROLL_MENU_H |
---|
8 | |
---|
9 | #include <gtk/gtk.h> |
---|
10 | |
---|
11 | #ifdef __cplusplus |
---|
12 | extern "C" { |
---|
13 | #endif |
---|
14 | |
---|
15 | #define TYPE_SCROLL_MENU (scroll_menu_get_type ()) |
---|
16 | #define SCROLL_MENU(obj) GTK_CHECK_CAST ((obj), scroll_menu_get_type (), ScrollMenu) |
---|
17 | #define SCROLL_MENU_CLASS(klass) GTK_CHECK_CLASS_CAST ((klass), scroll_menu_get_type (), ScrollMenuClass) |
---|
18 | #define IS_SCROLL_MENU(obj) GTK_CHECK_TYPE ((obj), scroll_menu_get_type ()) |
---|
19 | |
---|
20 | typedef struct _ScrollMenu ScrollMenu; |
---|
21 | typedef struct _ScrollMenuClass ScrollMenuClass; |
---|
22 | |
---|
23 | struct _ScrollMenu |
---|
24 | { |
---|
25 | GtkMenu menu; |
---|
26 | |
---|
27 | /*< private >*/ |
---|
28 | int offset; |
---|
29 | int max_offset; |
---|
30 | |
---|
31 | int screen_top; |
---|
32 | int screen_bottom; |
---|
33 | |
---|
34 | gboolean scroll; |
---|
35 | |
---|
36 | GtkWidget *up_scroll /* GtkButton */; |
---|
37 | GtkWidget *down_scroll /* GtkButton */; |
---|
38 | gboolean in_up; |
---|
39 | gboolean in_down; |
---|
40 | |
---|
41 | int scroll_by; |
---|
42 | guint scroll_timeout; |
---|
43 | }; |
---|
44 | |
---|
45 | struct _ScrollMenuClass |
---|
46 | { |
---|
47 | GtkMenuClass parent_class; |
---|
48 | }; |
---|
49 | |
---|
50 | GtkType scroll_menu_get_type (void) G_GNUC_CONST; |
---|
51 | GtkWidget * scroll_menu_new (void); |
---|
52 | void scroll_menu_set_screen_size (ScrollMenu *self, |
---|
53 | int screen_top, |
---|
54 | int screen_bottom); |
---|
55 | |
---|
56 | #ifdef __cplusplus |
---|
57 | } |
---|
58 | #endif |
---|
59 | |
---|
60 | #endif /* SCROLL_MENU_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.