Archived

This topic is now archived and is closed to further replies.

emileej

Disabling window resize

Recommended Posts

emileej    130
How do you, in C++ on windows, disable the resizing functionality of your window - like you in java use the setResizable function?

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
That depends on what GUI toolkit you are using, if any.

Share this post


Link to post
Share on other sites
emileej    130
grr?
Go stick your gui where the... Ahr never mind ;P
I''m not using any GUI - I am searching for the std. windows interface function.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
This might not be the best solution, but you could always resize window to it''s original size when ever it''s size is changed.

Share this post


Link to post
Share on other sites
emileej    130
I am currently using WS_EX_APPWINDOW|WS_EX_ACCEPTFILES and if I add WS_BORDER or use WS_BORDER solely - my window is not displayed.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
When you are creating your window with CreateWindow() don''t include WS_THICKFRAME or WS_SIZEBOX for the window style. If you are using WS_OVERLAPPEDWINDOW as the style, then it is including WS_THICKFRAME. Instead, use ( WS_OVERLAPPED | WS_SYSMENU | WS_CAPTION ) for your window style.

Hope that solves the problem.

Share this post


Link to post
Share on other sites
emileej    130
I am not using WS_OVERLAPPEDWINDOW - I am using WS_EX_APPWINDOW|WS_EX_ACCEPTFILES and I am using CreateWindowEx.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
Really, you should look in hte help for this kind of information. Because I am so kind i have found a topic that might be of help to you.

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/Windows/WindowReference/WindowStyles.asp

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
WS_EX_APPWINDOW and WS_EX_ACCEPTFILES are for the extended window style parameter. Put ( WS_OVERLAPPED | WS_SYSMENU | WS_CAPTION ) in for the dwStyle parameter of CreateWindowEX()

Share this post


Link to post
Share on other sites
emileej    130
I know fyhuang, but thanks for pointing it out, and AP I have already been there and did not find what I sought - thous I turned to this forum to reach people who had attempted the same thing.

Share this post


Link to post
Share on other sites
emileej    130
I got the result I wished by using WS_OVERLAPPED|WS_SYSMENU|WS_CAPTION|WS_MINIMIZEBOX. Thanks for your help and my apologies for the mixup on my part.

Share this post


Link to post
Share on other sites