GUI Programming :: C++ Exclusive

Status
Not open for further replies.
Hi.

I have learned the fundamentals of C++. To honest, I truly enjoy programming using C++ and prefer to program using C++.

I signed up for a college course named "GUI Programming." I read the course information and saw that it goes over menu, dialogs, etc. I picked up the books for the spring semester today, and I found out that course is actually a Visual Basic course with emphasis on GUI. I was appalled when I saw the VB book. I thought all alone that the class was GUI programming using C++. I immediately returned the textbook and will drop that class.

My passionate is C++. I want to program exclusively using C++ no matter how difficult GUI is using C++. I would like to know what programming language do programmers use to program the GUI interface under Windows and Linux's XWindows? I returned the textbook, but I have not drop the class. The only reason I can see going through with the class is if it is possible to somehow convert GUI in VB into C++. However, I greatly prefer to use C++ exclusively.

Last, I really want to learn GUI. What are some good C++ books with emphasis on GUI programming?

Thanks,
Kuphryn
 
Many C++ IDEs allow you to layout your windows and controls visually, saving a large amount of time. I programmed in java a lot and found that I preferred to do my GUIs in code, at least in that case.

However, VB is a great way to learn GUI guidelines and things, since the language is easy and won't interfere with the point of the class.

I'd say take the class to learn how to make a functional GUI. Laying it out in the language of choice is a matter of picking up a book and applying what you learned.
 
First, thanks everyone for your inputs.

In addition to the issue of my liking C++ too much, there is something else is bothers me. I have planned my "road" to becoming a future C++ programmer. I dedicated myself to learning C++.

The college requires that I pick either that one GUI Programming course or beginner Java. I chose GUI Programming because, again, I thought it was going to be related to C++ (MFC). It is not. Is it a Visual Basic class.

Now I have to try an reschedule, which is very difficult now that all the classes are full. Second, I am not fond of Java, even though I have heard possitive comments about Java. I prefer a balance of low level (C) and high level (OOP), which is C++. C++ is everything I need right now.

I have decide to go ahead and drop the GUI Programming course. I will end up having to take Java next fall. Hopefully, I will survive Java.

Whatever programming language I see, I always think of C++. C++, always!!!

Kuphryn
 

wb

Ars Legatus Legionis
25,208
Subscriptor
I think you're really limiting yourself as a programmer by turning down a course simply because it uses VB instead of C++. Although I write most of my heavy-duty code in C++ or Java, I still use VB quite often, especially for rapidly prototyping GUI design, because it is so well-suited to that task.

VB is also much faster to prototype COM API stuff. C++ is just plain tedious compared to VB when it come to COM/ActiveX programming. Either for making a prototype of an ActiveX control for example, or going the other way and exploring another object's API to prototype some basic functionality using that API, it is much, much faster to do this kind of work in VB than in C++.
 

wb

Ars Legatus Legionis
25,208
Subscriptor
wb: Definitely. I will of course miss an opportunity to learn another programming language. Again, my goal is to be able to create GUI using C++. That class teaches Visual Basic. The two are irrelevant with respect to GUI programming using C++.

I think you're missing my point, which is that even if you don't learn specifically how to do it in C++ in the class, you will learn many things about GUI programming which you can apply in any language, including C++, which will in turn make you a better C++ programmer. I get the feeling that you don't really understand the concept of education. By focusing on C++ so intently (which is commendable, committing to an ideal), you're missing a lot of things which will make you a better programmer in general, and make the development of your C++ skills come easier. I'm talking about knowledge not specific to any programming language, that will make it easier for you to write the C++ code you're so intent on developing.
 

AlphaMeridian

Ars Legatus Legionis
17,136
Moderator
While I share your same commitment and love for C++, (as i truthfully enjoy learning the lanugage and using it) i have to realize that as time progresses, other languages will come and take the forefront, which is pushing me to learn other kinds of languages, (perl, VB, Java), and it will be one day when experience with these other languages are required by businesses to get a job in programming (hopefully, i'll be in EE tho)

-Alpha
 

russ-iha

Ars Praefectus
4,407
Subscriptor
I'd vote to stick with the VB class to learn the basics of Windows GUI programming. Its a good way to get an initial handle on the concepts of Windows, what properties they can have, how to layout controls for maximum visual appeal, and other such things without getting your hands dirty.

Then, you can go back into C++ and try to recreate your efforts. Only now you don't have to wonder if that text box can have no border, multiline, with verticle scroll bar. You will already know that and can just look for the right way to make that happen from MFC or whatever it is that you are using.


At the very least, it will give you a good jumping point. Plus VB is very easy to pickup so it should be an easy "A" class :D
 
Many members responded to this topic conveying that I am limiting my horizon by not wanting to learn other programming languages such as VB and Java.

One person made a point that employers want their programmers to be dynamic. They want their programmers to know many language. That is conceivable. I understand fully how employers want their programmers to by dynamic including knowing many programming language.

My goal has always been to be the best that I can possibly be in one language. It think it is time consuming and maybe even impossible to know all languages extremely well and be able to produce anything with every language. I believe each programmer is good with one specific language. An employer turn to that programmer when it wants a specific job done in a specific language. My goal is to be the best that I can be with one language, first and foremost, and that is C++.

As for the VB GUI class, I still have the option of either taking that class or taking a beginner Java. I would rather learn Java because, as many members have said, I will get a clearer grasp of OOP using C++ after I experience Java.

I am basically stuck with not knowing GUI programming until someone release a book about GUI and Visual C++ .NET.

Kuphryn
 

WeaselGod

Wise, Aged Ars Veteran
101
As for the VB GUI class, I still have the option of either taking that class or taking a beginner Java. I would rather learn Java because, as many members have said, I will get a clearer grasp of OOP using C++ after I experience Java.

Good choice. VB has changed significantly with VS.net so a lot of what you would have learned in the class would be obsolete.

I am basically stuck with not knowing GUI programming until someone release a book about GUI and Visual C++ .NET.

This isn't a bad thing. The gui tools for VC++ in .net are many magnitudes better then the ones in previous versions. The IDE is also considerably different so in the long run just waiting until .net to learn all of this will save you some time (though you will probably still end up using a pre .net version of VS for at least some things in the work place).

- WG
 

wb

Ars Legatus Legionis
25,208
Subscriptor
I am basically stuck with not knowing GUI programming until someone release a book about GUI and Visual C++ .NET.

What? If you want to learn about GUI programming, just start writing a program with a GUI, and you'll figure things out as you go. Then, when a book comes out it will be much easier for you to apply the knowledge contained therein. The first windows (GUI) program I wrote I was living in Japan with no internet access and the only documentation I had was header files, yet somehow I managed to turn out functioning programs<SUP>*</SUP>.

This is not to mention that there is a HUGE mountain of information about C++ GUI development on the MSDN website, free for the taking.


Notes:
<SUP>*</SUP> I didn't spend too much time programming in Japan, but I wrote an XEyes-like program and a fractal exploration program when I was sick one week.
 
Going back to my original question about GUI. Again, my goal is to learn GUI programming using C++ specifically even though I know GUI is easy with Visual Basic. Really, I would prefer to take the Java course instead of the other choice, VB.

Since I am enrolled in this VB course and that fact that the college requires that I take either this VB course or the Java, I am starting to see maybe it is wiser to just go through with the VB since *it will eliminate a burden*. If not, I will have to enroll in the Java course next semester since the college requires that I take one or the other. Do you guys see my point?

I do want to learn Java. I hear a lot of members say that Java is fun and that it really helps them get a clear sight of OOP when then program in C++. As far as I am concern, anything that helps further my understanding and experience with C++ is a plus.

Kuphryn

Note: I still have no decided if I should drop. Class starts on Monday. The good news is that class meets once a week on Friday for five hours. I have until Friday to decide on the class. That is good because I am taking six classes. I see get to see if I can even hand the sixth (VB) on Friday. It's almost like a win-win situation even though the class it not something I anticipate.
 

xeraae

Wise, Aged Ars Veteran
132
Here's my experience.

Freshman year HS I learned C, then picked up C++.. Like you I really love C++.

During Junior year HS I had a class in VB. It was kinda fun to make GUI apps and stuff, but it seemed completely different than programming in C++. You draw a text box, open the text box's function and put code in it. It was harder to see the flow of the program in the way you can follow something in C++. It was all really high level and abstract. IMHO...

When I learned java senior year HS, I got a better idea of how a C++ program would control a GUI program, since Java also has a main method, and looks similar to C++ in construct. I also felt like I had more control and a better understanding of how my programs were running. I could write a whole GUI program with just text, as opposed to using the visual VB editor. (I'm sure you can do the same with VB, just never cared to learn how)

Finally, in my school java is currently used for graphics and multimedia (CS 335), it is a choice along with C++ in algorithms (CS 315), and can be used in a lot of other classes, so for me it was worthwile to learn and useful enough... even though I ultimately prefer C++.

Edit: If you're just gonna drop VB and not take anything else, might as well learn VB as long as it's not too much load. Better that than nothing, I say. :)
 
At work, I wrote a GUI engine for an embedded device because loading QT or MFC onto that greatly underpowered device will kill the poor beast(although QT-Embedded might have worked.).

I drew quite a lot of concepts (I think most people call it "pattern")
from other GUI libraries, in particular Java and QT.

So, if you are intent on building a C++ GUI, I will suggest you study APIs of different GUI libraries even if they are not written in your favorite language.

I admire your devotion to the C++ language. However, Understanding the strength and weakness of other languages by practicing them will not harm your appreciate for the C++ language. It will make you appreciate the design decision that goes into making C++.

If you want to be an excellent C++ programmer, you must first stop being closed-minded.
 
I definitely understand the importance of knowing multiple programming languages and being able to use them to solve relevant problems.

I believe I have present myself as a closed-minded C++ maniac who rejects all other language. That is completely not true.

I am such a fanatic about C++ because I have put so much energy into C++ ever since the beginning of the fall semester when I first started programming in C++ (within the last five months). I have done great things with it, and based on my experience, I know I so develope so much more just with C++ because it is so extensive. To me, designing and implementing programs using C++ is like reaching for the stars. I am not afraid to learn any new language. The reason I enjoy C++ so much is because I have not encountered anything I cannot accomplish with C++. Although some program are quite tedious if I use C++, but it can be done in a relatively easy way (unlike ASM). Anyways, I wanted to clarify my reason for being so excited about C++.

Here is something I have not mentioned. I began learning programming and programming on a serious level last fall when I signed up for the C++ course; however, I was interested in Visual Basic three years ago when I was in high school. A family member bought me a Visual Basic in 21 Days. I lost interest at like the 8th day. The reason I lost interest with Visual Basic was because I learn absolutely nothing about *programming* basic. The only thing I really learned was how to setup the GUI. Setting up GUI in Visual Basic was very easy, but they that was it. I could not code anything behind the GUI.

Here I am, three years later, and is ready to attack any problem using C++ (with respect to my experience). Yet, I cannot replicate that same GUI so I can put the code behind it. Ironic!!!

Anyways, I will learn Java soon, probably in this coming fall semester. However, my goal still stands at learning GUI programming using C++. That is like a huge accomplishment for me. I feel that once I can develope a complete C++ program including the GUI, I can do anything with any other language (except maybe ASM) easily.

Thanks,
Kuphryn
 

FriarPuck

Ars Praefectus
4,053
Subscriptor
I still think you are kind of missing the point.

They are not suggesting you take the VB/GUI class just for the saking of knowing VB. A good computer science education will teach you computer science concepts without regard to language. In that respect VB is a good way to learn GUI programming because it's simplicity and power when it comes to developing GUIs. Hopefully what you will take away from the GUI class is an understanding of how GUIs work and how GUI programming is done. You can then take that knowledge and apply it to C++ or Java or whatever.

Learning a language and being proficient in it are good things, however what is more important is that you understand programming concepts.
 

wb

Ars Legatus Legionis
25,208
Subscriptor
I think there should be a college course emphasis GUI Programming using C++. That way, the person can implement real code behind the GUI. I doubt I will produce anything productive program through VB GUI. I will learn the fundamentals of GUI in windows.

As has been stated on this forum before, both VB and C++ are turing-complete languages. Anything you can do in C++, you can do in VB. I've implemented some rather complex functionality in VB (the code behind the GUI) and I'm sure you can too. It's my guess that when you were programming VB stuff before, you didn't have enough programming expertise to understand what/how to make exciting stuff happen behind the interface, but now that you've got a little more experience under your belt, you will have no trouble using VB to make useful programs.
 
Status
Not open for further replies.