The Eclipse Graphical Editing Framework (GEF) and over one million other books are available for Amazon Kindle. Learn more

Vous voulez voir cette page en français ? Cliquez ici.

Sign in to turn on 1-Click ordering.
Amazon Prime Free Trial required. Sign up when you check out. Learn More
More Buying Choices
Have one to sell? Sell yours here
Start reading The Eclipse Graphical Editing Framework on your Kindle in under a minute.

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

The Eclipse Graphical Editing Framework (GEF) [Paperback]

Dan Rubel , Jaime Wren , Eric Clayberg

List Price: CDN$ 46.99
Price: CDN$ 37.59 & FREE Shipping. Details
You Save: CDN$ 9.40 (20%)
o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o
Only 1 left in stock (more on the way).
Ships from and sold by Gift-wrap available.
Want it delivered Tuesday, September 23? Choose One-Day Shipping at checkout.


Amazon Price New from Used from
Kindle Edition CDN $21.57  
Paperback CDN $37.59  
Save Up to 90% on Textbooks
Hit the books in's Textbook Store and save up to 90% on used textbooks and 35% on new textbooks. Learn more.
Join Amazon Student in Canada

Book Description

Aug. 7 2011 0321718380 978-0321718389 1
As Eclipse-based applications become increasingly popular, users are demanding more sophisticated graphical interfaces. When standard widgets aren’t enough, graphics built with GEF are often the best solution. The Eclipse Graphical Editing Framework (GEF) covers everything Java tool developers need to create tomorrow’s richest, most visual interfaces.


This practical, hands-on guide begins by introducing GEF, Draw2D, and Zest, and demonstrating what can be achieved with them. Next, the authors walk through building a simple Draw2D example, helping new GEF developers understand the core capabilities available to them. Building on this foundation, they progressively introduce more of the Draw2D frameworks, including Figures, Layout Managers, Connections, Layers, and Viewports. They present a chapter-length graph visualization project based on Zest, followed by detailed coverage of non-Draw2D portions of GEF.


The book’s final section walks step by step through developing a complete GEF editor. Each chapter focuses on a different aspect of the problem, and includes challenges, solutions, diagrams, screenshots, cookbook-style code examples, and more.


This book is organized to help developers solve immediate problems quickly, while also gaining in-depth knowledge for building advanced solutions. Relevant APIs are included in several chapters, making this an even more useful standalone reference.


This book

  • Introduces GEF application components such as shapes, flow, logic, and text
  • Explains Draw2D architecture, drawing features, and event processing
  • Shows how to create and customize figures, use painting and borders, and work with each Draw2D Layout Manager
  • Thoroughly explains GEF models, including domain and presentation information, populating diagrams, and more
  • Shows how to use Zest’s content providers, filters, and layout algorithms
  • Covers EditParts, EditPolicies, Tools, Commands, Actions, and much more


The Eclipse Graphical Editing Framework (GEF)

is the best resource for all Java tool developers who want to construct sophisticated graphical editing products that integrate with Eclipse, for experienced Eclipse users who want to start creating their own graphical tools, and for anyone who wants to see what makes GEF tick.

Customers Who Bought This Item Also Bought

Product Details

Product Description

About the Author

Dan Rubel, Senior Software Engineer at Google, is an entrepreneur and an expert in the design and application of object technologies. He has architected and managed several successful commercial products, and was cofounder and CTO of Instantiations, which was acquired by Google.


Jaime Wren, a software engineer at Google, has extensive experience developing commercial Eclipse-based tools. At Instantiations, he made significant contributions to the CodePro and WindowBuilder product lines. He continues to work on WindowBuilder as a member of the Google Web Toolkit (GWT) team.


Eric Clayberg, Software Engineering Manager for Google, is a seasoned software technologist, product developer, entrepreneur, and manager, with extensive Java and Eclipse experience. The primary author and architect of more than a dozen commercial Java and Smalltalk add-on products, he cofounded both ObjectShare and Instantiations.

Inside This Book (Learn More)
Browse Sample Pages
Front Cover | Copyright | Table of Contents | Excerpt | Index
Search inside this book:

Customer Reviews

There are no customer reviews yet on
5 star
4 star
3 star
2 star
1 star
Most Helpful Customer Reviews on (beta) 2.7 out of 5 stars  3 reviews
23 of 25 people found the following review helpful
2.0 out of 5 stars Insufficient; utterly fails to explain GEF Sept. 16 2011
By Stefan Mücke - Published on
This book is a good introduction to Draw2D and Zest, but unfortunately NOT to GEF. Like most articles and tutorials about GEF, this book fails to explain the complexities of GEF and make them easy to understand and use. It does not even make a reasonable attempt at discussing the concepts behind GEF. For those interested, I will elaborate below (after the lists) what concepts the book should have described but did not.

The book is written as a tutorial that develops a genealogy editor. In the first part about Draw2D, the authors do a great job in starting with a minimal solution and refactoring it as they add more features. This part is well written and easy to follow. Also, whenever a new Draw2D feature is introduced, the authors describe the various capabilities of Draw2D (e.g. the existing layouts, figures, anchor types, etc.). However, Draw2D is the easy-to-understand part of GEF, and most developers won't need a book to get started.

After Draw2D, the authors describe Zest, which is an extension to GEF that offers JFace-like viewers. I have skipped this part, because I am interested in editors, not viewers.

When it comes to GEF, the authors almost give up at explaining. They mostly describe their code as if observed through a debugger, without drawing the conceptual lines between the invocations. You will find sentences like this (p. 236): "When the user selects an element, the layout EditPolicy [...] for that element's container is found and the createChildEditPolicy(...) method is called." The book does not mention or explain any of the following:

(1) what EditPolicies have to do with layout
(2) when and why EditPolicies are looked up
(3) what a ChildEditPolicy is and why it is needed
(4) why an EditPolicy creates another EditPolicy when it usually creates Commands

After reading the book, I am left with the impression that the authors barely managed to implement the example editor themselves. Also, I cannot imagine that they were involved in the development of the (quite sophisticated) graphical editor that is part of WindowBuilder(tm) of their company Instantiations (acquired by Google). In fact, the editor was originally developed by Konstantin Scheglov and then bought by Instantiations. Konstantin Scheglov continues to be the chief architect and technical lead after WindowBuilder was donated by Google to the Eclipse foundation.

=== What is good ===

- concise wording; no repetitions
- easy to follow in the Draw2D part (and maybe the Zest part)
- starts with a minimal implementation and refactors it as new features are introduced
- develops a single example editor throughout the book

Regarding Draw2D:
- nicely describes zooming and how to do pixel-perfect rendering at zoom levels > 100%
- nicely describes the difference between composing figures of other figures and implementing your own rendering
- nicely describes layers and scrolling
- describes how selection feedback can be customized

=== What is bad ===

- does not explain how GEF works
- only 267 pages (including index), not 312
- the index is a fake; mostly class and method names
- the References section at the end of each chapter almost always refers to the same resources

=== What is missing ===

Regarding GEF, this book can be better characterized by what is missing than by what is not. It does not cover any of the following topics:

- how event handling works in GEF (different from Draw2D)
- how Tools and Requests work (two of the most central things in GEF)
- the different states an editor can be in
- how to use GEF's default layers and how to add your own
- does not explain an EditPart's life cycle
- does not explain an EditPart's activate/deactivate methods
- how drag-and-drop works and what a DragTracker is
- showing temporary/auxiliary elements (e.g. guide lines)
- showing a grid
- showing rulers
- implementing snap (e.g. snap to grid, guides, or figures)
- how feedback works and how to implement custom feedback
- printing
- should have listed Requests created by the various Tools
- how to use the command stack

There are no advanced topics or goodies, like e.g.
- animating figures
- using text figures (TextFlow etc.)
- customizing the keyboard behavior
- performance and memory considerations; scaling; visualizing huge numbers of elements/figures
- whether lazy EditPart creation is possible
- doing complex custom layouts
- dynamically adapting the rendering (e.g. showing more or less details depending on the zoom level)
- implementing non-scrollable (fixed) figures

Here is my view of what the book should have explained:

A graphical editor interacts with the user and must therefore interpret mouse and keyboard events. Besides rendering, this is the core of a graphical editor. In GEF, most of the event processing is done by Tools; a Tool in GEF is not a button on a button bar. The behavior of the editor depends on which Tool is currently active, and in which state it is (for example, when the mouse button is down, mouse movements will be interpreted differently).

In GEF, Tools do not usually implement the editing behavior themselves. Instead, they only interpret the events and create Request objects that describe the intended user action (e.g. select, move, resize an element). These Request objects are then used to obtain Command objects (containing the code that acts on the model), show feedback (e.g. during a drag operation), or perform some other operations. This is where EditPolicies come into play. Instead of implementing the same behavior again and again for different graphical elements, GEF provides a mechanism that allows certain behavior to be attached to elements (i.e. to EditParts). All this should have been explained in great detail, with some nice diagrams making it easier to follow the complex control flow.

There are many more things that need to be explained. However, Tools are the starting point where learning to implement the editing behavior should begin, IMHO. Once you understand Tools and Requests, GEF becomes much easier to use. Discovering this (when learning GEF the hard way) was my "Eureka!" moment after which everything suddenly seemed easy. This "Eureka!" knowledge is what I would have expected from a book about GEF.
1.0 out of 5 stars Terrible - Not for beginners of Eclipse and GEF April 23 2014
By Adym S. Lincoln - Published on
Format:Paperback|Verified Purchase
Having read a book on Eclipse before and written a couple of non graphical plugins, I thought this book would close the gap on learning the GEF framework. I was sadly disappointed. The book spends a great deal of time on developing a Graphical View, devoting only a few chapters on an actual Editor. The worst part is, those chapters on Editors are so terse and devoid of details, you're left with swimming thru the source code to try and understand concepts. In the end, without a broad understanding of GEF to begin with, you will not learn GEF. The book is NOT for beginners. I think the book was written by GEF developers with a focus on junior GEF developers that work for the Eclipse Foundation.

Hope this helps,

3 of 6 people found the following review helpful
5.0 out of 5 stars Great for beginners Sept. 25 2011
By Dr. Fraggenstein - Published on
As a novice Eclipse developer, this has been my go-to resource for GEF. I found that this gave me a great introduction and I would recommend it to anyone else.

Look for similar items by category