src/rb_cairo.c in cairo-1.4.1 vs src/rb_cairo.c in cairo-1.5.0

- old
+ new

@@ -1,11 +1,11 @@ /* -*- c-file-style: "gnu"; indent-tabs-mode: nil -*- */ /* * Ruby Cairo Binding * * $Author: kou $ - * $Date: 2007/03/10 11:54:17 $ + * $Date: 2007/05/23 02:26:24 $ * * Copyright 2006-2007 Kouhei Sutou <kou@cozmixng.org> * Copyright 2005 Øyvind Kolås <pippin@freedesktop.org> * Copyright 2004-2005 MenTaLguY <mental@rydia.com> * @@ -13,27 +13,14 @@ * */ #include "rb_cairo.h" +#include "rb_cairo_private.h" -VALUE rb_mCairo; +VALUE rb_mCairo, rb_mCairo_Color, rb_cCairo_Color_Base; -extern void Init_cairo_context (void); -extern void Init_cairo_path (void); -extern void Init_cairo_matrix (void); -extern void Init_cairo_surface (void); -extern void Init_cairo_constants (void); -extern void Init_cairo_exception (void); -extern void Init_cairo_font (void); -extern void Init_cairo_font_extents (void); -extern void Init_cairo_font_options (void); -extern void Init_cairo_scaled_font (void); -extern void Init_cairo_text_extents (void); -extern void Init_cairo_pattern (void); -extern void Init_cairo_glyph (void); - static ID id__add_one_arg_setter; void rb_cairo_def_setters (VALUE klass) { @@ -69,11 +56,15 @@ rb_define_const (rb_mCairo, "MINOR_VERSION", INT2FIX (minor)); rb_define_const (rb_mCairo, "MICRO_VERSION", INT2FIX (micro)); rb_define_const (rb_mCairo, "BINDINGS_VERSION", rb_ary_new3 (4, - INT2FIX (1), INT2FIX (4), INT2FIX (1), Qnil)); + INT2FIX (1), INT2FIX (5), INT2FIX (0), Qnil)); + rb_mCairo_Color = rb_const_get (rb_mCairo, rb_intern ("Color")); + rb_cCairo_Color_Base = rb_const_get (rb_mCairo_Color, rb_intern ("Base")); + + Init_cairo_private (); Init_cairo_constants (); Init_cairo_context (); Init_cairo_path (); Init_cairo_matrix ();