GNOME Bugzilla – Bug 677752
GdkPixbuf-CRITICAL warnings in GtkStatusIcon executions in KDE Plasma...
Last modified: 2014-08-30 05:20:12 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
Which exact GTK version is this about? What is the command that you use to compile the code?
(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 ?
> when runs under KDE - Plasma (but not under GNOME Classic), On the same computer?
(In reply to comment #3) > > when runs under KDE - Plasma (but not under GNOME Classic), > > On the same computer? Yes, on the same computer.
GtkStatusIcon has been deprecated