gef

Vertical center a TextFlow in GEF

I'm trying to vertical center a multiline textbox within a RectangleFigure in GEF. It needs to be ajusted on resize. This would be best done with a layout, but I can't figure out how that works. I'm adding a BorderMargin to the parent FlowPage and changing the margin when the RectangleFigure gets resized. Unfortunately, at that particu...

GEF - How to open Editor in Composite?

Hi all My name is Oleg, I'm writing advanced feature - visual comparison of BPEL files. I would like to use regular editors in "compare" panes (left and right) As a first step I just want to open two editors (one for each file) Later I can 'hack' them a little, make new parts green, deleted parts red etc... So my problem sounds pretty ...

One EditPart for all model views (in GMF/GEF)

Hello! We're working on creating a modeling tool based on the GMF framework and tools. We have a requirement to allow users to add views (figures) at runtime and use them in their diagrams. We will be using SVG files to represent figures. What's the correct structure of EditParts and other GEF related classes in such a case? We were th...

Eclipse Contextual Help.

Now can I register contextual help in an Eclipse WizardDialog/Editor. 1) I created a help_contexts.xml file. <?xml version="1.0" encoding="UTF-8"?> <?NLS TYPE="org.eclipse.help.contexts"?> <contexts> <context id="my.plugin.help.general" > <description>test</description> <topic label="test" href="http://domain.com/help.h...

How to get started with MDA?

Hey all, I've been wanting to have a dabble with Model Driven Architecture for a while now. Could anyone give me any hints on how to start. I'd love to be able to define a domain model in UML then be able to transform it to say java classes with JPA/hibernate annotations defining the data mappings. I'd really love to get my hands dir...

Draw2D figure with get position at offset

Hello. I am looking for a way to get the position coordinates for an offset of a Draw2D TextFlow. For example SWT's StyledText supports that directly (getLocationAtOffset), but none of the Draw2D text figures supports this. Any ideas how I could calculate the position with the given methods of TextFlow? Regards, Kai ...

Using a FilteredTree in a GEF ContentOutlinePage

We have a ContentOutlinePage that includes a GEF TreeViewer. Simply put, by calling setContents on the TreeViewer, GEF builds TreeEditParts using an EditPartFactory, as is typical for GEF. Internally, the GEF TreeViewer creates a Tree control. public Control createControl(Composite parent) { Tree tree = new Tree(parent, SWT.MULTI...

Updating GEF Model from a background thread

Hello, i'm trying to update a Model for GEF and have the changes shown in the view i've created. Currently no change I make is being reflected in the view, i'm using the following approach to update the model and am wondering if its the right approach to take: Display.getDefault().asyncExec(new Runnable() { public void run() { St...

Relationship between GEF and GMF?

Hello! I'm working on summary on the eclipse modeling project and it's various sub - projects. It is not going to get published, it's sole purpose is to help my colleagues and above all my boss to get an overall impression of the topic. For better understandability i took diagram from the eclipse GEF User Guide and modified it. I want t...

Eclipse GEF on Mac Snow Leopard

I've been in upgrade mode this month and upgraded my Mac to Snow Leopard. I've developed a good sized Eclipse RCP which uses GEF. I upgraded Eclipse on my Mac to 3.5.1-x86_64, latest XCode, etc. Eclipse 3.5.1 works well; however, when install GEF-3.5.1, the SWT plugin doesn't seem to load properly. I do see the GEF n Draw2D plugins i...

What is the difference between bendpoints in JBPM 3 plugin for Eclipse and JPBM 4 plugin for Eclipse?

In JBPM 3 plugin for Eclipse, bendpoints are represented using four integers: <transition name=""> <label x="5" y="-10"/> <bendpoint w1="36" h1="-37" w2="43" h2="39"/> </transition> In the source code, there is a class called Bendpoint, which stores two Dimension objects whose values are represented by w1, h1, w2 and h2. This seem...

Resizing a rectangle , from differnt origins.

Hi, I do have rectangle , which had information about topx ,topy , width and height. I want to scale this rectangle based on an origin other than top-left. Is there already existing algo to do that ? currently I work on Eclipse GEF & SWT . In GEF , the all Rectangle operations are assumed that top-left is where the drawing starts and ...

GEF java draw2d Layout that adjusts to the width of the container so that it spans over more lines

I need to show a line/multiline of images in GEF GraphicalViewer, so that it adjusts to the width of the container by spanning over more lines ...

Parent and Child Figures in Eclipse GEF

How do you make one figure a child of another in a GEF applcation? ...

Gallery of GEF/Draw2D figures

I am new to GEF/Draw2D, I've seen some tutorials on the topic, but I am wondering if any of you have seen a gallery of all figures which are shipped together with GEF? So that one can quickly see what do they look like and what's their purpose? ...

Looking for Java libraries to create a report editor

I have to develop a specialised report editor in Java. The user will get a number of fields that can be layed out on a page plus some graphical elements. The resulting report design needs to be serialized into already defined database tables. The actual generation of the report onto paper is already done. I need to provide only a graphi...

Placing figure in top-right corner of another

I want child figure (org.eclipse.draw2d.Figure) to be relative to the top-right corner of the parent (I want place some small icon, which will be ImageFigure, to be 12 pixels from top and right borders). Is there an existing layout manager that can layout child this way? The org.eclipse.draw2d.XYLayout is not capable of measuring positi...

How I can create a addition Tree Editor with GEF?

Hey, I have a graphical editor with GEF. It's possible to add objects from a palette. An Example what I mean is this: http://java-eclipse.info/IBM.Redbooks-Eclipse.Development.using.the.Graphical.Editing.Framework.and.the.Eclipse.Modeling.Framework/7823/images/fig166_01_0.jpg So, now I want add a different possibility to display the con...

Determing size of visible area of a ScrollingGraphicalViewer in Eclipse GEF

I am attempting to create a simple application using Eclipse GEF that displays a diagram inside a ScrollingGraphicalViewer. On start-up I want the diagram to be centered inside the viewer (imagine a star layout where the center of the star is in the center of the view). Here are what I think are the relevant code sections: My view: pu...

How to add delete command for GEF in coolbar

I need to define the toolbar delete command over plugin.xml for the perspective. I'm using the following code and for undo, redo, zoom in, zoom out works. Only for the delete command won't work. Where do i wrong? <command commandId="org.eclipse.ui.edit.redo" icon="icons/arrow_redo.png" ...