Where to begin? (Application development)

Sep 15, 2015 at 11:34pm
For quite a few years (on and off) I've been drilling in the fundamentals of C++ with console applications. I'm at a point where I'd like to try to develop something with a GUI. Not really interested in the game development route, but would feel accomplished with something as simple as a notepad that saves out a file.

Where should I begin with small application development that utilizes a window/GUI that I can build upon?
Sep 16, 2015 at 3:07am
closed account (48T7M4Gy)
Visual Studio - Community Edition,

then there is CodeBlocks with wxWidgets, XCode, Eclipse, and lots of others.

Visual Studio is probably the best of the bunch.
Sep 16, 2015 at 4:09am
Window's API is your friend if you want to get really low level (well not that low, but you get what I mean). If not, there's GUI Libs you can download such as QT.

Honestly, WinAPI isn't as hard as people make it out to be. Yes it can be time consuming setting everything up and yes it requires more work to do the same task that QT could for example. I enjoy it though.
Sep 16, 2015 at 4:31am
Thanks, I'll probably go with WinAPI then as I'd like to keep it as core as possible (not sure if that's the right term to use), rather than use additional libraries such as QT or WxWidgets.

Off to study up on some WinAPI then!!
Sep 16, 2015 at 4:45am
Take note that WinAPI is written in C. If you're going to apply OOP concepts, sometimes they may take a little extra thinking.

Example:

You can't pass a non-static member function Window Procedure to the window class as member functions have an implicit 'this' parameter that gets passed along with it. Static functions don't have that as they don't belong to an object and are part of the class only.

The solution:

1.) Make it static (lame!)
2.) Don't make it a member function (also lame)
3.) Have 2 Window Procedures, 1 static and 1 not (not lame)

Basically you're going to pass the static wndproc to the window class and inside the static wndproc you'll make a pointer to the class that creates your window. You set that pointer to the value you get from GetWindowLongPtr. You store a pointer to your class inside the extra storage space of the window using SetWindowLongPtr that is then retrieved from the GetWindowLongPtr.
Last edited on Sep 16, 2015 at 4:47am
Sep 16, 2015 at 5:15am
@Renthalkx97 that's a bit over my head at the moment. I know nothing of the WinAPI at the moment. So what you just said made little sense to me. I'll keep it in mind when I have an issue that may be related to what you said though.
Sep 16, 2015 at 5:28am
closed account (48T7M4Gy)
While the advice on winapi is sound it would be worthwhile to try the other higher level alternatives first and get into the winapi as a second step. Direct winapi programming is fun but not that easy to get up and running with a simple application - but, needless to say it can be done.
Sep 16, 2015 at 5:42am
Honestly, if you want to just get into GUI programming and don't care which language, Java might be the best option. It's extremely simply to create basic GUI apps. Java has all the elements you would need whereas in C++ (without a library) you'd need to implement it all yourself (listeners, a window heirarchy (frame->panel->button), etc).
Sep 16, 2015 at 6:15am
closed account (48T7M4Gy)
Java's good and very well organised and freely available information. FWIW, the thing I hate about it though, the only thing, is operator overloading.
Sep 16, 2015 at 6:19am
I don't mess with it much. Mainly just when I feel like trying to write some android apps.
Sep 16, 2015 at 4:28pm
I never said I didnt care which language I used. I was asking the best way to get into "C++" GUI development...
Sep 16, 2015 at 5:32pm
I know I was just simply stating that if the WINAPI doesn't work out for you, there's java which is magnitudes simpler.
Sep 22, 2015 at 6:06am
This info helps to understand how to start development. I like to share information on windows app development. Please go through the link.
http://www.intelliswift.com/windows-app-development
Topic archived. No new replies allowed.