Re: [gtkmm] Change cursor in Widget



you have to do that in the on_realize() method override or however when
the widget's window has already been created
.
I think it's also in the FAQ but I'm not sure.

Maurizio Umberto Puxeddu.

On Mon, 2003-05-12 at 16:12, Sergio Pascual wrote:
> 
> Hi, I'm trying to change the cursor over one window. I'm using this simple 
> code, but it segfaults:
> 
> #include <gtkmm/window.h>
> #include <gtkmm/main.h>
> #include <gdkmm/cursor.h>
> 
> int main (int argc,char **argv){
>         Gtk::Main app(argc,argv);
>         Gtk::Window window;
>         Gdk::Cursor cursor(Gdk::STAR);
>         window.get_window()->set_cursor(cursor);
>         app.run(window);
>         return 0;
> }
> 
> Is this the way to change the cursor? I'm using 
> gtkmm-2.0.2
> 
> -- 
>  <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
>                  Sergio Pascual Ramírez       spr astrax fis ucm es
>                Tf: (+34)  91-394-50-18      Fax: (+34)  91-394-46-35
>                       Dept. Astrofísica Facultad de C.C. Físicas 
>                           Universidad Complutense de Madrid
>                                  28040 Madrid (Spain)
>  ------------------------------------------------------------------------------
>             Spanish junior researchers fight for employment rights 
>                            http://www.precarios.org
>  <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
> 
> 
> 
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list





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