Additional Refactoring for Eclipse CDT - c++

Is there any way to configure or are there any 3rd party plug-ins available for Eclipse CDT (any version) that provide a rich set of refactorings? My refactoring menu only provides the following in Eclipse Indigo CDT:
Rename
Extract Constant
Extract Local Variable
Extract Function
Toggle Function Definition
Hide Method...
I am looking for something with the richness of either the Java refactorings:
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse.jdt.doc.user/concepts/concept-refactoring.htm
Or something like what DevExpress Refactor Pro offers:
http://www.devexpress.com/Products/Visual_Studio_Add-in/Refactoring/
Note that the DevExpress plug-in is not compatible with Eclipse. I am more than willing to pay for a good 3rd party plug-in (it just needs to support C++ in Eclipse).

Most of the refactoring features in Eclipse CDT are developed by people working and studying at the HSR Hochschule für Technik in Rapperswil Switzerland. There are students working on new refactorings and enhancements. After they had been reviewed they will be integrated into the official CDT.
For more information of the ongoing development get in contact with the leader of this projects Peter Sommerlad at the IFS.
Beside from this projects I think there is no other plugin/extension on the CDT platform.

I miss the additional features, too, but I guess, they are currently not available as eclipse plugins: at least I did not found any, except for announcements.
C++ is hard to parse.

Is there any way to configure or are there any 3rd party plug-ins
available for Eclipse CDT (any version) that provide a rich set of
refactorings?
Sure, it's possible. For example:
http://www.eclipse.org/articles/article.php?file=Article-Unleashing-the-Power-of-Refactoring/index.html
As far as finding exactly what you're looking for (either commercial or open source software) - and finding it for Eclipse (as opposed to simply purchasing a different IDE) - well, that's "iffy". For example, I make heavy use of Embarcadero Delphi at work. It's refactoring capabilities run RINGS around Visual Studio. Visual Studio, in turn, is far better than the default Eclipse. But hey - I use "vi" and a makefile whenever possible, so it's no big deal.
Suggestion:
Try an eval version of a major vendor's C++ compiler, and see where it takes you. Two suggestions:
Intel
http://software.intel.com/en-us/articles/intel-compilers/
IBM
http://www.ibm.com/developerworks/downloads/

Related

Best alternative for Visual C++? VS11 Express can't be used to write desktop apps

Some of you might already know that Microsoft is trying to kill desktop development in favor of Metro style apps. The express editions of the new Visual Studio 11 will only support writing Metro style apps. They also won't give you the new compilers as part of the new Windows SDK. The only way to get the compilers is to buy Visual Studio Professional or higher.
Now it's time to find an alternative (alternative compilers for the Windows platform). Any suggestions?
Some links that are related to this issue:
http://visualstudio.uservoice.com/forums/121579-visual-studio/suggestions/2645679-visual-studio-11-express-on-windows-7-and-the-abil
http://blogs.msdn.com/b/visualstudio/archive/2012/05/18/a-look-ahead-at-the-visual-studio-11-product-lineup-and-platform-support.aspx
http://www.microsoft.com/visualstudio/11/en-us/products/express
Gcc/G++ of course. In my opinion it is superior to VC++. In addition, you can use Eclipse CDT as IDE, it is quite usable at the moment (compared to older versions). I work like that on Windows. In addition, you can also work on Linux or MacOS without having to switch to another tool.
1) The Metro and WinRT features are accessible from C++/CX which in turn is built on top of COM, so according to this detailed discussion (SO question on WinRT and C) you can use the latest "Microsoft-only" features with any decent C compiler. Of couse this will require some code generation or just a lot of typing to get the access to basic facilities. I believe there would be a transition period and then the open-source community comes up with some automated solution to consume the WinRT APIs.
2) A quick list of available options right now.
Dev tools: MinGW or Cygwin (GCC toolchain + unix-like tools), Clang maybe, OpenWatcom as a thing from the past
GUI Libraries: FLTK, Qt, wxWidgets, Fox GUI toolkit, librocket (if you are into the OpenGL world)
IDEs: Code::Blocks, Eclipse+CDT, QtCreator
3) There's also a non-C++ way:
The FreePascal+Lazarus to allow Delphi-like RAD
Mono/SharpDevelop
Both options can use C++ code with some bindings.
4) Conclusions
These are the alternatives which give similar results but not always the similar level of comfort.
Yet another possibility would be Qt Creator, which comes with a full toolset targeting Windows (as well as MacOS, Linux, and Symbian). It is definitely somewhat different from VS, so it takes some getting used to, but overall I'd rate it as pretty decent. Qt (the library) generates somewhat mixed feelings -- some dislike its oddities (E.g., MOC), but quite a few consider it the best designed GUI toolkit available.
Don't forget the Netbeans GUI which is also available for windoze. It works great, just install mingw and choose this mingw/bin directory for the compiler tools and mysys/bin/make.exe as the make program
to download
https://netbeans.org/downloads/index.html
they have this plugin for vc++
http://plugins.netbeans.org/plugin/42519/vcc4n-visual-c-compiler-for-netbeans
some install info
https://netbeans.org/community/magazine/html/03/c++/
Another IDE that I havent used but looks good is
http://www.codeblocks.org/

Optimal Eclipse CDT (C++) experience in March of 2010

I am a student who will be using C++ next quarter. I really enjoyed using the Galileo release of Eclipse with Java and I would like to continue using Eclipse for for C++ development.
I am now experimenting with C++ development on Eclipse. I am running Eclipse 3.5 SR2 with CDT 6.02. My operating system is Windows 7 and I have installed MinGW-5.1.6. Version 6.3 of GDB is installed.
I have it compiling and stepping through code. However, I have the suspicion that I'm just crawling along and have yet to "shift the car out of first gear". I've spent about a week poking around on the Web to learn what constitutes and "optimal" C++ Eclipse experience. In particular, I'm interested in round-tripping with UML and unit testing.
My exploration of the Web became an archeological dig. I turned up how-to articles from 2003, alternative MinGW distros, references to plugins, dead-links, more references to plugins, passionate discussions on gdb bugs, and more references to plugins.
I no longer have any idea what might constitute an optimal C++ Eclipse environment. Would members of the community like to weigh-in on what they consider to be the current optimal experience for C++ development using Eclipse?
CDT 7.0 (out now in June) will have a preview of Codan, a static analysis framework for C/C++. It will highlight logic errors for you in "realtime", i.e. without having to wait for compilation. (It doesn't have very many checkers at the moment, but the number is growing, and you can also implement checkers of your own.)
CDT 7.0 also features a new debugger contributed by Nokia (called "EDC"), which allows debugging without relying on 3rd party tools such as gdb. This will also allow debugging of Visual Studio binaries, something which previously has been impossible.
The "Open Type" and "Open Resource" commands of CDT (and JDT also, BTW) is something I always miss when I have to do stuff in Visual Studio. Being able to locate any type by incrementally typing a part of its name is very practical, and Visual Studio has nothing close to it.
Integration with unit-testing is still missing, though. Not sure why that hasn't caught on.
Here is what I ended up with for a C++ development environment on Windows 7.
Compiler & libraries
Nuwen MinGW Distro.
It includes the Boost libraries which are necessary for the unit testing framework.
A big thanks to Stephan T. Lavavej for making this distribution available.
Debugger
The GNU debugger as built for Windows.
I copied the file gdb.exe into my C:\MinGW\bin folder and it worked well.
Thanks for Equation Solution for providing win32 and win64 binaries of the GDB executable.
IDE
Eclipse IDE for C/C++ Developers.
Unit testing framework
CUTE (C++ Automated Unit Testing Easier).
Download the Eclipse plug-in using Eclipse’s software installation . Add this URL to “Available Software Sites”: http://ifs.hsr.ch/cute/updatesite.
The CUTE Website has excellent installation and usage instructions.
I failed to find a round-trip modeling tool that was useful to me. Exploring free UML tools was like wandering through a city that had been bombed. Dozens of projects stood in various states of usability. Some projects were clearly active, some were clearly abandoned, but most were somewhere in between. Visio continues to be my pragmatic choice for creating UML models.
Seeing as none of the C++ gods here on SO have weighed in...
My last experience with CDT was about 1 year ago. I too love eclipse for Java, and while CDT "did the job", I didn't feel like it did it any better than Code::Blocks which I used for cross platform development.
Eclipse does have access to UMLet which is my favorite UML tool as it uses a very simple scripting language instead of the 'mouse-click-drag-double-click-type' hell that most UML applications turn out to be. However, UMLet can also be used as a standalone application which makes tucking it into eclipse accomplish little more than wasting screen real-estate.
In the end, I really don't think you are going to find many professionals developing in CDT.
On the linux side you are going to find developers using what they wish to use (Anjuta, Code::Blocks, Dev-C++, kdeveloper, EMACS, vim, etc.)
On the Windows side you'll find Visual Studio overwhelmingly followed by the IDE's above that happen to be cross platform.
In the end, if I HAD to develop in Eclipse; I would use CDT, UMLet, and Subclipse. After having done that I would probably long for my TortoiseSVN, Visual Studio, Code::Blocks, and UMLet standalone.
As far as any automated unit testing goes? Don't know, write my tests by hand. Hope that helps.

Using C++ with Eclipse

I'm figuring out that there's two ways of writing C++ in Eclipse: either download the Eclipse IDE for C/C++ Developers or download the regular Eclipse for java and add the CDT plugin. What is the difference between these two? (Note that I'm already exstensively using Eclipse for Java) Thank you
The C++ tools end up the same so depends if you use Eclipse for other things.
If for other things then I would start with the more complex setup e.g. if you do Java J2EE I would download the Eclipse J2EE then add the C++ tools
If just C++ start with the Eclipse C++
I also found using the Yoxos/Eclipse Source packaging easier to download extra packages. (unless you need the absolute latest patch)
edit:
Sorry I did not read the question fully I have given the general answer. However as you have eclipse working and setup already and if you are happy then just download the C++ plugins. Note I have a separate workspace for java and C++ helps as you will want different perpecives etc and also cuts down on the projects in the explore rs/
Or use EasyEclipse for C/C++ and get a few other useful tools pre-integrated too.

Good C++ Debugging/IDE Environment for Linux?

I have a friend who is trying to make the switch to Linux, but is hung up on the apparent lack of debugging/IDE environments for C++, especially as they relate to template programming. He has been using visual studio for years and is maybe a little spoiled by their awesome IDE. Does anyone have any good suggestions for an environment where he can, under Linux, develop and debug with all of the usual things (Breakpoints, line highlighting for compilation errors, step in/over/out/etc, etc) that he's accustomed to? Thanks!
How about Eclipse + CDT ?
Although many people think of it as a Java IDE, he could try NetBeans. I've used it on Windows for C and C++ development without a problem, and I know NetBeans is supported on Linux, so it would be worth a shot.
It looks like most of the features he wants are included in the C/C++ development toolkit, including integration with GDB, a profiler, and more.
Visual Studio is good, indeed.
On the free side:
Qt Creator is getting quite good too, it's worth a try. There are advantageous by-products coming from the Qt framework:
huge library - not only to build GUI applications but for other domains as well
portability on multiple platforms
A version 1.3 beta is available as a preview of the upcoming release but the current 1.2.1 is already all you need to manage projects.
Eclipse has already been mentioned, it's a very good environment offering many plug-ins (Mylyn, SVN, ...).
MonoDevelop somewhat supports C++ (more and more, I didn't check the latest version).
I've used Eclipse for C/C++ and it's pretty useful. It's also used at ACM ICPC World Finals http://cm.baylor.edu/welcome.icpc
I'd recommand Code::Blocks (but use a nighty build). It can be coupled with gdb to enable step by step debugging and all that stuff.
Not exactly an IDE but SublimeText 2/3 is available on Linux now. There may be a debugger plugin for it too, who knows.
Edit
Here's a gdb plugin for SublimeText
I havn't explored it personally, but Emacs has a C++ development addon that looks very much like a full IDE.
About 7 years ago I used KDevelop that was shipped with KDE. I found it quite good back than, and I hope it also improved with the time. I found it quite comparable to VC++ 6 at this time.
It also contains Qt support, if you are in need for some GUI toolkit.
Depends, Code::Blocks is good, Eclipse is very nice too, but you will need a very good computer. In my opinion the best choice iss gcc, gdb and ViM or Gedit.
My buddies from work use Eclipse + Scons, they also use Valgrind(spelling?) for tracking memory leaks and such.
Many of the IDE features you listed were debugger features. The ddd (Data Display Debugger) debugger is quite a nice GUI wrapper for gdb, allowing graphical representation of data structures, a non-crappy source listing window (ie. unlike the l command of gdb where you don't get context), and also allows you to use any and all native gdb commands directly if desired.
Have a look at CodeLite. It's available for Ubuntu and Fedora out of the box and even for Windows and Mac. So you can have the same IDE on different platforms.
We tried Eclipse and NetBeans but left them due to their huge CPU and memory usage. We have a development server and all the developers connect to it via RDC. Thats why these IDEs miserably failed in our model.
So, we looked for some native IDE. Found CodeBlocks to be very good and super fast. We sort of settled on it but later found CodeLite and liked it better than CodeBlocks.
I just seeing this question after 12+ years. AnyHow I just writing my answer. I personally use Quincy IDE for C and C++ development. it is very lite weight and debugging watch list is very much good and easy to use. I'm just attaching the link to the site. try it.
But you have to install it with wine.
Quincy <-- Click here

open source dev environment for C++: what's better? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I want to do some coding in my spare time, but the thing is, I don't want to spend the money on this.
Would the following set of development tools be The Right Thing, or is there something I'm forgetting?
Eclipse for C++
SVN for source control
Qt for UI development (since it's C++, and I believe it's now opened by Nokia)
hudson for continuous integration
I'd like to write a little image processing application that can run on any platform, but the main platform at the moment will be Windows with a possible movement to the Mac-- hence all the cross-platform tools.
Is there anything really obvious I'm forgetting? Like something like fxcop for style checking in C++?
If I use any libraries, I'd like to avoid GPL libraries; if things go south with my current employer, I'll want to monetize this.
Microsoft Visual C++ Express is free and easily the best IDE for Windows. Furthermore, you can use it to work on cross-platform code - it more depends on writing standards-adhering code and using portable libraries.
If you want to write cross-platform code, I recommend a cross-platform build tool. I use CMake, which generates Visual Studio solutions on Windows, but there are others too, such as SCons.
As for libraries, it depends on what exactly you need to do. Qt is an excellent GUI library. libpng/libjpeg and others are good for loading/saving images at a low level, but there are probably other higher-level image libraries as well.
[edit] A response to the comment about MSVC and Qt:
A quick search brings up Trolltech's Qt Visual Studio Integration page:
Qt Visual Studio .NET Integration
A comment points out that this is actually not free (a free addon is available at this link, but this runs Qt designer outside of Visual Studio. Also, the Express version of Visual Studio does not support plugins.
For coding specifically in Qt there is another new IDE created by Qt: Qt Creator. I've heard good things about it, and it is also portable across Windows, Linux, and Mac.
I detect procrastination (something I'm often guilty of) - just write some code - you can always add tools as you go along.
The problem with questions with phrases like "what's better" is that it's really hard to determine what's right in a specific situation and maybe impossible what's "better".
Said that, I use Eclipse CDT sucessfully as an IDE on Linux. I use frameworks like ACE/TAO to create code that is highly portable.
I know that QT is a very good UI framework. KDE is built on top of KDE and if you use KDE/Linux then you may also want to look at KDevelop, a C++ IDE that has many users.
In the end I believe that you and only you can figure out whats best for you to use. Make sure you check the alternatives and then make an educated decision.
for c++ there are a few more freewares available such as codeblocks and devcpp. I find eclipse very heavy on the machine.
There are many tools that make the difference:
A C++ compiler ... (it wasn't in your list)
doxygen
STLfilt (which is a must have when programming in C++)
A UT framework (CxxTests, boost.test, Fructose, google.test, ...)
something to manage the compilation chain (scons, aap, (b)jam, cmake, ...) -- I've no idea what eclipse is using.
Source control: git. It's not as diffucult as people make it seem. I'm an svn newbie and I still managed to learn the basics of git for use in everyday life! There are about 4 or 5 basic commands that will get you going in no time. Read the official git tutorial
Regarding IDE's, there are a few choices
Microsoft Visual C++ Express Edition (free lite version)
Eclipse with CDT
QtCreator. (Since you're using Qt for the GUI)
Personally I have used Eclipse+CDT for a number of projects. Paired with wxWidgets it has provided me with enough to keep myself pretty much crossplatform (which I think is a big plus).
Also QT has some interesting releases with an IDE now, make sure you check it out: http://www.qtsoftware.com/products/developer-tools
Like earlier suggestion, just start coding, you will eventually find out what is the appropriate mix for you. It varies greatly between individuals what is the "best" IDE or mix of command line tools, etc.
Eclipse CDT is making huge strides, and even organizations that were unx tools only are now finally joining the IDE bandwagon. Considering downloading a current milestone, not the official release.
If you're using windows, don't use Eclipse directly, find a third-party distribution that already has all the GNU tools in it (I forgot the name, I can look it up).
Once you switch to mac it's easier, but make sure to install xcode to get your GNU tools.
If you are using svn - VisualSVNServer is an excellent free GUI based way to setup and administer your SVN repository, definitely worth checking out as it means you have little/no messing about with config files etc. to change your repository.
Regarding version control - Subversion is pretty much standard and is very well supported. From what I've heard, Git is more powerful but harder to use; it's worth a look for a new one-man project, since you wouldn't have the support and retraining concerns that other projects would have.
Regarding IDE, since Visual C++ Express is currently the highest-voted answer - I've used both Eclipse and Visual C++ Express. I don't have a whole lot of experience with Visual C++ Express, so it might have features that I've overlooked, but from what I've been able to compare, Eclipse offers a lot more features. I tried to list its more impressive features in this answer; from what I've been able to see, Visual C++ Express doesn't have any of the features listed there. Eclipse is slower and more resource-intensive, but with a fast enough desktop, its extra features are more than worth it.
In terms of version control, use git and throw your project on GitHub or Gitorious. There's really no reason to use Subversion anymore, due to its painful branching and merging, and lack of a distributed model.
See this link here for why Git is better than X:
http://whygitisbetterthanx.com/
There's also no point in using Sourceforge or GNU Savannah, as the Git front-end sites have much more valuable features and are easier to use.