Jump to content
  • Advertisement
Sign in to follow this  
jsloan

Window properties [WIN32]

This topic is 5218 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, Is it possible to create a window without a control box in addition to not being able to be resized (im sure it is). heres what i use for my current window class wndclass.cbSize = sizeof(WNDCLASSEX); wndclass.style = CS_HREDRAW | CS_VREDRAW; wndclass.lpfnWndProc = ProcessMsgs; wndclass.hInstance = hInstance; wndclass.hbrBackground = (HBRUSH)GetStockObject(BLACK_BRUSH); wndclass.lpszClassName = class_name;

Share this post


Link to post
Share on other sites
Advertisement
Yes it is possible to do that.


wndclass.style = CS_DBLCLKS | CS_OWNDC |CS_HREDRAW | CS_VREDRAW

CreateWindowEx(
WS_EX_CONTROLPARENT,
ClassName,
Wname,
WS_BORDER | WS_SYSMENU | WS_CAPTION| WS_VISIBLE,
0, 0,
Width,Height,
NULL, NULL, gcl_hInstance,NULL);




This will give to a window with only a border and it cannot be resized.

If you dont want the standard controls like close and minimize just remove WS_SYSMENU.

And if you just want a black box without any title bar then remove WS_CAPTION

Helps?

Btw also check the Windows API helpfile for information on various options.They are very helpful.

Share this post


Link to post
Share on other sites
all you really need is to make a WS_TILED window, as in:


CreateWindow(winclass,winname,WS_TILED|WS_VISIBLE,0,0,640,480,NULL,NULL,NULL,NULL);



Share this post


Link to post
Share on other sites
Much Much better !

However while in full screen i can still 'drag' the window around via the title bar...is there any way to disable that or get rid of the title bar?

Than you.

Share this post


Link to post
Share on other sites
Quote:
Original post by anist
all you really need is to make a WS_TILED window, as in:

*** Source Snippet Removed ***


Dont we just love windows.There are a hundred ways to do a single thing.

Share this post


Link to post
Share on other sites
Quote:
Original post by FireNet
Dont we just love windows.There are a hundred ways to do a single thing.


yeah, sorry, i got my post out while you were editing yours. just trying to help like you and i like to see others helping as well *rates you up*

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!