Re: [gtkmm] The correct way to use Glib::Error?



On Fri, Nov 07, 2003 at 06:11:07PM +0100, Murray Cumming Comneon com wrote:
> > From: gtkmm-list-admin gnome org 

> >   I'm not sure of the method of using Glib::Error in Gtkmm2.  
> > Should I throw short exceptions,

> What's a short exception?

  Sorry, stupid buzz phrase.

  What I ment by "short exception" was to use exceptions, but keep them in
my code.

  If the code invokes some GTKMM constructs then I should't use them.

  That's how I read FAQ question 4.6.

  I assumed that because exceptions can cause trouble, then a safer
way would be to use Glib::Error as a paramater to the function calls
similar to the way you would use GError in plain old (C based) GTK.

  The argument against that is that GError has lots of helpful support
functions such as g_propagate_error() and I don't see the equivalent
in Glib::Error.

  The long and short of it is: What's the "correct" way (if there
is one) to propagate my error messages so as to not harrass GTKMM.
I'm fine with C++ exceptions, or the GTKMM equivalent of GError,
GError itself, or whatever is safe.

  I just don't want to commit to one method and then find out
I've re-invented the wheel or riddled my application with GTKMM
incompatibilities.

						Dale

Attachment: pgpmcXbXrXgrS.pgp
Description: PGP signature



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