Nov 10, 2007

Useful Eclipse plug-ins for C++ Developers

With this post I would like to share my preferences of plug-ins for Eclipse.
Most of the time I do a C++ development (mostly under Linux). Since I came from Windows world and I was using the best development environment ever made - MS Visual Studio :) I wanted to find something similar in the Linux world. I tried emacs, KDevelop and Eclipse. I wont compare all of them, probably I will do that some time later, I will just conclude that I choose Eclipse and CDT.
Well, currently I am suing the following useful plug-ins:
Also I don't use the original code formating mechanism of Eclipse CDT, rather I use AStyle as an external tool, which is much more powerful. Here I have an instraction for you how to use AStyle in Eclipse:
  • Select the dropdown button for "External Tools", then click on "Externals Tools..."
  • Select "Program" in the Configurations window then click the New button
  • For the "Name" call it "AStyle", for the "Location" put the full path and filename for AStyle (i.e. /usr/bin/astyle)
  • For "Arguments", put the AStyle arguments to get the code formatted to your style. I like ANSI style and 3 spaces for indentation, hence, the arguments would be "--style=ansi -s3" (no quotes) or use --options=####
  • Now put your cursor at the end of the "Arguments" and click the "Variables" button and then select the resource_loc" and click OK
  • Your arguments should look like "--style=ansi -s3 ${resource_loc}" (no quotes)
  • Now click the "Refresh" tab, and click the check-box "Refresh resources upon completion" and then click the "The Selected Resource" radio button.
  • Click the "Apply" button then the "Close" button.

No comments: