Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-19 Thread Phil Thompson
Stephen Green wrote: Ok, I think I found out what causes the problem in my code. Here is a small part of my program that will crash. As it is, if you create a point in the program, then delete the point, then try to create a new point, it usually gives a segmentation fault. But if you

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-14 Thread Stephen Green
Ok, I think I found out what causes the problem in my code. Here is a small part of my program that will crash. As it is, if you create a point in the program, then delete the point, then try to create a new point, it usually gives a segmentation fault. But if you comment lines 14 and 18,

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-14 Thread Boudewijn Rempt
On Friday 14 June 2002 19:31, Stephen Green wrote: Ok, I think I found out what causes the problem in my code. Here is a small part of my program that will crash. As it is, if you create a point in the program, then delete the point, then try to create a new point, it usually gives a

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-12 Thread Boudewijn Rempt
On Wednesday 12 June 2002 18:32, Stephen Green wrote: From: Moray Taylor [EMAIL PROTECTED] I think I have figured out how to do it. MyCanvasItem.setCanvas(None) It gets rid of it, and seems to free any memory it was using. Any comments? Moray I tried doing that, and it seems to

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-12 Thread Stephen Green
From: Boudewijn Rempt [EMAIL PROTECTED] To: Stephen Green [EMAIL PROTECTED] CC: [EMAIL PROTECTED] Subject: Re: [PyKDE] How do I delete a QCanvasItem? Date: Wed, 12 Jun 2002 22:08:59 +0200 On Wednesday 12 June 2002 18:32, Stephen Green wrote: From: Moray Taylor [EMAIL PROTECTED] I think

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-11 Thread Moray Taylor
I think I have figured out how to do it. MyCanvasItem.setCanvas(None) It gets rid of it, and seems to free any memory it was using. Any comments? Moray ___ PyKDE mailing list[EMAIL PROTECTED] http://mats.gmd.de/mailman/listinfo/pykde

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-11 Thread Phil Thompson
Moray Taylor wrote: I think I have figured out how to do it. MyCanvasItem.setCanvas(None) It gets rid of it, and seems to free any memory it was using. Any comments? Yes - I'd forgotten I'd already taken care of this. If you look at the implementation of QCanvasItem.setCanvas() in

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-10 Thread Boudewijn Rempt
On Monday 10 June 2002 21:29, Stephen Green wrote: I've been trying to figure out how to delete a QCanvasItem from a QCanvas. I tried using del, QCanvas.removeChild() and removing all references to it. None of this works though. I think removeChild() doesn't work because it takes a QObject

Re: [PyKDE] How do I delete a QCanvasItem?

2002-06-10 Thread Phil Thompson
Boudewijn Rempt wrote: On Monday 10 June 2002 21:29, Stephen Green wrote: I've been trying to figure out how to delete a QCanvasItem from a QCanvas. I tried using del, QCanvas.removeChild() and removing all references to it. None of this works though. I think removeChild() doesn't work