- Overload the method getDragTracker. The purpose of this method is to provide a tracker when you move the editpart. The NoScrollEditPartTracker provides a means to constraint movement in an a compartment without scroll bar

/**
* the drag tracker has been specialized in order to constraint mvt inside its container without
* scroll bar
* {@inheritDoc}
*/
@Override
public DragTracker getDragTracker(Request request) {
return new NoScrollDragEditPartsTrackerEx(this);
}

-Add an editpolicy for the role PRIMARY_DRAG_ROLE that provides A tracker for the constrained resize “NoScrollResizeTracker” A tracker for the constrained move “NoScrollDragEditPartsTrackerEx”

/**
* this code has been overloaded in order to constraint the resize into its container without scroll bars
*{@inheritDoc}
*/
@Override
protected ResizeTracker getResizeTracker(int direction) {
return new NoScrollResizeTracker((GraphicalEditPart) getHost(), direction);
}
/**
* this code has been overloaded in order to constraint the move into its container without scroll bars
*{@inheritDoc}
*/
@Override
protected DragEditPartsTracker getDragTracker() {
return new NoScrollDragEditPartsTrackerEx(getHost());
}

o See an example that contains theses two drag trackers: NoScrollClassifierResizableShapeEditPolicy