Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 954495
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T00:13:29+00:00 2026-05-16T00:13:29+00:00

I keep getting a broken image (a red ‘X’ in a paper, it doesn’t

  • 0

I keep getting a broken image (a red ‘X’ in a paper, it doesn’t even start loading the one i want, I don’t know if this is clear enough) and don’t know why, here is what i tried:

image = gtk_image_new_from_file("abc.png");
gtk_container_add (GTK_CONTAINER (window), image);
gtk_widget_show (image);
gtk_widget_show (window);`

I am a newbie in GUI programming so please be nice! haha

I forgot to say that this is under windows

UPDATE: noticed that the error is in “gdk_pixbuf_new_from_file” it returns me the error value, can’t solve the problem yet

if i run the debugger, it says “Error loading file: #4 Failed to open file ‘abc.jpeg’: No such file or directory”, it should be in the folder where the executable is? anyway if i put the complete path it doesn’t find it either

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T00:13:30+00:00Added an answer on May 16, 2026 at 12:13 am

    I had the same problem (on some machines) then I compiled an application for Windows using a recent version of GTK+. In older versions of GTK+, or gdk-pixbuf to be exact, each image loading plugin supplied a set of magic patterns to identify the file format(s) if can load. But then glib got an API for identifying files gdk-pixbuf was updated to use this instead. On Windows glib relies on the system for identifying files, but this is there it often fails. GTK+ doesn’t find out what kind of file it is, and assumes there is no loader available for it. This, however, generates an error message in the lines of “no loader available” or at least “image could not be loaded”. But maybe that’s what you get then you supply the whole path?

    I solved the problem by identifying the file types myself (using code from PCManFM) and loading the image with the type explicetly specified, using gdk_pixbuf_loader_new_with_mime_type(). A little cumbersome but it got the job done.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I keep getting crashes from a save: command on a managedObjectContext. It doesn't even
I keep getting uncaught handler error in this code and I don't know why.
I keep getting an exception when I want to display an alertdialog at the
Keep getting this error after inserting a subdatasheet into a query and trying to
Keep getting the error Arguments are not sufficiently instantiated for the multiplication by addition
I keep getting an error saying that @android:style/Widget.Holo.Light.Button.Borderless is not public and so can't
I keep getting this error and have no idea why. I googled and scanned
I keep getting this error on emulator: I copied this from a tutorial and
I keep getting this error Error in readPNG(destfile) : libpng error: PLTE: CRC error
I keep getting this error with my Play 2.0 application: play.core.ActionInvoker$$anonfun$receive$1$$anon$1: Execution exception [[MatchError:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.