1

I'm trying to get a window to cover the whole screen. Its positioning and dimensions is fine but it gets covered by the Gnome panel. To complicate things I have two monitors and this app needs to support people with multiple screens.

WINDOW_TYPE_HINT_SPLASHSCREEN is a good start. It covers both screens but not the panel. It's still there, just behind the panel.

WINDOW_TYPE_HINT_DOCK looked ideal but I need this window to take focus to listen to a keyboard event. _DOCK seems like it purposely ignores keyboard events (which kind of makes sense). Can I force it to take keyboard focus?

Is there some way I can force a hinted window to cover the panel?

Oli
  • 235,628
  • 64
  • 220
  • 299
  • If the window isn't a dock for icons or a splash screen then why hint it that way? The *fulscreen()* function works fine on an un-hinted window. Is there any particular reason the windows needs to be hinted? I have an app that goes fullscreen when 'f' is pressed. It is the main window that fullscreen() uses and it has no special hints. Size and position is given with window_move, set_size_request(). – frayser Dec 15 '10 at 19:14

2 Answers2

0

If you use the WINDOW_TYPE_HINT_MENU, you can give the focus to the window by calling the gtk_window_present() function. However, I don't know if you will be able to cover the panel.

Another hint: the panel probably change its _NET_WM_STRUT property so that other windows cannot cover it. Maybe you will have to play with this property (or another) in your window.

antoyo
  • 11,097
  • 7
  • 51
  • 82
  • Hi antoyo I am working with Noi here will this solution help us here: http://stackoverflow.com/questions/31366706/gtk-window-cover-entire-screen – yatg Jul 13 '15 at 17:32
0

There's window.fullscreen() which you can call on a normal "un-hinted" window. I assume this lets the window manager decide whether the window should cover the panel or not.

ptomato
  • 56,175
  • 13
  • 112
  • 165
  • 1
    This works in a single screen setup but isn't reliable in twinview/xinerama (my target problem) – Oli Oct 28 '10 at 16:42
  • @Oli you are right it works only on single screen, I have set my window to width and height of all monitors, but as soon as I go fullscreen it makes it cover single monitor. My issue is that my window is not even at 0,0 it is not covered, I am working with Noi here http://stackoverflow.com/questions/31366706/gtk-window-cover-entire-screen did you find a solution? – yatg Jul 13 '15 at 17:31