GdkPixbuf-CRITICAL: gdk_pixbuf_new_from_data
Archives Forums/Linux Discussion/GdkPixbuf-CRITICAL: gdk_pixbuf_new_from_data
| ||
When I run my MaxGUI program on BlitzMax, I get this error: GdkPixbuf-CRITICAL **: gdk_pixbuf_new_from_data: assertion `width > 0' failed Still trying to figure out why. Anyone have any ideas? |
| ||
Not a real idea, but had similar errors with some wxwidget implementations. At the end I changed some code to not use the errorneous commands. Think this is not the option you are able to choose - so this post is just to inform you, that it is not only maxgui-source-related but with the communication between maxgui and gdkpixbuf. hm...somehow a senseless post by me. bye Ron |
| ||
If I was you Josh focus on the gdk functions you implemented. I'm not sure but I think that was one of the errors I got with the icon/theme problem. But from what I have seen a number of things can cause it. |
| ||
I am using Bah.GTKMaxGUI. We're about to find out how feasible this idea was. |
| ||
The Hyperlink proxy gadget will cause this, either because it is setting the gadget font, color, or some other setting. I replaced it with a button and am investigating further. The only way to debug this is to add a DebugStop command to move the cursor, then call GCCollect() and see if it crashes. |
| ||
The LoadGUIFont command is causing this error. In GTKGUI.bmx: Method LoadFontWithDouble:TGuiFont(name:String, size:Double, flags:Int) return Null rem Local font:TGuiFont = New TGTKGuiFont font.name = name font.size = size font.style = flags Return DoLoadFont(font) endrem End Method GTKGadget.bmx: Rem bbdoc: Sets the gadget font End Rem Method SetFont(font:TGuiFont) Rem If font = Null Then Return End If _font = font '_font.name = font.name '_font.size = font.size '_font.style = font.style If Not font.handle Then font.handle = Int Ptr(getPangoDescriptionFromGuiFont(font))[0] End If gtk_widget_modify_font(handle, Int Ptr(font.handle)) 'pango_font_description_free(fontdesc) EndRem End Method Rem bbdoc: Set the text area font. End Rem Method SetFont(font:TGuiFont) 'Super.SetFont(font) ' we need to reset the tabs, as it is lost when font is changed. 'SetTabs(_tabsize) End Method Here's my program actually running in Ubuntu: http://www.leadwerks.com/werkspace/page/gallery/_/leadwerks-31-editor-on-ubuntu-r251 |
| ||
Do you know what data elements are being passed in font:TGuiFont? getPangoDescriptionFromGuiFont is in gtkcommon.bmx. Have a look at https://developer.gnome.org/pango/stable/ in Basic Pango Interfaces. And it may be worth your while posting this in Brucey's section as well. |
| ||
Sorry to be slightly offtopic: the screenshot you have posted - it has the same problems like UNZ's ide... - you use resized icons - the icons do not look that familar to the system ones: use the system ones if possible (and you custom ones wont look alienated) - or use only custom ones, but with the correct size of your toolbar. hint: Although the displayof your scrollbars is "naturally" happening (have to scroll -> visible scrollbars). On your screenshot it looks a bit "misaligned" as the only area not being conform is the perspective view (which is scrollbarwidth-wider and scrollbarheight-higher). Is there a reason to write "Left - ZY" instead writing the axis-label next to the axis? @TGuiFont and getPango ... think I had similar problems when I tried to have custom fonts for my tries with custom drawn tooltips... but like the hyperlink component I just did not use the functionality to get rid of it again. The whole "connecting to external libraries"-thing is still a bit of a miracle to me. Especially wrappers for objects or to access them using pointers. Maybe the wxmax-way would have been harder the first steps (because you surely have a win32-maxgui-base) but later on easier to work with because it is more versatile (and is statically linked - less dependencies). bye Ron |