[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Windowbar/border
- From: "Emmanuel DELOGET" <logout free fr>
- To: <gtk-app-devel-list redhat com>
- Subject: Re: Windowbar/border
- Date: Sun, 27 Feb 2000 20:25:30 +0100
From: Carlos Pereira <carlos@pehoe.civil.ist.utl.pt>
> > I was wondering how you can make an app with NO windowbar and no border,
> > just printing graphics to the entire screen, lise many common win32
> > games (starcraft, diablo, quake2, etc). This is somewhat important to me
> > (I want it to look professional and consistant with the feel of the
> > game). Can GTK+ accomplish this under the X system? If not, can you
> > point me to something that can do this under the X system?
Not sure that programming a game using X and GTK+ is a good
solution. Anyway you could have a look to the source code
of Golgotha (see golgotha.opengames.org), the free game from
(RIP) Crack Dot Com. Check the display_init() function.
>
> There are a couple of different ways of doing this with GTK. To go full screen:
>
> GtkWidget *window;
> gdk_window_move_resize (window->window, 0, 0, gdk_screen_width(), gdk_screen_height());
> gtk_window_set_default_size (GTK_WINDOW (window), gdk_screen_width(), gdk_screen_height());
> gtk_widget_set_usize (window, gdk_screen_width(), gdk_screen_height());
>
> This will hide all WM decorations and show only your window contents.
> Anyway, there are GTK functions to explicitly hide WM decorations and
> their functionality.
Like gtk_window_set_decorations() and gtk_window_set_functions()
(see the GLM 2000-01 on http://logout.free.fr/gtk-glm/index.html
for further informations)
>
> If you only have a drawing area inside the window, it will go full screen.
> If there are widgets in the window that you want to hide, you can use:
> gtk_widget_hide (widget);
>
> If you want to save the window geometry before going full screen, so
> later on you can go back, you can use, for example:
>
> gdk_window_get_size (window->window, &w, &h);
> gdk_window_get_origin (window->window, &x, &y);
>
> However, there's one thing I still don't know, which is: how can I hide
> the tools provided by the WM? say, tool bars, desktop bars and such?
>
> Carlos
>
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]