The Artima Developer Community
Sponsored Link

Agile Buzz Forum
Eclipse/GEF More questions that answers

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Mark Levison

Posts: 877
Nickname: mlevison
Registered: Jan, 2003

Mark Levison an agile software developer who writes Notes from a tool user.
Eclipse/GEF More questions that answers Posted: Jun 1, 2007 11:51 AM
Reply to this message Reply

This post originated from an RSS feed registered with Agile Buzz by Mark Levison.
Original Post: Eclipse/GEF More questions that answers
Feed Title: Notes from a Tool User
Feed URL: http://feeds.feedburner.com/NotesFromAToolUser
Feed Description: Thoughts about photography, software development, reading, food, wine and the world around us.
Latest Agile Buzz Posts
Latest Agile Buzz Posts by Mark Levison
Latest Posts From Notes from a Tool User

Advertisement

I'm struggling to build an GEF application in Eclipse. Unfortunately the documentation for GEF consists of half a dozen tutorials that were written between 2003-4. These tutorials are excellent as far as they go but don't really shed light in alot of areas. So I will use this blog posting as a way of keeping track of my questions and the answers as I stumble across them.

GEF Tutorials/Documentation

Current list. My favorites so far: A Shape Diagram Editor by Bo Majewski. The source code for this tutorial is included in the GEF Examples download (link is 3.2.2).

What's missing no tutorial/sample covers a standalone RCP/GEF application. In particular there is no information on how to integrate into the RCP commands and menu structure.

API Questions

Retarget Actions

  1. What is a retarget action? It appears to be a wrapper around the existing SWT actions. Retarget actions Javadocs only tell you that it "tracks the active part in the workbench". Not why this would be useful.
  2. Why do we need an action that is different from IAction?
  3. Does retarget action play nicely with 3.3 new handler code?
  4. Which actions need retarget actions and which don't? For example the Copy has one and Print doesn't. Why?

Integration with a plain RCP application

  1. Why use ActionContributor vs. adding Actions in the ActionBarAdvisor?

ActionBarContributor

  1. If you’re using the ActionBarContributor how do you contribute to a menu that already exists – perhaps file? In a specific place in that menu?
  2. When adding actions via an ActionBarContributor should you add the actions  to a ‘global handler’:
        • pageSite.getActionBars().setGlobalActionHandler() as per the logic editor sample **or** editor handler
        • getEditorSite().getService(IHandlerService.class).
    activateHandler() as per the shapes example?

Drawing

  1. When drawing your own figure what method should you override? paint() or paintClientArea() or paintFigure(). Finally one where I have answer (even though none of the methods provide any hints in the docs). From the Logic Designer sample code, I noticed that one that gets paintFigure() gets overridden.
  2. Need to turn on antialaising? Just do graphics.setAntialias(SWT.ON); If its inside paintFigure you don't need to turn it off since paint() does a graphics.restoreState(); immediately after calling paintFigure();

If you enjoyed this post, subscribe now to get free updates.

 

Read: Eclipse/GEF More questions that answers

Topic: DMOZ Two? Previous Topic   Next Topic Topic: It's called Testing...

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use