gtk2 crash: bug or abuse?

H

Holger K.

Hi there.

I am running Ruby 1.8.7 (debian lenny/i386) and the following program
crashes the ruby vm with a Segmentation Fault (when closing the window):

#!/usr/bin/env ruby
=begin
rubycalc - Ruby/GTK first sample script.
=end

require 'gtk2'

window = Gtk::Window.new
window.signal_connect("delete_event") {
puts "delete"
false
}

window.signal_connect("destroy") {
puts "destroy"
Gtk.main_quit
}


window.add( $tos=Gtk::Entry.new() )
style = Gtk::RcStyle.new
font = Pango::FontDescription.new("Sans Serif 15")
style.font_desc = font
$tos.modify_style(style)

window.show_all

Gtk.main
# EOF

Am I abusing RcStyle/Pango or did I discover a bug in the GTK2 bindings?

Regards
Holger
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top