Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Programming Talk / C++ / C# - What is needed for a "window application"?

Author
Message
nackidno
19
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: Där solen aldrig skiner
Posted: 12th Sep 2009 02:02
Hi everyone, I'm concerned about programming a windows environment with C++. Right now, I'm only creating console based applications, but I want to take the next step.

My question is pretty simple: Is there any need for a special API to create a window? Or can you use the standard libraries for this?

ionstream
21
Years of Service
User Offline
Joined: 4th Jul 2004
Location: Overweb
Posted: 12th Sep 2009 08:34
You need the Win32 API libraries, found in the Platform SDK. This comes with Visual C++ 2008 nowadays, but can also be found in a separate download if you need it. This is for Windows at least.

You might also want to look into a GUI toolkit like QT or wxWidgets. I like wx the best but Qt seems to be more popular.

nackidno
19
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: Där solen aldrig skiner
Posted: 12th Sep 2009 10:53
Many thanks, I will look into the suggestions given. Thanks.

Coder#05
20
Years of Service
User Offline
Joined: 26th Oct 2005
Location: Denmark
Posted: 14th Sep 2009 23:17 Edited at: 14th Sep 2009 23:20
Hey, this is a very nice tutorial for learning/getting started with the Win32 API

http://www.winprog.org/tutorial/



Below info from an article written by someone else here at the forum:

And, if you are using the DarkGDK sdk and need to use your own window procedure function, do this:



Where the last argument passed(LONG)Proc_MainWindow) is the address off your window procedure function.

And call the "old" window procedure function from your procedure function(only when needed though, read the above tut):


g_pGlob is declared in the DarkGDK header file: globstruct.h
So you will need to include this.

&?

nackidno
19
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: Där solen aldrig skiner
Posted: 15th Sep 2009 12:04
A very interesting link Coder#05, I don't have time to read it right now because I'm at school at the moment, I will surely read it through when I get the time to. Really appreciated.

And thanks for the tip about the GDK window procedure function, will come in handy for sure.

Login to post a reply

Server time is: 2026-06-10 05:54:07
Your offset time is: 2026-06-10 05:54:07