Quantcast

Gtk errors - what do they mean?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Gtk errors - what do they mean?

Frédéric Bron
I have built some wxwidgets samples for GTK 3 with wx 3.1.0 and they
give a lot of error messages (see below). Are these serious issues? Is
it possible to make these messages disappear?
Frédéric

* auidemo:

when clicking on wxPanel:

(wx-auidemo:9019): Gtk-CRITICAL **: gtk_box_gadget_distribute:
assertion 'size >= 0' failed in GtkSpinButton

when quiting:

(wx-auidemo:9019): Gtk-CRITICAL **: gtk_widget_is_drawable: assertion
'GTK_IS_WIDGET (widget)' failed

* collpane:

When showing About dialog:

Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.

* combo:

when the program ends: 2 messages like that:

(wx-combo:8974): Pango-CRITICAL **: pango_layout_get_cursor_pos:
assertion 'index >= 0 && index <= layout->length' failed


* controls:

when the program starts: many messages like that:

(wx-controls:8891): Gtk-CRITICAL **: gtk_box_gadget_distribute:
assertion 'size >= 0' failed in GtkScrollbar

--
Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.

To unsubscribe, send email to [hidden email]
or visit http://groups.google.com/group/wx-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Gtk errors - what do they mean?

Vadim Zeitlin-4
On Tue, 14 Mar 2017 10:55:18 +0100 Frédéric Bron wrote:

FB> I have built some wxwidgets samples for GTK 3 with wx 3.1.0 and they
FB> give a lot of error messages (see below).

 Unfortunately GTK+ 3 is a (very) fast moving target and changes breaking
the code which used to work with earlier versions or even downright bugs
regularly happen in it. We try to keep up, but it's not always simple...
Which version of GTK+ (`pkg-config --modversion gtk+-3.0`) do you have?

FB> Are these serious issues?

 Most of them don't seem to be, but I'm not sure and would have to look
closer.

FB> Is it possible to make these messages disappear?

 You should be able to set your custom GTK log handler

https://developer.gnome.org/glib/stable/glib-Message-Logging.html#g-log-set-handler

but I wouldn't recommend doing it: the users won't see these messages
anyhow (they don't run the application from the console) and they can be
useful during development.

FB> Frédéric
FB>
FB> * auidemo:
FB>
FB> when clicking on wxPanel:
FB>
FB> (wx-auidemo:9019): Gtk-CRITICAL **: gtk_box_gadget_distribute:
FB> assertion 'size >= 0' failed in GtkSpinButton

 I think this is not as critical as it says, probably some layout problem
due to control being too small or something like this.

FB> when quiting:
FB>
FB> (wx-auidemo:9019): Gtk-CRITICAL **: gtk_widget_is_drawable: assertion
FB> 'GTK_IS_WIDGET (widget)' failed

 This doesn't look good OTOH, I'll try to look into this one...

FB> * collpane:
FB>
FB> When showing About dialog:
FB>
FB> Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.

 This is definitely harmless, just annoying.

FB> * combo:
FB>
FB> when the program ends: 2 messages like that:
FB>
FB> (wx-combo:8974): Pango-CRITICAL **: pango_layout_get_cursor_pos:
FB> assertion 'index >= 0 && index <= layout->length' failed

 This doesn't look good neither...

 Regards,
VZ

--
TT-Solutions: wxWidgets consultancy and technical support
               http://www.tt-solutions.com/

attachment0 (203 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Gtk errors - what do they mean?

Frédéric Bron
> FB> I have built some wxwidgets samples for GTK 3 with wx 3.1.0 and they
> FB> give a lot of error messages (see below).
>
> Which version of GTK+ (`pkg-config --modversion gtk+-3.0`) do you have?

3.22.9

--
Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.

To unsubscribe, send email to [hidden email]
or visit http://groups.google.com/group/wx-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Gtk errors - what do they mean?

Vadim Zeitlin-4
In reply to this post by Frédéric Bron
On Tue, 14 Mar 2017 10:55:18 +0100 Frédéric Bron wrote:

FB> I have built some wxwidgets samples for GTK 3 with wx 3.1.0 and they
FB> give a lot of error messages (see below). Are these serious issues? Is
FB> it possible to make these messages disappear?
FB> Frédéric
FB>
FB> * auidemo:
FB>
FB> when clicking on wxPanel:
FB>
FB> (wx-auidemo:9019): Gtk-CRITICAL **: gtk_box_gadget_distribute:
FB> assertion 'size >= 0' failed in GtkSpinButton

 This was just due to creating a wxSpinCtrl with a fixed width of 100
pixels which is not enough, so it was fixed by

https://github.com/wxWidgets/wxWidgets/commit/672cf7d1996c24db3a73e5d9c76881045d6e72f0

FB> when quiting:
FB>
FB> (wx-auidemo:9019): Gtk-CRITICAL **: gtk_widget_is_drawable: assertion
FB> 'GTK_IS_WIDGET (widget)' failed

 I see this one and, also, a message similar to it in the toolbar sample
which also has a combobox in a toolbar (because this is what triggers it),
with GTK+ 3.22.9 under Debian Stretch, but I don't see neither of them with
3.14.5 in Debian Jessie, so it looks like something has changed again in
GTK+ in an incompatible way.

 I don't see what do we actually do wrong, but I found a way to work around
getting this message, see https://github.com/wxWidgets/wxWidgets/pull/449
If Paul doesn't object, I'm going to merge this relatively soon. But, in
any case, this "CRITICAL" message is actually harmless.


FB> * combo:
FB>
FB> when the program ends: 2 messages like that:
FB>
FB> (wx-combo:8974): Pango-CRITICAL **: pango_layout_get_cursor_pos:
FB> assertion 'index >= 0 && index <= layout->length' failed

 I don't see this one at all, with any GTK+ version. Do you do anything
special to trigger this message by chance?


FB> * controls:
FB>
FB> when the program starts: many messages like that:
FB>
FB> (wx-controls:8891): Gtk-CRITICAL **: gtk_box_gadget_distribute:
FB> assertion 'size >= 0' failed in GtkScrollbar

 The "controls" sample doesn't exist any more since more than a year, so
this can't happen with the latest master.

 Regards,
VZ

--
TT-Solutions: wxWidgets consultancy and technical support
               http://www.tt-solutions.com/

attachment0 (203 bytes) Download Attachment
Loading...