Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » SnapToGrid, SnapToGeometry or ....
SnapToGrid, SnapToGeometry or .... [message #171208] Thu, 10 March 2005 13:36 Go to next message
Eclipse UserFriend
Originally posted by: J_ML.netcabo.pt

Hi guys, i need some help here. I'am building an editor using GEF and a
SWT view that has nothing to do with my question. Everything is doing fine
except for one thing. Imagine i need to build a table just like an HTML
table (not in the swt view) and that the user is supposed to drag-n-drop
stuff into it. I need some kind of snap-to-*** to make the objects dragged
aply/expand over the "cols and rows". My problem is that i have no
documentation over SnapToGrid, SnapToGeometry or SnapToHelper.... What i
have is the reference that somehow seems quite confusing...

It would be a HUGE help for any comments from anyone... feel free to
propose other solutions...

(sorry about my english)

josé
Re: SnapToGrid, SnapToGeometry or .... [message #171219 is a reply to message #171208] Thu, 10 March 2005 15:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

""Jos
Re: SnapToGrid, SnapToGeometry or .... [message #171242 is a reply to message #171219] Thu, 10 March 2005 16:32 Go to previous message
Eclipse UserFriend
Originally posted by: J_ML.netcabo.pt

Randy Hudson wrote:


> ""José"" <J_ML@netcabo.pt> wrote in message
> news:d0pihk$jto$1@www.eclipse.org...
>>
>> Hi guys, i need some help here. I'am building an editor using GEF and a
>> SWT view that has nothing to do with my question. Everything is doing fine
>> except for one thing. Imagine i need to build a table just like an HTML
>> table (not in the swt view) and that the user is supposed to drag-n-drop
>> stuff into it. I need some kind of snap-to-*** to make the objects dragged
>> aply/expand over the "cols and rows". My problem is that i have no
>> documentation over SnapToGrid, SnapToGeometry or SnapToHelper.... What i
>> have is the reference that somehow seems quite confusing...

> What do yo umean you have a reference? JavaDoc? SnapToHelper is pretty
> small API that can adapt to many situations, including table cell snapping.

hi again, i ment examples, samples or tutorials. Anyways, i found how to
understand SnapToHelper and i have some code working for now. But i have
another problem, imagine this:

Problem: I want to make the grid visible in a certain area (it can still
force snap outside the visual "grid", no prob with that) but i can seem to
ajust the size! i can resize the with and heith of the cells but clipping
doesnt seem to work... i've tryed the "size" atribbute.

How it is untill now: I have all the initialization on my editor class and
i've set the contents viewer.setContents(EditPartXXX). That EditPartXXX is
building a gridlayer on it's createfigure, were i have defined the cell
sizes (that work) and were i'am trying to clip the grid using SIZE but
it's not working.

This questions may seem simple.. i don't know, the problem is that i had
no contact with GEF until now and i'm supposed to learn and use it for
"yesterday".

Thanks for any answers, thanks Randy
Previous Topic:Embed SWT Composite inside Draw2D Figures
Next Topic:hit-test support for overlapping shapes
Goto Forum:
  


Current Time: Thu Apr 25 05:05:02 GMT 2024

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

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

Back to the top