Skip to main content



      Home
Home » Eclipse Projects » GEF » Newbie Question: Model not being painted
Newbie Question: Model not being painted [message #129918] Thu, 29 April 2004 18:05
Eclipse UserFriend
Originally posted by: etrexuser.hotmail.com

Hi,

I am a newbie to GEF and I've been trying to display an element on the
screen for quite some time now.

My EditPartFactory creates an instance of a ChildEditPart.
The ChildEditPart defines a XYLayoutEditPolicy for the Layout_Role
The Policy Creates a ChildFigure
==>(Problem 1. The ChildFigure is painted immediately)

The Policy does a getCreateCommand.
The Palette points to the Child class on selection of the Child tool.
When I select the Child Tool and click on the workspace I am able to create
an instance of the model via the execute method of the command.
==>(Problem 2. getContraintsFor(request) returns a NullPointerException)

request.getLocation() works and I am able to store the location of the Child
as part of the child.
The command sends a fireStructureChange() method.
I am able to get the event in the ChildEditPart.
==>(Problem 3. Refresh, RefreshChildren and RefreshVisuals don't seem to do
anything. Nothing appears on the screen).
==>(Problem 4. If I override paintFigure in my Figure class I can see the
control going there, but I don't get the location correctly. It is always 0,
0).

Can you please help. I am desperate.

Thanks.
Previous Topic:handle to the model class
Next Topic:Logic Gates Example
Goto Forum:
  


Current Time: Fri Jul 11 22:39:23 EDT 2025

Powered by FUDForum. Page generated in 0.02991 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top