Skip to main content

By clicking Submit, you agree to the developerWorks terms of use.

The first time you sign into developerWorks, a profile is created for you. Select information in your profile (name, country/region, and company) is displayed to the public and will accompany any content you post. You may update your IBM account at any time.

All information submitted is secure.

  • Close [x]

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerworks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

By clicking Submit, you agree to the developerWorks terms of use.

All information submitted is secure.

  • Close [x]

Customizing Eclipse RCP applications

Techniques to use with SWT and JFace

Scott Delap (scott@clientjava.com), Desktop/Enterprise Java Consultant
Scott Delap is president of Rich Client Solutions Inc., a software consulting firm focusing on technologies such as Swing, Eclipse RCP, GWT, Flex, and Open Laszlo. He is actively involved in the Java community, speaking at events such as NFJS, QCon and JavaOne. He is also the Java editor of InfoQ.com and runs ClientJava.com, a portal focused on desktop Java development.
Annas Andy Maleh (andy@obtiva.com), Consultant, MichaelDKelly.com
Annas "Andy" Maleh is a consultant at Obtiva Corp., a firm that specializes in Eclipse RCP development, Ruby on Rails development and training, and helping teams transition to Agile methodologies. He is currently involved with an Eclipse RCP project to build a custom CRM application for an international corporation. He works on a team that follows eXtreme Programming practices, programs professionally in Java and Ruby, and participates in work relating to UI design enhancement. At EclipseWorld 2006, he gave two presentations relating to Eclipse RCP development. He is a Sun Certified Java Programmer who holds a bachelor's degree in computer science from McGill University.

Summary:  Most developers think that an Eclipse Rich Client Platform (RCP) application must look similar in nature to the Eclipse integrated development environment (IDE). This isn't the case, however. This tutorial will explain a number of simple techniques you can use with the Standard Widget Toolkit (SWT) and JFace to create applications that have much more personality than the Eclipse IDE.

Date:  27 Feb 2007
Level:  Intermediate PDF:  A4 and Letter (1058 KB | 40 pages)Get Adobe® Reader®

Activity:  39594 views
Comments:  

Workspace setup

Before going through the many code examples in this tutorial, you need to set up a sandbox workspace. You can do this two ways:

  • Select a new workspace location on Eclipse IDE startup.
  • If your IDE defaults to the same workspace every time at startup, select File > Switch Workspace.

After you establish a workspace, a few support projects are needed. Select File > Import. Select plug-ins and Fragments from the plug-in Development category, then click Next. Click Next on the following screen, then select the following projects for import and add them to the list on the right:

  • org.eclipse.swt
  • org.eclipse.swt.win32.win32.x86 (or platform-specific SWT plug-in)
  • org.eclipse.equinox.common
  • org.eclipse.core.commands

Click Finish to import. Next, download the archive referenced in the Resources section. Right-click in the Package Explorer and select Import. This time, select Existing Projects into Workspace from the General category, then click Next. Select the Archive File option and browse to find the archive project file. Click Finish to import.

Confirm that all the code in the tutorial project compiles without errors. If it doesn't, you may need to modify the project's required libraries. To do so, right-click the project, and select Properties. Next, go to the Java Build path. Under the Projects tab, remove all projects. Finally, click Add to read the projects that were imported as dependencies. Upon a clean compile, all errors should disappear. Now you're ready to begin widget customizations.

4 of 18 | Previous | Next

Comments



static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=Open source
ArticleID=197254
TutorialTitle=Customizing Eclipse RCP applications
publish-date=02272007
author1-email=scott@clientjava.com
author1-email-cc=
author2-email=andy@obtiva.com
author2-email-cc=