Using Glib::RefPtr
- From: Yves Claes <claes_yves hotmail com>
- To: <gtk-app-devel-list gnome org>
- Subject: Using Glib::RefPtr
- Date: Fri, 7 Nov 2008 11:30:50 +0000
Hi,
I 'm trying to write a little app in Gtkmm on windows;
I have a GtkWindow and want to draw some rectangles on it using gdk functions.
so i retrieve my gdkWindow using the following code
GdkWindow* gdkWindow = GTK_WIDGET(this)->window;
GdkDrawable* gdkDrawable = GDK_DRAWABLE(gdkWindow);
But when i try to get a context it goes wrong
he does not like
Glib::RefPtr<Gdk::GC> some_gc = Gdk::GC::create(gdkDrawable);
Can any body explain me what the difference is between a Glib::RefPtr and a C/C++ pointer
Glib::RefPtr<GdkDrawable> versus GdkDrawable*
and how to convert between them?
Thanks.
btw: is there any where an simple example on using gdk (ex. a gtkwindow with some gdk rectangles and some
text?)
_________________________________________________________________
Windows Live Hotmail now works up to 70% faster.
http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_faster_112008
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]