Borderless window

Get answers to all your basic programming questions. No Ogre questions, please!
Post Reply
User avatar
Ruud v A
Gremlin
Posts: 150
Joined: Mon Jan 28, 2008 6:44 pm
Location: The Netherlands
x 5
Contact:

Borderless window

Post by Ruud v A »

How do I create a borderless window via the Win32 API? I searched Google quite thoroughly, but no results. If I specify no window styles and no extended window styles (just 0) the window still has a border (and caption bar, I also like to know how to get rid of that. Not specifying WS_CAPTION and no buttons just WM_THICKFRAME doesn't work.)

Thanks in advance,

~Ruud.
User avatar
lonewolff
Ogre Magi
Posts: 1207
Joined: Wed Dec 28, 2005 12:58 am
x 6

Re: Borderless window

Post by lonewolff »

WS_POPUP in your window style will do the job.

For example;

HWND hWnd=CreateWindowEx(NULL,L"Window Class",
L"Windows application",
WS_EX_TOPMOST | WS_POPUP,
200,
200,
640,
480,
NULL,
NULL,
hInst,
NULL);

Hope this helps :wink:
User avatar
Ruud v A
Gremlin
Posts: 150
Joined: Mon Jan 28, 2008 6:44 pm
Location: The Netherlands
x 5
Contact:

Re: Borderless window

Post by Ruud v A »

Yes it does! Thank you very much. :D
User avatar
lonewolff
Ogre Magi
Posts: 1207
Joined: Wed Dec 28, 2005 12:58 am
x 6

Re: Borderless window

Post by lonewolff »

Glad to be of assistance :D
Zebriah
Gnoblar
Posts: 1
Joined: Wed Jun 04, 2014 5:04 am

Re: Borderless window

Post by Zebriah »

This is a kicker for this thread as it's been inactive since '09. Using Python-Ogre (ogre 1.7.1) how would I create a borderless window?
Post Reply