GtkCellRendererPixbuf with a checkbox?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi everyone,

for a private (yet) project, I need a GtkIconView, which can display a GtkCheckButton in a corner of every icon or before/behind the label - kinda like the idea of the plus/minus signs on every icon in the dolphin file manager from KDE4. I first tried to achieve the functionality by way of GtkCellRendererToggle and gtk_cell_layout_pack_end, but was not able to make the check box clickable or when I set "mode" to GTK_CELL_RENDERER_MODE_EDITABLE my app crashed with:

(app:5890): Gtk-CRITICAL **: gtk_widget_set_parent_window: assertion `GTK_IS_WIDGET (widget)' failed

(app:5890): Gtk-CRITICAL **: gtk_widget_set_parent: assertion `GTK_IS_WIDGET (widget)' failed

(app:5890): Gtk-CRITICAL **: gtk_cell_editable_start_editing: assertion `GTK_IS_CELL_EDITABLE (cell_editable)' failed

(app:5890): Gtk-CRITICAL **: gtk_widget_grab_focus: assertion `GTK_IS_WIDGET (widget)' failed

(app:5890): GLib-GObject-WARNING **: invalid (NULL) pointer instance

(app:5890): GLib-GObject-CRITICAL **: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed

I had a look at the implementation of GtkCellRendererPixbuf and GtkCellRendererToggle, but since I don't have much experience with Gtk+ and have not developed a custom widget with it yet, I couldn't even decide which one to subclass. So instead of re-inventing the wheel, I'd like to see if someone else has it already rolling...

So if someone has useful pointers or knows an open source project with an already working implementation, I'd appreciate a nudge in that direction. Thanks in advance!

Best regards,

Todor
_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux