473,466 Members | 1,416 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

C++ Advise

Hello!

I’m new to this forum and in need of some advice.

I have learned the basics of java in the school as I’m studying
computer science. I would rather learn C++ though.
You can create windows applications, games, Linux applications, its
faster, more power etc.
And you get a nice .exe file when you compile in windows. (Which java
lacks)

I have already started to read an C++ book and I’m half way through,
but when it comes to GUI applications I have some
questions I would like to clear out.

As I understand it C++ doesn’t provide a GUI library. But then we have
Windows API and Visualc++. So my questions are.
Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
I know that in VisualC++ you can just copy and paste in the design
mode to get a button but in WinAPI its lines of code.

And another problem is that many C++ books don't even mention the GUI.
Don't even know if there are books about it.
Are there more libraries that one should be aware of?
In other hand C++ is an "old" language compared to java, C#, VB but
it’s still is the most powerful one (my opinion).
Thanks in advance

Nov 18 '08 #1
10 1912
On Nov 18, 2:53*pm, Allonii <allo...@hotmail.comwrote:
Hello!

I’m new to this forum and in need of some advice.

I have learned the basics of java in the school as I’m studying
computer science. I would rather learn C++ though.
You can create windows applications, games, Linux applications, its
faster, more power etc.
And you get a nice .exe file when you compile in windows. (Which java
lacks)

I have already started to read an C++ book and I’m half way through,
but when it comes to GUI applications I have some
questions I would like to clear out.

As I understand it C++ doesn’t provide a GUI library.
Yes, the language doesn’t provide a GUI library.
But then we have
Windows API and Visualc++. So my questions are.
Please go to the comp.os.ms-windows.programmer.win32 or like this.
Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
False. It depends on your task.
I know that in VisualC++ you can just copy and paste in the design
mode to get a button but in WinAPI its lines of code.

And another problem is that many C++ books don't even mention the GUI.
Probably you need book about GUI programming (as I understand, for
Windows) not book about C++.
In other hand C++ is an "old" language compared to java, C#, VB but
it’s still is the most powerful one (my opinion).
Hmmm. What's mean powerful? Again, it depends on your needs. Sometime
it is powerfull. Sometimes not.
Nov 18 '08 #2
Allonii <al*****@hotmail.comwrote:

>Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
I know that in VisualC++ you can just copy and paste in the design
mode to get a button but in WinAPI its lines of code.
Visual C++ is Microsoft's implementation of the C++ language. The
Windows API comprises the functions built in to Windows that you
*must* use to write a Windows application. You're probably seeing code
written using MFC (Microsoft Foundation Classes), a set of classes
that comes with VC++ that wrap many of the API functions and make
writing Windows applications easier.

The proper place to ask questions about writing Windows apps is the
microsoft.public.vc.* hierarchy.

--
Tim Slattery
Sl********@bls.gov
http://members.cox.net/slatteryt
Nov 18 '08 #3
Hello,

Allonii wrote:
As I understand it C++ doesn’t provide a GUI library. But then we have
Windows API and Visualc++. So my questions are.
If you do not have a special reason to go for the Windows API, I'd
suggest that you learn some ClassLibrary, which is easier to use.
For example Qt ( http://trolltech.com/products/appdev ) or Gtk.
I am using Qt since years, sometimes developing under Windows,
sometimes under Linux, sometimes for the Mac.
I do not care. Qt does it all.
Example:
int main(int nArgCount, char** ppSzArgs)
{
QApplication app(nArgCount, ppszArgs);
QPushButton button("Press me");
connect(&button, SIGNAL(clicked() ),
&app, SLOT(quit() ) );
return app.exec();
}

This would create a button, complete with event loop, text, clickable.
And if you click it, it will send a message to the application
which will end the queue...
Same Sourcecode for all platforms.

Building ?
- qmake
- make
done.

Just a suggestion.
Andreas
Nov 18 '08 #4
On 2008-11-18 09:18:44 -0500, Tim Slattery <Sl********@bls.govsaid:
Allonii <al*****@hotmail.comwrote:

>Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
I know that in VisualC++ you can just copy and paste in the design
mode to get a button but in WinAPI its lines of code.

Visual C++ is Microsoft's implementation of the C++ language. The
Windows API comprises the functions built in to Windows that you
*must* use to write a Windows application.
Only if "WIndows application" means windowing application, as distinct
from "applicatton that runs on Windows". You don't need any of the
Windows API to write a standard-conforming C++ application (i.e an
application that runs from the command line).

--
Pete
Roundhouse Consulting, Ltd. (www.versatilecoding.com) Author of "The
Standard C++ Library Extensions: a Tutorial and Reference
(www.petebecker.com/tr1book)

Nov 18 '08 #5
On Tue, 18 Nov 2008 12:53:48 +0100, Allonii <al*****@hotmail.comwrote:
[...]Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
I know that in VisualC++ you can just copy and paste in the design
mode to get a button but in WinAPI its lines of code.

And another problem is that many C++ books don't even mention the GUI.
Don't even know if there are books about it.
Are there more libraries that one should be aware of?
Another idea is to separate components and use the most suitable language
to implement them. If you need speed for example you could create a native
Windows DLL in C++. If you need a GUI you could use the .NET platform and
create a .NET executable (for example with C++/CLI if you prefer to use
something similar to C++) which can access the native Windows DLL. That
way you are not stuck in a certain language but can choose whatever is
best.

Boris
Nov 18 '08 #6
Pete Becker <pe**@versatilecoding.comwrote:
>Only if "WIndows application" means windowing application, as distinct
from "applicatton that runs on Windows". You don't need any of the
Windows API to write a standard-conforming C++ application (i.e an
application that runs from the command line).
Agreed, you can write a command-line app for windows using only
standard C++, no Windows API call involved. You do have to use the API
for a GUI application.

--
Tim Slattery
Sl********@bls.gov
http://members.cox.net/slatteryt
Nov 18 '08 #7
On 2008-11-18 12:53, Allonii wrote:
Hello!

I’m new to this forum and in need of some advice.

I have learned the basics of java in the school as I’m studying
computer science. I would rather learn C++ though.
You can create windows applications, games, Linux applications, its
faster, more power etc.
And you get a nice .exe file when you compile in windows. (Which java
lacks)
You can compile Java code to native binaries too, it's just not how it's
usually done.
As I understand it C++ doesn’t provide a GUI library. But then we have
Windows API and Visualc++. So my questions are.
Not in the C++ standard, no. But there are many GUI libraries available
for C++ programmers, some are platform-specific and others works on many
platforms (such as Qt, wxWidgets, Gtk, etc.).
Windows API and VisualC++ they don't seem to be using the same
library? Windows API is it too old to be using today?
When you create GUI applications in VC++ it is usually a MFC
applications or a .Net application. MFC is a layer on top of the WinAPI
which should make it easier to write GUI applications, and .Net
applications are managed and not written in C++. Of course, if you want
you can also use the WinAPI directly.

The latest version of MFC was released with VS2008 and the WinAPI is
constantly updated with each version/service pack of Windows, so while
both have been around for a number of years none of them are by any
means obsolete.
And another problem is that many C++ books don't even mention the GUI.
That might be because C++ is complex enough to fill a whole book without
even getting close to GUI programming. And also, GUI programming is
complex enough that you should read a book dedicated to the subject.
Don't even know if there are books about it.
There are lots, but you need to decide what GUI library/API you want to use.
Are there more libraries that one should be aware of?
As mentioned earlier there are more libraries that provides GUI
capabilities and many have the benefit of working on multiple platforms
so it might be worth taking a look at them also before deciding which to
learn.

--
Erik Wikström
Nov 18 '08 #8

Thanks for all the replays
Not in the C++ standard, no. But there are many GUI libraries available
for C++ programmers, some are platform-specific and others works on many
platforms (such as Qt, wxWidgets, Gtk, etc.).
So I know none of them, which one would be more easy to learn? And
that not have played alot with ISO C++. If you recommend one could you
also please give me a good ebookk to read?
What about C++/CLI the VSC++ is using?

Thanks
Nov 19 '08 #9
Allonii wrote:
Thanks for all the replays
>Not in the C++ standard, no. But there are many GUI libraries available
for C++ programmers, some are platform-specific and others works on many
platforms (such as Qt, wxWidgets, Gtk, etc.).

So I know none of them, which one would be more easy to learn? And
that not have played alot with ISO C++. If you recommend one could you
also please give me a good ebookk to read?
What about C++/CLI the VSC++ is using?
C++/CLI is *NOT* C++.
Nov 19 '08 #10
On 19 Nov., 09:50, Allonii <allo...@hotmail.comwrote:
Thanks for all the replays
Not in the C++ standard, no. But there are many GUI libraries available
for C++ programmers, some are platform-specific and others works on many
platforms (such as Qt, wxWidgets, Gtk, etc.).

So I know none of them, which one would be more easy to learn? And
that not have played alot with ISO C++. If you recommend one could you
also please give me a good ebookk to read?
What about C++/CLI the VSC++ is using?

Thanks
I can recommend Qt, because it is quite easy to use, and the (free
online) Documentation is great. wxWindows seems to be quite popular,
too, but I lack first hand experience. Gtk is a C lib but a full-
featured(?) C++ wrapper exists (gtkmm).

To find out which Library suits you, I would suggest that you read the
Tutorials or "Getting Started" Sections of the respective Libraries
Websites. (For qt this would be http://doc.trolltech.com/4.4/tutorials.html)
Nov 19 '08 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: GM | last post by:
Hello... Please advise me where can I post a message about job seeking for the small developers team (ASP, XML/XSLT, *script skills)? Thanks a lot ahead. Please, advise me to:...
0
by: Girish Agarwal | last post by:
--0-474210375-1058976151=:31789 Content-Type: text/plain; charset=us-ascii Content-Id: Content-Disposition: inline Note: forwarded message attached. __________________________________
1
by: Question | last post by:
I am making a custom small menu which is most basic. Problem is that I can't make the first step work for some reason. I have an image to the left of where would be the layer positioned. This...
3
by: Michael Crawford | last post by:
Hi, Where would one start for this type of application: I want to create an vb.net container application that has the gives the end user the ability to install and uninstall plugins or add-in...
1
by: artifact | last post by:
Hello Can anyone tell me what is the best way to persist a complex object across postbacks in ASP.NET eg * I have a Person class with methods to edit the person's info * I navigate to my...
4
by: Craig Kenisston | last post by:
Hi, I'm an ex-Delphi developer and I'm used to the ModelMaker Case tool for Delphi. Now I'm starting a large project in C# and I need some help in design. I'm looking for case tools for...
0
by: serge calderara | last post by:
Dear all, I need to collect different type of data. Source of those data are CSV files and Access database. I am thinking on the way I should retrive those data under my VB.NET application in...
1
by: serge calderara | last post by:
Dear all, I need to create an application which is able at the end to generate reports based on SQL server data table. Actually it is hard to decide if I have to go for a simple Windows...
0
by: User | last post by:
Hi everyone, Right now, one of our client have an in-house system which stores customer profiles / data. We are building an external web based system for them which also houses the same...
13
by: Alexander Vasilevsky | last post by:
What ASP.Net hosting you advise me? http://www.alvas.net - Audio tools for C# and VB.Net developers
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.