1 // gnash-canvas.h: Gtk canvas widget for gnash
3 // Copyright (C) 2009, 2010 Free Software Foundation, Inc.
5 // This program is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation; either version 3 of the License, or
8 // (at your option) any later version.
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software
17 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20 #ifndef GNASH_GTK_CANVAS_H
21 #define GNASH_GTK_CANVAS_H
24 #include <gtk/gtkdrawingarea.h>
25 #include <boost/shared_ptr.hpp>
27 // Forward declarations.
34 typedef struct _GnashCanvas GnashCanvas
;
35 typedef struct _GnashCanvasClass GnashCanvasClass
;
37 #define GNASH_TYPE_CANVAS (gnash_canvas_get_type())
38 #define GNASH_CANVAS(object) (G_TYPE_CHECK_INSTANCE_CAST((object), GNASH_TYPE_CANVAS, GnashCanvas))
39 #define GNASH_CANVAS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), GNASH_TYPE_CANVAS, GnashCanvasClass))
40 #define GNASH_IS_CANVAS(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), GNASH_TYPE_CANVAS))
41 #define GNASH_IS_CANVAS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), GNASH_TYPE_CANVAS))
42 #define GNASH_CANVAS_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), GNASH_TYPE_CANVAS, GnashCanvasClass))
44 struct _GnashCanvasClass
{
45 GtkDrawingAreaClass base_class
;
48 GType
gnash_canvas_get_type ();
49 GtkWidget
*gnash_canvas_new ();
51 void gnash_canvas_setup (GnashCanvas
*canvas
, std::string
&hwaccel
, std::string
&renderer
, int argc
, char **argv
[]);
52 void gnash_canvas_before_rendering (GnashCanvas
*canvas
);
53 boost::shared_ptr
<gnash::Renderer
> gnash_canvas_get_renderer (GnashCanvas
*canvas
);
61 // indent-tabs-mode: nil