Re: Dragging a window



Press ALT while left clicking on it... nah just kidding.

I presume you want to do it in code... so you could inherit the Gtk::Window class, and add a custom "on_click" handler, and have that call   gtk_window_set_position (GtkWindow *window, GtkWindowPosition position);

These are your WindowPosition flags:
  GTK_WIN_POS_NONE,
  GTK_WIN_POS_CENTER,
  GTK_WIN_POS_MOUSE,
  GTK_WIN_POS_CENTER_ALWAYS,
  GTK_WIN_POS_CENTER_ON_PARENT

Only problem is that GTK can only set these couple of flags for the window manager, and there's no promises that the window manager is going to adhere to these...

Good luck, -Harry

PS: I think it a rather bad idea to do this... its not particularly user friendly!


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