Re: regarding Gtkwindows



On Tue, 2006-08-22 at 22:57 -0700, cnu_sree wrote:
> how we can disable close button in windows title bar.

you can't. that is the responsibility of the window manager.

your app can, however, ask the WM not to show a close button:

	some_gtk_window.signal_realize().connect (bind (sigc::ptr_fun
(set_decoration), &some_gtk_window, Gdk::WMDecoration
(Gdk::DECOR_BORDER|Gdk::DECOR_RESIZEH)));

void
set_decoration (Gtk::Window* win, Gdk::WMDecoration decor)
{
	win->get_window()->set_decorations (decor);
}

note that you cannot call set_decorations() on an unrealized GtkWindow
because get_window() will fail.

whether or not the WM will honor your request is another story entirely.





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