Power Java programming—free!
Build an open source IDE with jEdit
By Robert Swarr, JavaWorld.com, 07/11/03
- Digg
- Reddit
- SlashDot
- Stumble
- del.icio.us
- Technorati
- dzone
Sometimes the best things in life are free, like fresh air and sunshine, but not software. Until recently, a professional-grade
IDE could have cost hundreds or even thousands of dollars. However, after Linux entered the marketplace, open source software
proliferated and became competitive with commercial software. Today, open source development tools are as free as fresh air
and sunshine, and just as plentiful.
For example, the jEdit programmer's editor is an open source utility with advanced editing features. Using jEdit plug-ins,
you can integrate open source development tools such as CVS (Concurrent Versions System), Ant, and JUnit within jEdit's graphical
user interface (GUI). This article shows you how to transform jEdit into an IDE comparable to proprietary software. In this
article, I use the term open source software instead of free software. To set the record straight, "Sidebar 1: Open Source Software = Free Software" explains the similarities and differences between open source and free software.
IDE features
The first step in building an IDE is answering a simple question: what features should the IDE support? Many developers request
features in the following list. These requirements may be the same for you:
- Small, fast, intuitive, but powerful programming editor: it starts up and responds quickly; you can use it without spending hours reading documentation; and it has powerful features
such as advanced search and replace
- Source code beautification: configurable, programmatic formatting of Java source files to a consistent standard
- Class browser: tree-structured view of the methods, data members, and inner classes in a Java source file and point-and-click navigation
through the file
- Project view: tree-structured view of a project's files and point-and-click navigation through the project
- Version control: integration with CVS with a graphical interface
- In-process compilation: compilation of a Java class in the current edit buffer
- Unit-testing framework: integration with JUnit to run automated regression tests within the IDE
- Build management: integration with Ant to run build scripts for a project within the IDE
- Integrated debugger: when code behaves badly and you don't know why, having a debugger in your toolkit is a blessing
- Integrated Javadoc generation and viewing with a graphical interface
You might want to add additional features to the above list based on your requirements.
Build the jEdit IDE
Once you've defined your requirements for an IDE, download and install the software. If you don't have a Java SDK, download
one. The development tools need jar and executable files included in the SDK, but omitted from the JRE (Java Runtime Environment).
Installing jEdit is as simple as downloading and running an executable jar file. From the jEdit project homepage, select the Quick Start page and follow that page's directions. Read the installation instructions for your operating system
on the download page. To run jEdit, use the Java application loader (javaw) in the SDK, not the JRE, since the development
plug-ins will not work properly with the JRE.
- Digg
- Reddit
- SlashDot
- Stumble
- del.icio.us
- Technorati
- dzone
Resources
- JDocPlugin homepage
http://jdocplugin.sourceforge.net
- Sun Microsystems' J2SE (Java 2 Platform, Standard Edition) download page
http://java.sun.com/j2se/downloads.html
- The jEdit project homepage
http://www.jedit.org
- jEdit Plugin Central page
http://plugins.jedit.org
- Concurrent Versions System (CVS) homepage
http://www.cvshome.org
- Ant homepage
http://jakarta.apache.org/ant
- To learn how to use Ant, see "Automate Your Build Process Using Java and Ant," Michael Cymerman (JavaWorld, October 2000)
http://www.javaworld.com/javaworld/jw-10-2000/jw-1020-ant.html
- JUnit homepage
http://www.junit.org/index.htm
- JSwat homepage
http://www.bluemarsh.com/java/jswat/index.html
- Learning Java, Second Edition, Patrick Niemeyer, Jonathan Knudsen (O'Reilly & Associates, July 2002; ISBN0596002858)
http://www.amazon.com/exec/obidos/tg/detail/-/0596002858/javaworld
- Eclipse homepage
http://www.eclipse.org
- NetBeans homepage
http://www.netbeans.org
- The Free Software Foundation's Free Software Definition
http://www.gnu.org/philosophy/free-sw.html
- The Open Source Initiative's Open Source Software Definition
http://www.opensource.org/docs/definition_plain.html
- Robert McMillan's "Will Big Blue Eclipse the Java Tools Market?" (JavaWorld, February 2002) compares and contrasts NetBeans and Eclipse
http://www.javaworld.com/javaworld/jw-02-2002/jw-0222-eclipse.html
- For a recent review of Eclipse, read "Updated Eclipse Toolkit Shines," Rick Grehan, InfoWorld Test Center (JavaWorld, June 2003)
http://www.javaworld.com/javaworld/jw-06-2003/jw-0627-iw-eclipse.html
- Michael J. Daconta's "When Runtime.exec() Won't" (JavaWorld, December 2000) provides how-tos and gotchas on using the Java Runtime.exec() method
http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html
- jEdit 4.0 user's guide
http://www.jedit.org/index.php?page=download
- Eric Raymond's "The Cathedral and the Bazaar" (First Monday, 1998), the essay that turned on a few lightbulbs at Netscape
http://www.firstmonday.dk/issues/issue3_3/raymond
- For more IDEs, browse the Development Tools section of JavaWorld's Topical Index
http://www.javaworld.com/channel_content/jw-tools-index.shtml
- For more open source projects, see Erik Swenson's Open Source Profile column
http://www.javaworld.com/columns/jw-opensource-index.shtml
- Speak out in the JavaWorld Forum
http://www.javaworld.com/javaforums/ubbthreads.php?Cat=&C=2
- Sign up for JavaWorld's free weekly email newsletters
http://www.javaworld.com/subscribe
Archived Discussions (Read only)