Jump to content
  • Advertisement
Sign in to follow this  
nuclear123

looking for windows API tutor!

This topic is 2866 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

sorry for posting such an annoying topic but i am very interested programing c++ and would very much like to get into the windows API programming part of it to be able to interact with the windows O/S and makeing a GUI for my programs! I know it's very unlikely to find a tutor especially for free but if anyone happens to have experience in this area and has some free time to spare every now and then and would like to spread/help refresh your knowledge on me id be greatly appreciated! toss me a PM or reply and we can contact each other on SKYPE - cheers

Share this post


Link to post
Share on other sites
Advertisement
You sure you want to use the Windows API directly? It's essentially written in stone age C and extremely awkward to use. Personally, you'd pratically have to point a gun to my head to make me touch Windows' API for GUI programming.

Why not use something modern and platform-independent like Qt or wxWidgets instead? I'd recommend going with Qt ... makes GUI programming a breeze. wxWidgets feels too much like a MFC clone - sort of messy and you have to write a lot of code for even the most trivial things.

You could even use C# instead and get a nice GUI API for free without using any external libraries.

Share this post


Link to post
Share on other sites
the most important thing about win32 api programming is that you need to know how message handling works if you are confident in c and c++ that is. learning how messages works may be a pain at first but after you have tried and failed alot of times you should understand it pretty much. also its a good thing to search for some message wrapper class on the net because while doing message handling you have to use one shared window procedure instead of several others. because that means there will be _ALOT_ of code. i think there is some nice tutorial on the net with lots of sourcecode, i cant remember the name of the site though, its design was green and brownish i remember and i think it was called something with ....soft. anyway, start out simple, like some hello world program with paint dc's and stuff like that before you try coding a message handler.

here are some short words for what you need:
- WNDCLASSEX or just WINDCLASS
- RegisterClass(Ex)
- CreateWindow, ShowWindow
- Message Pumper, like translate, dispatchmessage, peekmessage etc..
(this is where the messages gets pumped to your program/windows or whatever)
- The gizmos u want, like Buttons and stuff like that.

if you can make some abstract classes for the Gizmos, you can reuse that class without copy & paste code. same for windows.

here's a hello world application:
http://msdn.microsoft.com/en-us/library/bb384843.aspx

if you learn what is what, the rest should be simple to look up at msdn.

Share this post


Link to post
Share on other sites
i've looked at QT before still not sure how to implement buttons to do certain things :/ im quite the noob when it comes to GUI things

Share this post


Link to post
Share on other sites
You can use WinForm (and the whole .Net api) with C++ as well, though I would switch to C# unless you are for some reason bound to C/C++...

Share this post


Link to post
Share on other sites
okay, if you want to be hardcore, i searched the net and found some wrapper class tutorials:

- http://www.relisoft.com/win32/index.htm
- http://www.infernodevelopment.com/c-win32-api-simple-gui-wrapper
- http://www.gamedev.net/reference/articles/article1810.asp
- http://www.codeproject.com/KB/winsdk/win32windowwrapperclass.aspx
- http://virtualrealityblog.com/tutorials/test/windows-wrapper-tutorial/

that should get you on track, if you decide not to use other tools.

Share this post


Link to post
Share on other sites
Quote:
Original post by Rudibs
okay, if you want to be hardcore, i searched the net and found some wrapper class tutorials:

- http://www.relisoft.com/win32/index.htm
- http://www.infernodevelopment.com/c-win32-api-simple-gui-wrapper
- http://www.gamedev.net/reference/articles/article1810.asp
- http://www.codeproject.com/KB/winsdk/win32windowwrapperclass.aspx
- http://virtualrealityblog.com/tutorials/test/windows-wrapper-tutorial/

that should get you on track, if you decide not to use other tools.


Wrapping Win32 is not a project for beginners (to C++ or Win32). The OP should get a copy of Programming Windows and work through it (as it has been done since time immemorial...)

Share this post


Link to post
Share on other sites
You can ask me some questions if you want :) Although I have only been learning Win32 for about 7/8 months so I dont know it completely in depth, for eg dont ask me about win sockets yet coz I dont know it yet.

Best way to contact me is through email. cya

Share this post


Link to post
Share on other sites
I can only advise you to play with the win32 API a little bit. Write a program, and try implementing things on your own (like drag and drop for example). I did something similar and I learned alot, especially how the underlying API of all these fancy wrappers works (in the case of windows that is). The resources that the other guys posted should suffice.

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!