Sign in to follow this  
Trillian

[win32/C++] Querying default window position

Recommended Posts

Hello! I need to know what is the default position of a window, like if I was creating the window using CreateWindow and CW_USEDEFAULT as the x/y coordinates. However, I do not want to actually create a window. Is there any way to query this default position?

Share this post


Link to post
Share on other sites
From the purpose of this flag, I don't believe such position exists. It's simply determined in a non-deterministic fashion at the time of call. In addition, some windows don't even support it.

It's likely that the only way to do this is to actually create the window, then query that - but the values will be different every time you do that.

The default position doesn't mean a particular value, it depends on outside factors, most/all of which are likely not specified.

Share this post


Link to post
Share on other sites
That's what I feared. Anyways I somewhat got around the problem by centering the window in the screen as default coordinates. Thanks anyways.

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