Attached is a small patch that (1) creates a rake task for building
emacs tag files and (2) fixes a small bug when DEBUG=1.
--paulv
diff --git a/Rakefile b/Rakefile
index d2b652e..a70b8ef 100644
--- a/Rakefile
+++ b/Rakefile
@@ -2,6 +2,7 @@ require 'rake'
require 'rake/clean'
require 'platform/skel'
require 'fileutils'
+require 'find'
include FileUtils
APPNAME = ENV['APPNAME'] || "Shoes"
@@ -399,3 +400,13 @@ end
SRC.zip(OBJ).each do |c, o|
file o => [c] + Dir["shoes/*.h"]
end
+
+desc "build TAGS file for emacs hackers"
+task :tags do
+ files = ""
+ Find.find(".") do |path|
+ next if path !~ /\.(c|h)$/
+ files += path + " "
+ end
+ system("etags #{files}")
+end
diff --git a/samples/simple-video.rb b/samples/simple-video.rb
diff --git a/shoes/ruby.c b/shoes/ruby.c
index 838748d..0ef05fb 100644
--- a/shoes/ruby.c
+++ b/shoes/ruby.c
@@ -2329,7 +2329,7 @@ shoes_textblock_send_hover(VALUE self, int x, int y, VALUE *clicked, int *t)
hover = pango_layout_xy_to_index(self_t->layout, x * PANGO_SCALE, y * PANGO_SCALE, &index, &trailing);
if (hover)
{
- INFO("HOVER (%d, %d) OVER (%d, %d)\n", x, y, self_t->place.ix + self->place.dx, self_t->place.iy + self_t->place.dy);
+ INFO("HOVER (%d, %d) OVER (%d, %d)\n", x, y, self_t->place.ix + self_t->place.dx, self_t->place.iy + self_t->place.dy);
}
for (i = 0; i < RARRAY_LEN(self_t->links); i++)
{