Re: Dragging a TreeViewItem painted with custom CellRenderer



On Fri, Apr 10, 2009 at 8:50 AM, Paul Davis <paul linuxaudiosystems com> wrote:
>
> Its probably true that Gtk::Style's draw methods should probably take
> Glib::RefPtr<Gdk::Drawable> not Glib::RefPtr<Gdk::Window>.

I wasn't finished.

... However, that represents an issue in the C API which also requires
 a GdkWindow.

It probably works in C because of the less strict type checking and
the fact the low level code which actually does the drawing only cares
about GdkDrawable (both GdkPixmap and GdkWindow are examples thereof).
Thus when you pass in a pixmap to gtk_style_draw_layout() it works
because nothing checks that its a GdkWindow, only a GdkDrawable. in
the C++ API, the requirement that the argument be a GdkWindow is being
enforced by the compiler.


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