Re: Destructors eg wxBitmap::~wxBitmap

2009-09-08 Thread Mattia Barbon
Steve Cookson wrote: Hi, I can't see any obvious samples that tell you how the Perl syntax works for removing an element, like a bitmap, a textctrl or a button. Any pointers would be welcome. For all classes derived from wxWindow you can use ->Destroy. Most other classes (including wx

Re: Destructors eg wxBitmap::~wxBitmap

2009-09-07 Thread Jacky Jack
Hi Steve This is because wxPerl is itself ported from WxWidgets. Have you consulted : http://wxperl.sourceforge.net/documentation.html " There is no wxPerl API document per se. The wxPerl API is described in terms of C++ in the following: online wxWidgets documentation (2.6.3)

Destructors eg wxBitmap::~wxBitmap

2009-09-07 Thread Steve Cookson
Hi Guys, I can't see any obvious samples that tell you how the Perl syntax works for removing an element, like a bitmap, a textctrl or a button. Any pointers would be welcome. Regards Steve <>

RE: Destructors

2009-08-08 Thread Steve Cookson
org Subject: RE: Destructors Hi Mattia, Thanks for this. Are they both the same? Obviously one line is better than two! Regards Steve -Original Message- From: Mattia Barbon [mailto:mattia.bar...@libero.it] Sent: 08 August 2009 04:50 To: Steve Cookson Cc: wxperl-users@perl.org Subject:

RE: Destructors

2009-08-08 Thread Steve Cookson
Hi Mattia, Thanks for this. Are they both the same? Obviously one line is better than two! Regards Steve -Original Message- From: Mattia Barbon [mailto:mattia.bar...@libero.it] Sent: 08 August 2009 04:50 To: Steve Cookson Cc: wxperl-users@perl.org Subject: Re: Destructors Steve

Re: Destructors

2009-08-08 Thread Mattia Barbon
Steve Cookson wrote: Hi, Thanks to everyone for their help. Here is an answer that works: $self->{"Notebook_tab_1"}->DestroyChildren(); $self->{"Notebook"}->RemovePage(0); Doing it like this will leak the page object; unless you later reuse the window in Noteboo

RE: Destructors

2009-08-07 Thread Steve Cookson
...@sca-uk.com] Sent: 07 August 2009 14:31 To: wxperl-users@perl.org Cc: 'Andri Möll' Subject: RE: Destructors Hi Andri, Thanks for this. So my frame is called $self, and I have a TextCtrl on it called $self->{"Field_Txt"}. I tried to do: DESTROY($self->{

RE: Destructors

2009-08-07 Thread Steve Cookson
to delete part of an object, I should use a different command. Regards Steve -Original Message- From: Andri Möll [mailto:an...@dot.ee] Sent: 07 August 2009 13:53 To: Steve Cookson Cc: wxperl-users Subject: Re: Destructors On Fri, 2009-08-07 at 13:23 -0300, Steve Cookson wrote: > H

Re: Destructors

2009-08-07 Thread Andri Möll
On Fri, 2009-08-07 at 13:23 -0300, Steve Cookson wrote: > Hi Guys, > > Does anyone know what the correct syntax for a Perl destructor is, if > I want to remove a field, sizer or tab from a pane? > > Any suggestions welcome! > > Regards > > Steve Use the DESTROY subroutine with your Perl bless

Destructors

2009-08-07 Thread Steve Cookson
Hi Guys, Does anyone know what the correct syntax for a Perl destructor is, if I want to remove a field, sizer or tab from a pane? Any suggestions welcome! Regards Steve <>