[Glade-users] libglade pixmap loading
- From: lists brachttal net (Andreas Volz)
- Subject: [Glade-users] libglade pixmap loading
- Date: Sat, 31 Jul 2004 00:48:15 +0200
Hi,
Damon Chaplin damon karuna uklinux net
14 Jan 2004 15:52:22 +0000
I'm answering to an old email (Thread[1]), because I've the same
problem:
Check the pixmap files were installed, probably into somewhere like:
/usr/local/share/pixmaps/project33
Check src/interface.c has code like:
about1_logo_pixbuf = create_pixbuf ("project33/calendar.xpm");
Try creating a small project from scratch using one pixmap and see if
that works OK.
I've had similar reports from a few people before, so I'd like to
figure out what the problem is here.
Perhaps I found the problem. If I work with Glade and create the
C-Sourcecode there is in interface.c:
...
image8 = create_pixmap (toolbox_window, "sphere.png");
...
So far no problem, because I could use the function from support.c in my
application:
add_pixmap_directory (PACKAGE_DATA_DIR "/" PACKAGE"/pixmaps");
This works and the application search the image where I installed it.
For example /usr/share/gldesigner/pixmaps/sphere.png.
The problem is only if you use no interface.c and no support.c, because
you use libglade and the .glade file to create my GUI. The image is in
the .glade like this:
<widget class="GtkImage" id="image8">
...
<property name="pixbuf">sphere.png</property>
....
It seems there is no way to tell libglade in which directory the
sphere.png is. Or is there any add_pixmap_directory() function in
libglade?
The best way for me is currently to insert an empty image in Glade and
later get it into the sourcecode and load the image with C-Code. But is
there really no better/easier way?
regards
Andreas
[1] http://makeashorterlink.com/?V5D2520F8
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]