Hi James.
I found another point where the canvas crashes, but this time I get no
segfault. It seems a bit like the arrowhead problem we found earlier, but I
don't know. No arrowhead is used to get the crash. It occurs when an
antialiased canvas is used, and all the points in a line are set equal.
I modified your crashme program:
------------8<------------
from gtk import *
from gnome.ui import *
def crash_me(button, canvas, line):
line.set(points=(1,1, 1,1))
print "About to crash:"
print canvas.get_item_at(0, 0)
win = GtkWindow(WINDOW_TOPLEVEL)
win.set_title("Canvas Crash")
win.connect("destroy", mainquit)
vbox = GtkVBox(spacing=5)
win.add(vbox)
vbox.show()
canvas = GnomeCanvas(aa=TRUE)
canvas.set_usize(10, 10)
canvas.set_scroll_region(-1.5, -1.5, 1.5, 1.5)
vbox.pack_start(canvas)
canvas.show()
root = canvas.root()
line = root.add('line', points=(1,1, -1,-1))
button = GtkButton("Crash Me")
button.connect("clicked", crash_me, canvas,
line)
vbox.pack_start(button, expand=FALSE)
button.show()
win.show()
mainloop()
------------8<------------
If you just remove aa=TRUE, it won't crash.
Cheers.
Jeff
--
J.W. Bizzaro mailto:[EMAIL PROTECTED]
Boston College Chemistry http://www.uml.edu/Dept/Chem/Bizzaro/
--
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]