Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » SWTBot » Absolute and relative positions in SWTBotGefEditor
Absolute and relative positions in SWTBotGefEditor [message #1090510] Tue, 20 August 2013 08:32 Go to next message
Helene Molliere is currently offline Helene Molliere
Messages: 2
Registered: August 2013
Junior Member
Hi,

I'm, a new user of SWTBot and I want to test a GEF editor. I can easily draw my components using the SWTBotGefEditor but I'm facing issues with relative positions in editor.click(x,y) and drag(fromX,fromY,toX,toY) methods.

As far as I understand, these positions are relative to the viewer, so they depends on the screen resolution. Am I right? Is there a way to easily translate an absolute position into a relative one?

Thanks
Re: Absolute and relative positions in SWTBotGefEditor [message #1091545 is a reply to message #1090510] Wed, 21 August 2013 16:35 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael Istria
Messages: 755
Registered: July 2009
Location: Grenoble, France
Senior Member
On 08/21/2013 05:44 PM, Helene Molliere wrote:
> As far as I understand, these positions are relative to the viewer, so
> they depends on the screen resolution. Am I right? Is there a way to
> easily translate an absolute position into a relative one?

As far as I remember of using SWTBot with GMF editors, it seems that it
does not depend directly on the screen resolution, but rather on the
part of the viewer that is shown, which depends on how much the editor
was scrolled.

--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria
Re: Absolute and relative positions in SWTBotGefEditor [message #1095623 is a reply to message #1091545] Tue, 27 August 2013 09:56 Go to previous message
Helene Molliere is currently offline Helene Molliere
Messages: 2
Registered: August 2013
Junior Member
Thank you! It helps.
Previous Topic:SWTWorkbenchBot equivalent for E4
Next Topic:Can SWTBot be used for a SWT application with limited or no access to the source code?
Goto Forum:
  


Current Time: Thu Sep 18 23:48:42 GMT 2014

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

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