r34887 - in /branches/upstream/libgoo-canvas-perl/current: Changes META.yml README lib/Goo/Canvas.pm t/Goo-Canvas.t xs/goocanvas.xs

ryan52-guest at users.alioth.debian.org ryan52-guest at users.alioth.debian.org
Thu May 7 02:55:03 UTC 2009


Author: ryan52-guest
Date: Thu May  7 02:54:54 2009
New Revision: 34887

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=34887
Log:
[svn-upgrade] Integrating new upstream version, libgoo-canvas-perl (0.06)

Modified:
    branches/upstream/libgoo-canvas-perl/current/Changes
    branches/upstream/libgoo-canvas-perl/current/META.yml
    branches/upstream/libgoo-canvas-perl/current/README
    branches/upstream/libgoo-canvas-perl/current/lib/Goo/Canvas.pm
    branches/upstream/libgoo-canvas-perl/current/t/Goo-Canvas.t
    branches/upstream/libgoo-canvas-perl/current/xs/goocanvas.xs

Modified: branches/upstream/libgoo-canvas-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/Changes?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/Changes (original)
+++ branches/upstream/libgoo-canvas-perl/current/Changes Thu May  7 02:54:54 2009
@@ -13,4 +13,9 @@
 0.05  Sun Nov  4 14:25:34 2007
     - Fix get_bounds error
     - Add bin/perltetris.pl
-    - Add bin/perlmine.pl
+    - Add bin/perlmine.pl
+
+0.06  Wed, 06 May 2009 22:00:39 -0400
+    - Add Goo:Canvas::get_items_at and Goo::Canvas::get_items_in_area.
+    Thanks to Jeffrey Ratcliffe!
+

Modified: branches/upstream/libgoo-canvas-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/META.yml?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/META.yml (original)
+++ branches/upstream/libgoo-canvas-perl/current/META.yml Thu May  7 02:54:54 2009
@@ -1,15 +1,17 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
-name:         Goo-Canvas
-version:      0.05
-version_from: lib/Goo/Canvas.pm
-installdirs:  site
-requires:
+--- #YAML:1.0
+name:                Goo-Canvas
+version:             0.06
+abstract:            Perl interface to the GooCanvas
+license:             ~
+author:              ~
+generated_by:        ExtUtils::MakeMaker version 6.42
+distribution_type:   module
+requires:     
     Cairo:                         1.00
     ExtUtils::Depends:             0.2
     ExtUtils::PkgConfig:           1.0
     Glib:                          1.103
     Gtk2:                          1.100
-
-distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.30_01
+meta-spec:
+    url:     http://module-build.sourceforge.net/META-spec-v1.3.html
+    version: 1.3

Modified: branches/upstream/libgoo-canvas-perl/current/README
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/README?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/README (original)
+++ branches/upstream/libgoo-canvas-perl/current/README Thu May  7 02:54:54 2009
@@ -1,7 +1,7 @@
-Goo-Canvas version 0.04
+Goo-Canvas version 0.05
 =======================
 
-Perl bindings to the goocanvas-0.9. For goocanvas-0.6, please use
+Perl bindings to the goocanvas-0.9+. For goocanvas-0.6, please use
 Goo-Canvas version 0.03.
 
 INSTALLATION
@@ -21,7 +21,7 @@
   Cairo >= 1.00 (perl module and requisite C libraries)
   Glib >= 1.103 (perl module and requisite C libraries)
   Gtk2 >= 1.100 (perl module and requisite C libraries)
-  goocanvas-0.9
+  goocanvas-0.9+
 
 
 COPYRIGHT AND LICENCE

Modified: branches/upstream/libgoo-canvas-perl/current/lib/Goo/Canvas.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/lib/Goo/Canvas.pm?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/lib/Goo/Canvas.pm (original)
+++ branches/upstream/libgoo-canvas-perl/current/lib/Goo/Canvas.pm Thu May  7 02:54:54 2009
@@ -26,7 +26,7 @@
 	
 );
 
-our $VERSION = '0.05';
+our $VERSION = '0.06';
 
 require XSLoader;
 XSLoader::load('Goo::Canvas', $VERSION);

Modified: branches/upstream/libgoo-canvas-perl/current/t/Goo-Canvas.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/t/Goo-Canvas.t?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/t/Goo-Canvas.t (original)
+++ branches/upstream/libgoo-canvas-perl/current/t/Goo-Canvas.t Thu May  7 02:54:54 2009
@@ -6,7 +6,7 @@
 
 # change 'tests => 1' to 'tests => last_test_to_print';
 
-use Test::More tests => 1;
+use Test::More tests => 2;
 BEGIN { use_ok('Goo::Canvas') };
 use lib qw(../blib/lib ../blib/arch);
 
@@ -14,3 +14,5 @@
 
 # Insert your test code below, the Test::More module is use()ed here so read
 # its man page ( perldoc Test::More ) for help writing this test script.
+
+can_ok('Goo::Canvas', qw(get_items_at get_items_in_area));

Modified: branches/upstream/libgoo-canvas-perl/current/xs/goocanvas.xs
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libgoo-canvas-perl/current/xs/goocanvas.xs?rev=34887&op=diff
==============================================================================
--- branches/upstream/libgoo-canvas-perl/current/xs/goocanvas.xs (original)
+++ branches/upstream/libgoo-canvas-perl/current/xs/goocanvas.xs Thu May  7 02:54:54 2009
@@ -6,20 +6,20 @@
     use Goo::Canvas;
     use Gtk2 '-init';
     use Glib qw(TRUE FALSE);
-    
+
     my $window = Gtk2::Window->new('toplevel');
     $window->signal_connect('delete_event' => sub { Gtk2->main_quit; });
     $window->set_default_size(640, 600);
-    
+
     my $swin = Gtk2::ScrolledWindow->new;
     $swin->set_shadow_type('in');
     $window->add($swin);
-    
+
     my $canvas = Goo::Canvas->new();
     $canvas->set_size_request(600, 450);
     $canvas->set_bounds(0, 0, 1000, 1000);
     $swin->add($canvas);
-    
+
     my $root = $canvas->get_root_item();
     my $rect = Goo::Canvas::Rect->new(
         $root, 100, 100, 400, 400,
@@ -31,7 +31,7 @@
     );
     $rect->signal_connect('button-press-event',
                           \&on_rect_button_press);
-    
+
     my $text = Goo::Canvas::Text->new(
         $root, "Hello World", 300, 300, -1, 'center',
         'font' => 'Sans 24',
@@ -39,7 +39,7 @@
     $text->rotate(45, 300, 300);
     $window->show_all();
     Gtk2->main;
-    
+
     sub on_rect_button_press {
         print "Rect item pressed!\n";
         return TRUE;
@@ -47,8 +47,8 @@
 
 =head1 DESCRIPTION
 
-GTK+ does't has an buildin canvas widget. GooCanvas is wonderful.
-It is easy to use and has powerful and extensible way to create items
+GTK+ doesn't has an built-in canvas widget. GooCanvas is wonderful.
+It is easy to use and has powerful and extensible methods to create items
 in canvas. Just try it.
 
 For more documents, please read GooCanvas Manual and the demo programs
@@ -56,7 +56,7 @@
 GooCanvas.
 
 =cut
-    
+
 GtkWidget*
 goo_canvas_new(class)
     C_ARGS:
@@ -123,6 +123,47 @@
     gdouble x
     gdouble y
     gboolean is_pointer_event
+
+AV*
+goo_canvas_get_items_at(canvas, x, y, is_pointer_event)
+    GooCanvas *canvas
+    gdouble x
+    gdouble y
+    gboolean is_pointer_event
+  PREINIT:
+    GList *list, *i;
+  CODE:
+    list = goo_canvas_get_items_at(canvas, x, y, is_pointer_event);
+    RETVAL = newAV();
+    for ( i = list; i != NULL; i = i->next ) {
+        av_push(RETVAL, newSVGooCanvasItem((GooCanvasItem*)i->data));
+    }
+    sv_2mortal((SV*)RETVAL);
+  OUTPUT:
+    RETVAL
+  CLEANUP:
+    g_list_free (list);
+
+AV*
+goo_canvas_get_items_in_area(canvas, area, inside_area, allow_overlaps, include_containers)
+    GooCanvas *canvas
+    GooCanvasBounds *area
+    gboolean inside_area
+    gboolean allow_overlaps
+    gboolean include_containers
+  PREINIT:
+    GList *list, *i;
+  CODE:
+    list = goo_canvas_get_items_in_area(canvas, area, inside_area, allow_overlaps, include_containers);
+    RETVAL = newAV();
+    for ( i = list; i != NULL; i = i->next ) {
+        av_push(RETVAL, newSVGooCanvasItem((GooCanvasItem*)i->data));
+    }
+    sv_2mortal((SV*)RETVAL);
+  OUTPUT:
+    RETVAL
+  CLEANUP:
+    g_list_free (list);
 
 void
 goo_canvas_scroll_to(canvas, left, top)




More information about the Pkg-perl-cvs-commits mailing list