GLib-GObject-WARNING **: invalid cast from `GtkSpinButton' to `SPWidget' (trunk >= r11868)

Bug #1089290 reported by su_v on 2012-12-12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Alex Valavanis

Bug Description

For each digit entered into the zoom widget at the right end of status bar, this warning is printed to the console:

GLib-GObject-WARNING **: invalid cast from `GtkSpinButton' to `SPWidget'

As far as I can tell the warning is harmless, but it's irritating nevertheless ;)

Reproduced with current trunk (r11868 - r11950) on
- Mac OS 10.5.8 (glib2 2.28.8)
- OS X 10.7.4 (glib2 2.32.4, 2.34.3)
- Ubuntu 12.10 (glib2 2.34.0)

Not reproduced with <= r11867 and with current stable on all mentioned systems.

Likely related to this change:
revision 11868 “Replace remaining C-style pointer casts for src/widgets”

su_v (suv-lp) wrote :

@Alex - maybe you could take a look at this?

jazzynico (jazzynico) wrote :

Confirmed on Debian testing, Inkscape trunk revision 11950.

Changed in inkscape:
status: New → Triaged
Alex Valavanis (valavanisalex) wrote :

Ah... this kind of thing makes me glad I replaced the C-style pointer casting :-)

The GObject pointer cast macros perform runtime type-checking of objects so it reveals places such as this where we were doing something dodgy all along.

Anyway, I've fixed this in lp:inkscape r11951. We should keep our eyes open for other similar runtime warnings that have been revealed since the type-checking was introduced.

Changed in inkscape:
assignee: nobody → Alex Valavanis (valavanisalex)
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers