Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9167051
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T15:17:47+00:00 2026-06-17T15:17:47+00:00

I am building a Eclipse plug-in project with The Eclipse Graphical Editing Framework (

  • 0

I am building a Eclipse plug-in project with The Eclipse Graphical Editing Framework (GEF).
It’s ok that I write a single class for testing with example code I find on the internet, the code is following:

public class Test {
    public static void main(String args[]){
        Shell shell = new Shell(); 
        shell.open();
        Display display = shell.getDisplay();
        LightweightSystem lws = new LightweightSystem(shell);
        IFigure panel = new Figure();
        lws.setContents(panel);
        RectangleFigure node1 = new RectangleFigure();
        RectangleFigure node2 = new RectangleFigure();
        node1.setBackgroundColor(ColorConstants.red);
        node1.setBounds(new Rectangle(30, 30, 64, 36));
        node2.setBackgroundColor(ColorConstants.blue);
        node2.setBounds(new Rectangle(300, 300, 64, 36));
        PolylineConnection conn = new PolylineConnection();
        conn.setSourceAnchor(new ChopboxAnchor(node1));
        conn.setTargetAnchor(new ChopboxAnchor(node2));
        conn.setTargetDecoration(new PolygonDecoration());
        Label label = new Label("Midpoint");
        label.setOpaque(true);
        label.setBackgroundColor(ColorConstants.buttonLightest);
        label.setBorder(new LineBorder());
        conn.add(label, new MidpointLocator(conn, 0));
        panel.add(node1);
        panel.add(node2);
        panel.add(conn);
        while (!shell.isDisposed ()) { 
            if (!display.readAndDispatch ()) 
               display.sleep (); 
        }
    }//main
}

It works.

But – when I try to build figures in a EditorPart (org.eclipse.ui.IEditorPart) instance class, it turns bad and giving me the following error code:

**org.eclipse.e4.core.di.InjectionException: java.lang.NoClassDefFoundError:** org/eclipse/draw2d/LightweightSystem

It’s quite strange because I just write 3 lines at the editor’s createPartControl method:

Shell shell = parent.getShell();
Display display = shell.getDisplay();
LightweightSystem lws = new LightweightSystem(shell);

So any body help?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T15:17:48+00:00Added an answer on June 17, 2026 at 3:17 pm

    Are your dependencies set properly? You need to add org.eclipse.draw2d for the LightweightSystem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building an Android application (as an Eclipse project) that needs to access a
Building simple code (example is below) returns error on eclipse, while g++ from commandline
I am building an Eclipse plug-in that provides a set of core features in
Why would Eclipse, when building an Android project, get stuck in an infinite loop
Tycho is supposed to be a plug-in for maven for building eclipse plug-ins. I
I'm running eclipse with the Blackberry Java Plug-in, working on a 1.4.5 Blackberry project.
In building eclipse code, I have this Build path specifies ... error. Build path
So I am building some Arduino code in eclipse, as described in Your Second
Yesterday, my project was building and running fine. Today, Eclipse decided it doesn't recognize
I am building a C++ project in Eclipse. It uses SQLITE3 for database and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.