Jump to content
Sign in to follow this  
dino_bosnia

C++ IDE

Recommended Posts

Hi.

 

I use to do some programming on Windows (C++ + C#)

 

I want to start with C++ programming on Linux.

What should I use?

Is there any IDE?

What lib should I use?

 

What is Qt?

 

Any tutorials about Linux C++ programming?

Edited by dino_bosnia

Share this post


Link to post
Share on other sites

two excellent ide's that I would recommend are either Anjuta or KDevelop. Anjuta is an excellent general C/C++ ide that is made for gnome. KDevelop is another one that is made specifically for kde and qt. The advantage to KDevelop is that it is on the Mandrake cd's.

 

As for tutorials, I would actually recommend getting a book on the subject. Also, how much do you know about Object-Oriented programming?

Share this post


Link to post
Share on other sites

Eclipse has a C++-plugin, but uit could be slow sometimes. It's written completely in java and I used it already and it is VERY nice, certainly for java .. but it has a C++-plugin, maybe worth trying out.

 

I was thinking about why not compiling the eclipse-code with gcj...That would maybe make it not so slow at times.

Edited by Michel

Share this post


Link to post
Share on other sites
As for tutorials, I would actually recommend getting a book on the subject. Also, how much do you know about Object-Oriented programming?

I did try (just now) Kdevelop and Qt designer, and I think I can deal with them :)

 

I have some experience with Object-Oriented programming ,C++ and C#, (and PHP, but I think that PHP 4.x programming is not really OO).

 

So I know the basics of Object-Oriented progamming.

 

Which book do u find a good enough for start (I am reading Qt manual now)?

Share this post


Link to post
Share on other sites

I don't know of any particular title. The one that I have is called Absolute C++ by Savitch, It is a good overview of the language with sections on most of the popular topics -- inheritance, polymorphism, overloading, etc.

 

Beginners Guide to C++ from Wrox Press is probably another excellent book. I have not read it, but I have several other wrox books and they have been excellent. I have also heard nothing but good things regarding various wrox books so they are usually a safe bet.

 

Anyway, hope that helps.

Share this post


Link to post
Share on other sites

I dont know anything about QT, but there is another option -- GTK

 

GTK is the other major GUI Toolkit. It is the one used in GNOME, Evolution, GAIM, Abiword, Mozilla, XMMS, GIMP and many major programs.

 

You can find out more at www.gtk.org

It is crossplatform and the documentation is excellent. The tutorial is here. It is well written and easy to understand

http://gtk.org/tutorial/

 

As for your editor, there are a number of great editors, Cooledit (my fave), bluefish, anjuta, vim (gvim is good too), emacs and more.

 

Anjuta is a IDE for GTK, the equivalent of Kdevelop for QT.

 

Have a look at both GTK and QT, how they work then pick whichever you like most (GTK :D).

 

All of the above are in the urpmi sources

 

Good luck

Edited by iphitus

Share this post


Link to post
Share on other sites

My husband's wanting to programme C++ on our linux box. I'm running 9.2, and I've tried installing both kdevelop and anjuta (I run KDE) and they both borked on the dependencies. I've got gcc etc installed, so is there either a) another UI for C++ or B) a way for him to compile from the command line?

Share this post


Link to post
Share on other sites

If you are running Mandrake 9.2 (or any recent version of Mandrake) KDevelop is supplied on the install CD's. You should be able to simply go to the package manager and install it. It will tell you that it needs to install about a hundred different packages to support dependencies, but it should install.

 

As for the actual question, yes you can compile from the command line. Instead of using gcc use g++. Most of the options are the same for gcc and g++.

 

Another suggestion for an IDE is Emacs or VIM. Both are excellent editors with a lot of powerfull features when used for C++ programming. They do take a little getting used to though.

Share this post


Link to post
Share on other sites
If you are running Mandrake 9.2 (or any recent version of Mandrake) KDevelop is supplied on the install CD's. You should be able to simply go to the package manager and install it. It will tell you that it needs to install about a hundred different packages to support dependencies, but it should install.

I think 'should' is the operative word B) It came up with the incredibly helpful 'the following packages could not be installed', and when I tried to settle the dependencies it just couldn't install them full stop. LibXinerama.so.1 was the crunch on both installs.

 

How do you compile and then execute from the command line (I really do know nothing about this sort of thing, and the last time my husband tried programming was on a Spectrum :D )?

Share this post


Link to post
Share on other sites
If you are running Mandrake 9.2 (or any recent version of Mandrake) KDevelop is supplied on the install CD's. You should be able to simply go to the package manager and install it. It will tell you that it needs to install about a hundred different packages to support dependencies, but it should install.

I think 'should' is the operative word B) It came up with the incredibly helpful 'the following packages could not be installed', and when I tried to settle the dependencies it just couldn't install them full stop. LibXinerama.so.1 was the crunch on both installs.

 

How do you compile and then execute from the command line (I really do know nothing about this sort of thing, and the last time my husband tried programming was on a Spectrum :D )?

hello.cpp

#include <iostream>
using namespace std;

int main()
{
cout << "Hello World! \n";
return 0;
}

 

open up a terminal window, cd to the directory with the .cpp file in it.

g++ -o hello hello.cpp

this will create a executable file called "hello" from the hello.cpp source file.

then type "./hello" (without quotes) to run the file.

 

fine for starting c++ but when you get bigger project you will want to use the "make" utility.

Edited by johnnyv

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...