Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Scrolling Viewer Problem
Scrolling Viewer Problem [message #186080] Fri, 01 July 2005 14:10 Go to next message
Eclipse UserFriend
Originally posted by: prb113.cs.york.ac.uk

Hi,

I have an editor with a ScaleableFreeformRootEditPart as the root edit
part. This top layer then contains a single rectangular container figure,
which contains other rectangular figures. I have implemented an XY style
layout which snaps to a grid size for the container figure. This all works
fine while I haven't scrolled anywhere but once I scroll across the
screen, say x units then the figures are offest from the gird lines by: x
mod gridSize

Having looked at other posts I think this is something to do with relative
and absolute co-ordinates but I cannot get it to work.

Any ideas?

Paul
Re: Scrolling Viewer Problem [message #186222 is a reply to message #186080] Mon, 04 July 2005 02:02 Go to previous message
Dazhen Gao is currently offline Dazhen GaoFriend
Messages: 21
Registered: July 2009
Junior Member
My suggestion:Check you the method that calculate snap size.
If you getBounds from the figure, you should translate the bounds to the
absolutely bounds.(figure.translateToAbsolute)

"Paul Barton" <prb113@cs.york.ac.uk> wrote in message
news:d2fb365e3319b9f3633f04faa22befac$1@www.eclipse.org...
> Hi,
>
> I have an editor with a ScaleableFreeformRootEditPart as the root edit
> part. This top layer then contains a single rectangular container figure,
> which contains other rectangular figures. I have implemented an XY style
> layout which snaps to a grid size for the container figure. This all works
> fine while I haven't scrolled anywhere but once I scroll across the
> screen, say x units then the figures are offest from the gird lines by: x
> mod gridSize
>
> Having looked at other posts I think this is something to do with relative
> and absolute co-ordinates but I cannot get it to work.
>
> Any ideas?
>
> Paul
>
Previous Topic:Where ist the ShortestpathConnectionRouter gone ?
Next Topic:[OT] viewing examples for expanding collocated nodes
Goto Forum:
  


Current Time: Tue Dec 03 06:01:04 GMT 2024

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

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

Back to the top