[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Re: Re: Glib::Object and Storable





--- On Fri, 5/8/09, jeffrey ratcliffe gmail com <jeffrey ratcliffe gmail com> wrote:

> From: jeffrey ratcliffe gmail com <jeffrey ratcliffe gmail com>
> Subject: Re: Re: Re: Glib::Object and Storable
> To: gtk-perl-list gnome org
> Date: Friday, May 8, 2009, 3:54 AM
> On May 8, 2009 11:52am, Sergei
> Steshenko <sergstesh yahoo com> wrote:
> > When
> I needed to store the state of my GUI, I wrote a routines
> which upon encountering widgets converted them into their
> properties, for example:
> 
> Doing that in a generic
> way is a bright idea (I ended up doing a tiny subset of it
> in a similar manner), but rather hard to do properly,
> keeping the references between widgets correct, etc.,
> especially as not all Glib::Objects have a straight new()
> method.
> 
> Nevertheless, done well, it would be
> worth a module on CPAN, and I would use it.
> 
> Regards
> 
> Jeff
> -----Inline Attachment Follows-----
> 
> _______________________________________________
> gtk-perl-list mailing list
> gtk-perl-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-perl-list
> 

No, I didn't do it in a generic way. I did it in my application-specific
way, i.e. I store only the bare minimum needed to reconstitute widgets.

For example, for toggle buttons I store only their on/off state, and my
value change sub knows to render text on the button according to its on/off
state.

Regards,
  Sergei.


      


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]