Sign in to follow this  
jsloan

Window properties [WIN32]

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
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
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

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this