1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ |
---|
2 | /** |
---|
3 | * bonobo-view.h: a view object of an embeddable |
---|
4 | * |
---|
5 | * Authors: |
---|
6 | * Miguel de Icaza (miguel@kernel.org) |
---|
7 | * Nat Friedman (nat@nat.org) |
---|
8 | * |
---|
9 | * Copyright 1999 Helix Code, Inc. |
---|
10 | */ |
---|
11 | #ifndef _BONOBO_VIEW_H_ |
---|
12 | #define _BONOBO_VIEW_H_ |
---|
13 | |
---|
14 | #include <libgnome/gnome-defs.h> |
---|
15 | #include <bonobo/bonobo-control.h> |
---|
16 | #include <bonobo/bonobo-view-frame.h> |
---|
17 | |
---|
18 | BEGIN_GNOME_DECLS |
---|
19 | |
---|
20 | #define BONOBO_VIEW_TYPE (bonobo_view_get_type ()) |
---|
21 | #define BONOBO_VIEW(o) (GTK_CHECK_CAST ((o), BONOBO_VIEW_TYPE, BonoboView)) |
---|
22 | #define BONOBO_VIEW_CLASS(k) (GTK_CHECK_CLASS_CAST((k), BONOBO_VIEW_TYPE, BonoboViewClass)) |
---|
23 | #define BONOBO_IS_VIEW(o) (GTK_CHECK_TYPE ((o), BONOBO_VIEW_TYPE)) |
---|
24 | #define BONOBO_IS_VIEW_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), BONOBO_VIEW_TYPE)) |
---|
25 | |
---|
26 | typedef struct _BonoboView BonoboView; |
---|
27 | typedef struct _BonoboViewPrivate BonoboViewPrivate; |
---|
28 | |
---|
29 | #include <bonobo/bonobo-embeddable.h> |
---|
30 | |
---|
31 | #define BONOBO_VIEW_VERB_FUNC(fn) ((BonoboViewVerbFunc)(fn)) |
---|
32 | typedef void (*BonoboViewVerbFunc)(BonoboView *view, const char *verb_name, void *user_data); |
---|
33 | |
---|
34 | struct _BonoboView { |
---|
35 | BonoboControl base; |
---|
36 | |
---|
37 | BonoboEmbeddable *embeddable; |
---|
38 | Bonobo_ViewFrame view_frame; |
---|
39 | BonoboViewPrivate *priv; |
---|
40 | }; |
---|
41 | |
---|
42 | typedef struct { |
---|
43 | BonoboControlClass parent_class; |
---|
44 | |
---|
45 | POA_Bonobo_View__epv epv; |
---|
46 | |
---|
47 | /* Signals */ |
---|
48 | void (*do_verb) (BonoboView *view, |
---|
49 | const CORBA_char *verb_name); |
---|
50 | void (*set_zoom_factor) (BonoboView *view, double zoom); |
---|
51 | |
---|
52 | } BonoboViewClass; |
---|
53 | |
---|
54 | GtkType bonobo_view_get_type (void); |
---|
55 | BonoboView *bonobo_view_construct (BonoboView *view, |
---|
56 | GtkWidget *widget); |
---|
57 | BonoboView *bonobo_view_new (GtkWidget *widget); |
---|
58 | void bonobo_view_set_embeddable (BonoboView *view, |
---|
59 | BonoboEmbeddable *embeddable); |
---|
60 | BonoboEmbeddable *bonobo_view_get_embeddable (BonoboView *view); |
---|
61 | void bonobo_view_set_view_frame (BonoboView *view, |
---|
62 | Bonobo_ViewFrame view_frame); |
---|
63 | Bonobo_ViewFrame bonobo_view_get_view_frame (BonoboView *view); |
---|
64 | Bonobo_UIContainer bonobo_view_get_remote_ui_container(BonoboView *view); |
---|
65 | BonoboUIComponent *bonobo_view_get_ui_component (BonoboView *view); |
---|
66 | void bonobo_view_activate_notify (BonoboView *view, |
---|
67 | gboolean activated); |
---|
68 | |
---|
69 | END_GNOME_DECLS |
---|
70 | |
---|
71 | #endif /* _BONOBO_VIEW_H_ */ |
---|