Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » scrolling - how do i get the right position withi a figure
scrolling - how do i get the right position withi a figure [message #200052] Thu, 20 October 2005 14:53 Go to next message
Eclipse UserFriend
Originally posted by: philipp_sessner.yahoo.de

Hi,

in my editor i need to get the mouseposition within an figure - so i use
((CreateRequest)request).getLocation() in my createAddCommand() method
of my layoutPolicy. Everythig is fine till i have to scroll because my
figure, i`m adding to, is getting to big. i do not need the position for
placing the figure in it's parent. i need it to find the closest point
out of a bunch of points in the figure.

i don`t know how i have to translate my mouse coordinates to get the
right position in the figure, because i don`t know how much i scrolled
and where to get that information.

can someone help me?

thanks
Re: scrolling - how do i get the right position withi a figure [message #200061 is a reply to message #200052] Thu, 20 October 2005 15:10 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

Try calling getConstraintFor(addRequest)

"Philipp Se
Re: scrolling - how do i get the right position withi a figure [message #200117 is a reply to message #200061] Thu, 20 October 2005 17:18 Go to previous message
Eclipse UserFriend
Originally posted by: philipp_sessner.yahoo.de

i don`t know how i could missed that - thanksa lot, now i got all i need.

Philipp

Randy Hudson schrieb:
> Try calling getConstraintFor(addRequest)
>
> "Philipp Seßner" <philipp_sessner@yahoo.de> wrote in message
> news:dj8b0t$9i$1@news.eclipse.org...
>
>>Hi,
>>
>>in my editor i need to get the mouseposition within an figure - so i use
>>((CreateRequest)request).getLocation() in my createAddCommand() method of
>>my layoutPolicy. Everythig is fine till i have to scroll because my
>>figure, i`m adding to, is getting to big. i do not need the position for
>>placing the figure in it's parent. i need it to find the closest point out
>>of a bunch of points in the figure.
>>
>>i don`t know how i have to translate my mouse coordinates to get the right
>>position in the figure, because i don`t know how much i scrolled and where
>>to get that information.
>>
>>can someone help me?
>>
>>thanks
>
>
>
Previous Topic:passing informations between EGF models
Next Topic:Palette and Tree View
Goto Forum:
  


Current Time: Tue Apr 23 06:10:33 GMT 2024

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

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

Back to the top