/** * Returns <code>true</code> if the given rectangle intersects * with any of the polygons the receiver maintains to describe * its area and <code>false</code> otherwise. * * @param rect the rectangle to test for intersection * @return <code>true</code> if the rectangle intersects with the receiver, and <code>false</code> otherwise * * @exception IllegalArgumentException <ul> * <li>ERROR_NULL_ARGUMENT - if the argument is null</li> * </ul> * @exception SWTException <ul> * <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li> * </ul> * * @see Rectangle#intersects(Rectangle) */ public boolean intersects(Rectangle rect) { if (rect == null) SWT.error(SWT.ERROR_NULL_ARGUMENT); return intersects(rect.x, rect.y, rect.width, rect.height); }
/** * Returns <code>true</code> if the rectangle described by the * arguments intersects with any of the polygons the receiver * maintains to describe its area, and <code>false</code> otherwise. * * @param x the x coordinate of the origin of the rectangle * @param y the y coordinate of the origin of the rectangle * @param width the width of the rectangle * @param height the height of the rectangle * @return <code>true</code> if the rectangle intersects with the receiver, and <code>false</code> otherwise * * @exception SWTException <ul> * <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li> * </ul> * * @see Rectangle#intersects(Rectangle) */ public boolean intersects (int x, int y, int width, int height) { if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); return intersects(new Rectangle(x, y, width, height)); }
/** * Returns <code>true</code> if the rectangle described by the * arguments intersects with any of the polygons the receiver * maintains to describe its area, and <code>false</code> otherwise. * * @param x the x coordinate of the origin of the rectangle * @param y the y coordinate of the origin of the rectangle * @param width the width of the rectangle * @param height the height of the rectangle * @return <code>true</code> if the rectangle intersects with the receiver, and <code>false</code> otherwise * * @exception SWTException <ul> * <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li> * </ul> * * @see Rectangle#intersects(Rectangle) */ public boolean intersects (int x, int y, int width, int height) { if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); return intersects(new Rectangle(x, y, width, height)); }
/** * Returns <code>true</code> if the rectangle described by the * arguments intersects with any of the polygons the receiver * maintains to describe its area, and <code>false</code> otherwise. * * @param x the x coordinate of the origin of the rectangle * @param y the y coordinate of the origin of the rectangle * @param width the width of the rectangle * @param height the height of the rectangle * @return <code>true</code> if the rectangle intersects with the receiver, and <code>false</code> otherwise * * @exception SWTException <ul> * <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li> * </ul> * * @see Rectangle#intersects(Rectangle) */ public boolean intersects (int x, int y, int width, int height) { if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); return intersects(new Rectangle(x, y, width, height)); }