After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 677752 - GdkPixbuf-CRITICAL warnings in GtkStatusIcon executions in KDE Plasma...
GdkPixbuf-CRITICAL warnings in GtkStatusIcon executions in KDE Plasma...
Status: RESOLVED WONTFIX
Product: gtk+
Classification: Platform
Component: Widget: GtkStatusIcon
3.4.x
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2012-06-09 12:29 UTC by gtglus
Modified: 2014-08-30 05:20 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description gtglus 2012-06-09 12:29:37 UTC
The simple code below throws the warning

"GdkPixbuf-CRITICAL **: gdk_pixbuf_scale_simple: assertion `dest_width > 0' failed"

when runs under KDE - Plasma (but not under GNOME Classic), although the icon is well fitted in the System Trays of both environments.

---
#include <gtk/gtk.h>

int main (int argc, char *argv[])
{
    GtkWidget *window;
    GtkStatusIcon *statusicon;
    
    gtk_init (&argc, &argv);
    
    statusicon = gtk_status_icon_new_from_file ("icon.svg");
    
    window = gtk_window_new (GTK_WINDOW_TOPLEVEL);    
    gtk_widget_show (window);
   
    g_signal_connect (window, "delete-event", G_CALLBACK (gtk_main_quit), NULL);
   
    gtk_main ();
    
    return 0;
}
---

Glus
Comment 1 André Klapper 2012-06-09 13:09:18 UTC
Which exact GTK version is this about? 
What is the command that you use to compile the code?
Comment 2 gtglus 2012-06-09 13:33:30 UTC
(In reply to comment #1)
> Which exact GTK version is this about?

$ pkg-config --modversion gtk+-3.0
3.4.2

> What is the command that you use to compile the code?
Before, just

$ gcc `pkg-config gtk+-3.0 --cflags --libs` statusicon.c -o statusicon

But then I do this,

$ gcc -Wall -g `pkg-config gtk+-3.0 --cflags --libs` statusicon.c -o statusicon

And I get,

statusicon.c: In function ‘main’:
statusicon.c:6:20: warning: variable ‘statusicon’ set but not used [-Wunused-but-set-variable]

Is anything wrong ?
Comment 3 Murray Cumming 2012-06-11 08:13:29 UTC
> when runs under KDE - Plasma (but not under GNOME Classic),

On the same computer?
Comment 4 gtglus 2012-06-12 15:53:01 UTC
(In reply to comment #3)
> > when runs under KDE - Plasma (but not under GNOME Classic),
> 
> On the same computer?

Yes, on the same computer.
Comment 5 Matthias Clasen 2014-08-30 05:20:12 UTC
GtkStatusIcon has been deprecated