goocanvas 1.1.5 → 1.1.6
Sign up to get free protection for your applications and to get access to all the features.
- data/ext/goocanvas/rbgoocanvas.c +62 -1
- metadata +24 -24
data/ext/goocanvas/rbgoocanvas.c
CHANGED
@@ -40,7 +40,7 @@ rg_initialize(VALUE self)
|
|
40
40
|
|
41
41
|
static VALUE
|
42
42
|
rg_set_bounds(VALUE self, VALUE left, VALUE top,
|
43
|
-
|
43
|
+
VALUE right, VALUE bottom)
|
44
44
|
{
|
45
45
|
goo_canvas_set_bounds(SELF(self), NUM2DBL(left), NUM2DBL(top),
|
46
46
|
NUM2DBL(right), NUM2DBL(bottom));
|
@@ -109,6 +109,61 @@ rg_scroll_to(VALUE self, VALUE left, VALUE top)
|
|
109
109
|
return self;
|
110
110
|
}
|
111
111
|
|
112
|
+
static VALUE
|
113
|
+
rg_update(VALUE self)
|
114
|
+
{
|
115
|
+
goo_canvas_update(SELF(self));
|
116
|
+
return self;
|
117
|
+
}
|
118
|
+
|
119
|
+
static VALUE
|
120
|
+
rg_request_update(VALUE self)
|
121
|
+
{
|
122
|
+
goo_canvas_request_update(SELF(self));
|
123
|
+
return self;
|
124
|
+
}
|
125
|
+
|
126
|
+
static VALUE
|
127
|
+
rg_convert_from_pixels(VALUE self, VALUE rb_x, VALUE rb_y)
|
128
|
+
{
|
129
|
+
double x = NUM2DBL(rb_x);
|
130
|
+
double y = NUM2DBL(rb_y);
|
131
|
+
goo_canvas_convert_from_pixels(SELF(self), &x, &y);
|
132
|
+
return rb_ary_new3(2, INT2NUM(x), INT2NUM(y));
|
133
|
+
}
|
134
|
+
|
135
|
+
static VALUE
|
136
|
+
rg_convert_to_pixels(VALUE self, VALUE rb_x, VALUE rb_y)
|
137
|
+
{
|
138
|
+
double x = NUM2DBL(rb_x);
|
139
|
+
double y = NUM2DBL(rb_y);
|
140
|
+
goo_canvas_convert_to_pixels(SELF(self), &x, &y);
|
141
|
+
return rb_ary_new3(2, INT2NUM(x), INT2NUM(y));
|
142
|
+
}
|
143
|
+
|
144
|
+
static VALUE
|
145
|
+
rg_get_item_at(VALUE self, VALUE x, VALUE y, VALUE b)
|
146
|
+
{
|
147
|
+
GooCanvasItem *item;
|
148
|
+
item = goo_canvas_get_item_at(SELF(self),
|
149
|
+
NUM2DBL(x),
|
150
|
+
NUM2DBL(y),
|
151
|
+
RVAL2CBOOL(b));
|
152
|
+
return GOBJ2RVAL(item);
|
153
|
+
}
|
154
|
+
|
155
|
+
static VALUE
|
156
|
+
rg_bounds(VALUE self)
|
157
|
+
{
|
158
|
+
double left, top, right, bottom;
|
159
|
+
goo_canvas_get_bounds(SELF(self),
|
160
|
+
&left,
|
161
|
+
&top,
|
162
|
+
&right,
|
163
|
+
&bottom);
|
164
|
+
return rb_ary_new3(4, INT2NUM(left), INT2NUM(top), INT2NUM(right), INT2NUM(bottom));
|
165
|
+
}
|
166
|
+
|
112
167
|
void
|
113
168
|
Init_goocanvas(void)
|
114
169
|
{
|
@@ -121,12 +176,18 @@ Init_goocanvas(void)
|
|
121
176
|
|
122
177
|
RG_DEF_METHOD(initialize, 0);
|
123
178
|
RG_DEF_METHOD(set_bounds, 4);
|
179
|
+
RG_DEF_METHOD(bounds, 0);
|
124
180
|
RG_DEF_METHOD(root_item, 0);
|
125
181
|
RG_DEF_METHOD(grab_focus, -1);
|
126
182
|
RG_DEF_METHOD(pointer_grab, 4);
|
127
183
|
RG_DEF_METHOD(pointer_ungrab, 2);
|
128
184
|
RG_DEF_METHOD(render, 3);
|
129
185
|
RG_DEF_METHOD(scroll_to, 2);
|
186
|
+
RG_DEF_METHOD(update, 0);
|
187
|
+
RG_DEF_METHOD(request_update, 0);
|
188
|
+
RG_DEF_METHOD(convert_from_pixels, 2);
|
189
|
+
RG_DEF_METHOD(convert_to_pixels, 2);
|
190
|
+
RG_DEF_METHOD(get_item_at, 3);
|
130
191
|
|
131
192
|
Init_goocanvasitem(mGoo); /* Goo::CanvasItem */
|
132
193
|
Init_goocanvastext(mGoo); /* Goo::CanvasText */
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: goocanvas
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.6
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-
|
12
|
+
date: 2012-12-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: gtk2
|
@@ -18,7 +18,7 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: 1.1.
|
21
|
+
version: 1.1.6
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -26,7 +26,7 @@ dependencies:
|
|
26
26
|
requirements:
|
27
27
|
- - ! '>='
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 1.1.
|
29
|
+
version: 1.1.6
|
30
30
|
description: Ruby/GooCanvas is a Ruby binding of GooCanvas.
|
31
31
|
email: ruby-gnome2-devel-en@lists.sourceforge.net
|
32
32
|
executables: []
|
@@ -38,39 +38,39 @@ files:
|
|
38
38
|
- Rakefile
|
39
39
|
- extconf.rb
|
40
40
|
- lib/goocanvas.rb
|
41
|
+
- ext/goocanvas/depend
|
42
|
+
- ext/goocanvas/extconf.rb
|
43
|
+
- ext/goocanvas/goocanvas.def
|
44
|
+
- ext/goocanvas/rbgoo.c
|
41
45
|
- ext/goocanvas/rbgoocairomatrix.c
|
42
|
-
- ext/goocanvas/rbgoocanvastext.c
|
43
46
|
- ext/goocanvas/rbgoocairopattern.c
|
47
|
+
- ext/goocanvas/rbgoocanvas.c
|
48
|
+
- ext/goocanvas/rbgoocanvas.h
|
44
49
|
- ext/goocanvas/rbgoocanvasconversions.h
|
50
|
+
- ext/goocanvas/rbgoocanvasellipse.c
|
51
|
+
- ext/goocanvas/rbgoocanvasgroup.c
|
45
52
|
- ext/goocanvas/rbgoocanvasimage.c
|
46
|
-
- ext/goocanvas/
|
47
|
-
- ext/goocanvas/rbgooutils.c
|
48
|
-
- ext/goocanvas/rbgoocanvas.c
|
49
|
-
- ext/goocanvas/rbgoocanvaspolyline.c
|
53
|
+
- ext/goocanvas/rbgoocanvasitem.c
|
50
54
|
- ext/goocanvas/rbgoocanvaspoints.c
|
51
|
-
- ext/goocanvas/
|
55
|
+
- ext/goocanvas/rbgoocanvaspolyline.c
|
52
56
|
- ext/goocanvas/rbgoocanvasprivate.h
|
53
|
-
- ext/goocanvas/goocanvas.def
|
54
|
-
- ext/goocanvas/rbgoo.c
|
55
57
|
- ext/goocanvas/rbgoocanvasrect.c
|
56
|
-
- ext/goocanvas/rbgoocanvasellipse.c
|
57
|
-
- ext/goocanvas/rbgoocanvasitem.c
|
58
58
|
- ext/goocanvas/rbgoocanvasstyle.c
|
59
|
+
- ext/goocanvas/rbgoocanvastable.c
|
60
|
+
- ext/goocanvas/rbgoocanvastext.c
|
59
61
|
- ext/goocanvas/rbgoocanvaswidget.c
|
60
|
-
- ext/goocanvas/
|
61
|
-
-
|
62
|
-
- ext/goocanvas/rbgoocanvasgroup.c
|
63
|
-
- sample/toroid.png
|
64
|
-
- sample/flower.png
|
62
|
+
- ext/goocanvas/rbgooutils.c
|
63
|
+
- sample/demo-arrowhead.rb
|
65
64
|
- sample/demo-fifteen.rb
|
66
|
-
- sample/table-demo.rb
|
67
|
-
- sample/demo.rb
|
68
|
-
- sample/widgets-demo.rb
|
69
65
|
- sample/demo-primitives.rb
|
70
|
-
- sample/demo
|
66
|
+
- sample/demo.rb
|
67
|
+
- sample/flower.png
|
71
68
|
- sample/scalability-demo.rb
|
72
|
-
- sample/units-demo.rb
|
73
69
|
- sample/simple-demo.rb
|
70
|
+
- sample/table-demo.rb
|
71
|
+
- sample/toroid.png
|
72
|
+
- sample/units-demo.rb
|
73
|
+
- sample/widgets-demo.rb
|
74
74
|
homepage: http://ruby-gnome2.sourceforge.jp/
|
75
75
|
licenses: []
|
76
76
|
post_install_message: This library is experimental.
|