Can Emacs do everything C++ that Codeblocks can do?

I have used Emacs on and off for years. (mostly it's been off). I know basic stuff like how to open and close a file - I use emacs to edit e.g. rc.conf and other system files.

I am also into programming as a hobby and have used mainly codeblocks for this. However, I am thinking of going radical and just using console tools from now on, i.e. no X windows and no codeblocks.

There has been a lot written about Emacs - it can do almost anything - but I have always found it complex to use. How could anyone remember all those commands??? Do people really use Emacs for serious coding work? I am going to be using the sfml library in a project I'm working on and was wondering how complex the commands would be to compile stuff. I don't know anything about make files - would I have to learn about them?

In short, do you think it is a good or bad idea to attempt to use Emacs as a IDE rather than Codeblocks???
 
neilms said:
Do people really use Emacs for serious coding work?
Yes, and I know a number of them including myself though I, too, tend to get off the wagon and forget everything.
In short, do you think it is a good or bad idea to attempt to use Emacs as a IDE rather than Codeblocks?
Same answer. There are thousands who do. Codeblocks is prepackaged for you. Emacs requires you to put it together yourself. Just like Windows. It's easier to start using than FreeBSD but you can do so much more with FreeBSD.
 
neilms said:
However, I am thinking of going radical and just using console tools from now on, i.e. no X windows and no codeblocks.

Why would you limit yourself to resolution of standard terminal? Specially when emacs has bindings for X server and even popular toolkits like GTK+ to maximize the display capabilities of your system. IMHO it is a waste of time and nerves, you will not learn anything new than just running emacs in X mode or even just running in terminal mode, but on a terminal emulator within X. It is like buying an iPad to use it as a calculator, not practical.
 
expl said:
Why would you limit yourself to resolution of standard terminal? Specially when emacs has bindings for X server and even popular toolkits like GTK+ to maximize the display capabilities of your system. IMHO it is a waste of time and nerves, you will not learn anything new than just running emacs in X mode or even just running in terminal mode, but on a terminal emulator within X. It is like buying an iPad to use it as a calculator, not practical.

What is the advantage of running emacs in X windows? None - apart from the fact that a user can select menu options with a mouse. You are misguided and IMO you are wrong. By running emacs in console mode, it will no doubt enable me to get to grips with all the relevant commands. You know - sometimes X windows is not available for one reason or another. If I run emacs in console mode, I know that I will learn how to (for example) link third party libraries into my code on the command line. I do not know how to do this now as I use a GUI IDE. So I consider that you are incorrect in your assertion.:stud
 
neilms said:
What is the advantage of running emacs in X windows? None - apart from the fact that a user can select menu options with a mouse. You are misguided and IMO you are wrong. By running emacs in console mode, it will no doubt enable me to get to grips with all the relevant commands. You know - sometimes X windows is not available for one reason or another. If I run emacs in console mode, I know that I will learn how to (for example) link third party libraries into my code on the command line. I do not know how to do this now as I use a GUI IDE. So I consider that you are incorrect in your assertion.:stud


You know, sometimes Emacs is not available for one reason or another. You should do all your programming with ed.
 
I use Emacs since 10+ years for pretty much all stuff. I have to admit that it is quite complex to learn, but it is extremely powerful and has a lot of features. I use it for editing configuration files, do script programming and even some C++/Java programming, but here I prefer I real IDE that can give me some more specialized tools. I'm impressed with the speed of Emacs, I mean even opening very large files the search go faster than any other editor. Oh, and by the way, just to name one, the Eclipse IDE is still lacking the "split editor" feature that Emacs can do in any direction (it will be added to the next upstream release of Eclipse).
 
neilms said:
What is the advantage of running emacs in X windows? None - apart from the fact that a user can select menu options with a mouse.

You say there is no advantage of running in X? How about going way way above the standard VGA text resolution of pathetic "80×30"? Its you who is very misinformed... You can run the emacs without the X bindings if you want that is a matter of preference and taste but running it from X terminal emulator is essential to achieve high text resolution or you are hamstring yourself and wasting your hardware running it in 80s compatibility mode.

neilms said:
By running emacs in console mode, it will no doubt enable me to get to grips with all the relevant commands.

Have you heard that terminal emulators have been invented? Have you been living in a cave for last 20 years?

neilms said:
I do not know how to do this now as I use a GUI IDE.

Don't blame your IDE for your lack of knowledge and understanding how it works. All major IDEs provide you with ability to alter building and linking configuration (would be very impractical if they wouldn't). Also if you think that automated build from the box alters your effectiveness of learning how building tools work keep in mind that IDEs are for aiding programmers in their developing process not teaching them about it...
 
neilms said:
What is the advantage of running emacs in X windows? None - apart from the fact that a user can select menu options with a mouse.

One reason I prefer to run in X is that I can use docview to display documents such as dvi or PDF files. I'll have the window split with latex code in one buffer and the resulting document beside the code in another buffer. When I compile the code I can see the changes.

Some other (subjective) advantages I can think of are:
you can have multiple frames, as already mentioned there are nicer fonts and colours and the X clipboard is accessible.

You don't really have to completely choose to only run in the terminal or X. With daemon mode, you can run both a terminal and X client working on the same buffers at the same time, so you can compare the different options.

P.S. If the menu and tools bars are too much of a temptation, you can turn them off with

Code:
M-x tool-bar-mode
M-x menu-bar-mode
 
If you can get away with using just the terminal, I say go for it! Then you don't need to mess about with broken WMs, terminal emulators and things. Also allows for seemless development over SSH which is always a bonus.

However, much code these days has been written by github kiddies who dont understand why their line length is unmanagable when they look at it through Visual Studio on their 50 inch monitor ;)
 
fluca1978 said:
...but here I prefer I real IDE that can give me some more specialized tools.
I'm sure a real emacs person would probably smack you about the head for that statement. I knew enough people who say emacs runs rings around Visual Studio that they would be insulted.
 
kpedersen said:
Then you don't need to mess about with broken WMs, terminal emulators and things.

Define 'broken'.

kpedersen said:
Also allows for seemless development over SSH which is always a bonus.

What does SSH have to do with development from a VGA console? You can also do that from a terminal emulator with a huge text resolution.
 
drhowarddrfine said:
I'm sure a real emacs person would probably smack you about the head for that statement. I knew enough people who say emacs runs rings around Visual Studio that they would be insulted.

emacs is a text editor not an IDE. You can create an IDE(ish) environment using emacs, but you can't compare it directly to any specific IDE as it would be like comparing oranges and apples.

P.S.
Some IDEs like Eclipse have emacs plugins for actual code editing.
 
expl said:
Define 'broken'.
The more software you have running, the more things can break. If you can cut as much as you can out, then less can break lol.
Also, as I recall, Mwm had a really annoying freeze issue with one of the versions of Xorg in ports about a year back. And if something as simple (and old/stable) as Mwm can break, then I don't trust much else ;)

expl said:
What does SSH have to do with development from a VGA console? You can also do that from a terminal emulator with a huge text resolution.
Probably not much but if you can replicate the server environment on your development machine as much as possible then that is sometimes a bonus. For example Windows server, although they went the wrong way and made the server OS more like a desktop haha.
 
kpedersen said:
The more software you have running, the more things can break. If you can cut as much as you can out, then less can break lol.
Also, as I recall, Mwm had a really annoying freeze issue with one of the versions of Xorg in ports about a year back. And if something as simple (and old/stable) as Mwm can break, then I don't trust much else ;)

If you think like that then you are better off writing code with pen and paper. No software - no software to break.

kpedersen said:
Probably not much but if you can replicate the server environment on your development machine as much as possible then that is sometimes a bonus. For example Windows server, although they went the wrong way and made the server OS more like a desktop haha.

That does not make any sense. Are you trying to say that working from a VGA console is "server environment" replication? Or you just ment writing software thats being ment to be accessed specifically from a VGA console (has nothing to do with 'server environment', again comparing apples and oranges)? If so, that means if I write software for a smart phone I have to write it WITH the smartphone?

Anyways, this is topic is going to path of silliness. My advice honest advice for neilms is, if you think that coding from console will provide you with interest and motivation then go a head do what you like. But if you have a serious interest to achieve anything serious I suggest you forget this silliness and go with time tested methods.
 
expl said:
Don't blame your IDE for your lack of knowledge and understanding how it works. All major IDEs provide you with ability to alter building and linking configuration (would be very impractical if they wouldn't). Also if you think that automated build from the box alters your effectiveness of learning how building tools work keep in mind that IDEs are for aiding programmers in their developing process not teaching them about it...

Oh, I thought that programmers could and do learn about the development process from using different IDE's. Just because it is designed for a particular purpose does not preclude someone from learning from it's use, in some way. An analogy might be to state that you should 'keep in mind that cars are for moving people from A to B not teaching them about how engines work'. But the fact is you can learn how a car engine works by studying it.

Your statement is incredibly ridiculous. If you don't like emacs that is your option. I was looking for responses from people who actually understand how to use emacs from experience rather than hearsay from the internet.
 
This thread is full of flame.

The right tool for the right job. nuff said!

ChalkBored said:
You know, sometimes Emacs is not available for one reason or another. You should do all your programming with ed.

I realize ChalkBored is just poking but there is some logic to the first part of his post. For example from one jail to the next one would have to install their preferred text editor. I most certainly don't install vim in every one of my jails.

This is why many people learn vi(1) as it's part of the base system as well as the posix definition. There is a disconnect newer users may not realize that when on groks vi they have have also grokked ed(1) by proxy.

@neilms
You need to figure out what tools work with you and in what situations you would use them. Editing rc files and programming c++ are completely different tasks. I'm not saying that you can't work one way or another or use a single program or editor for both tasks. It's up to you to find what best works with yours style in production.

Without knowing much about emacs and knowing absolutely nothing about codeblocks here is what I can think of. Look and see what feature is missing from codeblocks that you would like to see in emacs. Ask on emacs mailing lists, irc, user forums if such a plugin(macro?) exists already. If not find out what you need to learn to create the feature in emacs.

(In Before The LOCK!)
 
expl said:
emacs is a text editor not an IDE. You can create an IDE(ish) environment using emacs, but you can't compare it directly to any specific IDE as it would be like comparing oranges and apples.
And, again, I know some people who would bristle at that statement. Saying emacs is just a text editor is like saying a Ferrari is just a car. I don't know of any IDEs that contain their own programming language and can completely modify itself to where some people feel they are in their own world, when they code, and they never have to leave it.

I wish I had the in-depth knowledge to argue this point further but I don't. I've seen people with emacs that would put any IDE to shame. I do know enough that I would never say it was just a text editor.
 
drhowarddrfine said:
And, again, I know some people who would bristle at that statement. Saying emacs is just a text editor is like saying a Ferrari is just a car.


wikipedia said:
As a poke at Emacs' creeping featurism, vi advocates have been known to describe Emacs as "a great operating system, lacking only a decent editor".

Check vim
 
drhowarddrfine said:
And, again, I know some people who would bristle at that statement. Saying emacs is just a text editor is like saying a Ferrari is just a car. I don't know of any IDEs that contain their own programming language and can completely modify itself to where some people feel they are in their own world, when they code, and they never have to leave it.

I wish I had the in-depth knowledge to argue this point further but I don't. I've seen people with emacs that would put any IDE to shame. I do know enough that I would never say it was just a text editor.

Well, Emacs is a very powerful infrastructure, since it allows users to customize it, to even read mail within Emacs, develop, run some kind of IDE-tools, and so on. But today this is the same for other environments, like Eclipse, that using plugins allow users to run even external programs or to use the foundation as their own application infrastructure. What I was saying, is that sometimes a very general purpose environment like Emacs, even if customized, results much more complicated to use in a specific context than a specific tool like an ad-hoc IDE. That said, I know it is possible to use Emacs to do all the job, and when I have to connect remotely to a machine without having access to another tool I use it.
Moreover, I'm a kind of person that tries a lot of different tools just to know them and get an opinion other them, so to be able to choose the right one (for me) in each context. At the moment, Emacs is winning (that is it is used for a lot of contexts).
My opinion.

Oh, and very Emacs-people will complain about the editor not being part of the base system!;)
 
The OP like Emacs and would like to get endorsement across the board. Unfortunately, that will not happen.

I'd advise...grow up. Get on to a decent project (get a job if you don't have one) where projects are handled large sized teams, delivery timelines, QA pressures, documentation and process compliance etc. God help you if the project is an inherited code base. The real utility of an IDE will be felt then....for one realizes then that professional software development is much more that writing code and time is a premium there.
 
SR_Ind said:
Get on to a decent project (get a job if you don't have one) where projects are handled large sized teams, delivery timelines, QA pressures, documentation and process compliance etc. God help you if the project is an inherited code base. The real utility of an IDE will be felt then....for one realizes then that professional software development is much more that writing code and time is a premium there.

I think I'm in such kind of situation, and while I admit that an IDE can do a lot of stuff and simplify the development, I still use Emacs for a lot of tasks. I don't see any conflict or waste of time, on the other hand I can see my colleagues not able to edit a source file on a remote server without their IDE....
 
fluca1978 said:
I think I'm in such kind of situation, and while I admit that an IDE can do a lot of stuff and simplify the development, I still use Emacs for a lot of tasks. I don't see any conflict or waste of time, on the other hand I can see my colleagues not able to edit a source file on a remote server without their IDE....

Well that's obvious. If they are using just the IDE, then they'd require an IDE.

I use vi or nano/ee if I need to edit a text file on a remote *NIX server.

And

I use an IDE if I need to run through a complete code, refactor, build, debug, source check ins and relase cycle within a project...local or remote doesn't matter.

I still have some colleagues that use ancient MS Visual C++ 6 with FTP Commander and PutTY to manage C/C++ development on remote *NIX servers.

Are we mixing two use cases here? Editing text files versus GUI assisted Software Development Life Cycle?
 
Just my take on a random selection of comments and questions raised in this thread:

"Do people use Emacs for serious coding?"

Yes. I myself use Emacs for writing and compiling La/Con/TeX(t) documents, performing statistical analysis in R, and messing around with E/Lisp (ok, so the last one isn't all that serious... yet).

"There is no advantage to running Emacs in X."

Falsch. Image-dired and docview mode depend on X, and twittering-mode and EMMS (Emacs Multimedia System) certainly use X display capabilities to good effect.

"Emacs is subject to feauturism/bloat."

I can see why people might see it that way, but for me, the extensibility of Emacs is one of its most attractive aspects. Getting to grips with Emacs is, as other posters have rightly pointed out, at the very least a rather involved process. But so too is getting to grips with Vi(m). The difference with Emacs is that if you learn the shortcuts, commands, and typical behaviors of Emacs in general, then you can -- by extending Emacs -- use that knowledge when performing tasks like reading and writing emails, listening to music, programming, posting on Twitter, browsing the web, etc. etc. Having a consistent interface for a wide variety of tasks is very economical.

But, you could argue, that it's not at all economical to have one application that tries to do everything -- surely, there are going to be some things that it just isn't suited for. I totally agree with this principle, and it's one of the reasons I think that projects like Google Chrome OS (or whatever it's called) are so misguided. Projects like that attempt to use, for example, web languages and technologies to do things -- e.g. word-processing -- that there far more mature, stable, and efficient apps do far, far better.

The thing is, people who write new modes or "apps" for Emacs typically recognize this. If we take EMMS as an example, we can see how it leverages Emacs for things that it's good at (text editing/display, command/shortcut interface, etc.), and outside applications for what they're good at. EMMS doesn't use Emacs to attempt to "play" your music, or even read song/artist/album info from file metadata; it leaves that up to mplayer (as one option) and mp3/ogginfo respectively. It can even use MPD as a backend to speed up performance when it comes to, for example, retrieving track information.

Most extensions to Emacs adhere to the above approach, although there are some like the aforementioned docview -- although even that does use an external application, namely Imagemagick, to handle the stuff that Emacs isn't good at... it's just that converting from PDF/PS to .png is far from being an optimal solution.

"Emacs is complicated/difficult to learn."

As I already conceded, this is quite true. It's probably the biggest reason that Emacs isn't more widely used than it is. The learning curve is not insurmountable, though, and one thing that Emacs has in common with FreeBSD is magnificent documentation. Now I'll be honest, I came to Emacs from Vim and the first thing I did (other than playing Tetris :p ) was enable "vimpulse" -- a mode which modifies Emacs to behave in a more Vim-like way. As a result, I did very little RTFM-ing for many of the months that I have spent with Emacs. It was only after I gradually weaned myself on to doing things the Emacs way that I began to consult the online documentation. Once I did that, however, I was surprised by how quickly I learnt the basics required for cursor movement, editing, and buffer/window management.

The tutorial (accessed with C-h t or Ctrl+h ~ t) was immensely helpful, as was the Emacs Manual (C-h r or Ctrl+h ~ r), as were various blogs like "Mastering Emacs", "Emacs-fu", and Sacha Chua's "Living an Awesome Life" blog. Also worth mentioning are the "Hack Emacs" series of tutorials on Youtube by rpdillon, and the "Programothesis" channel by emailatask. Of course, learning all this stuff is pointless unless you retain it, and the best way to do that is to make a commitment to sticking with Emacs for a decent chunk of time, and using it for stuff that is actually of importance to you: whether that be keeping up with your emails, planning and managing projects of one sort or another, or what-have-you. You gotta get some long-term synaptic potentiation going on, and the only way to do that is through practice and repetition.
 
Back
Top