|
|
|
|
Uses of Class org.eclipse.swt.graphics.Rectangle
Methods in
org.eclipse.jface.text with parameters of type
Rectangle
|
protected
Rectangle
|
AbstractInformationControlManager.
computeAvailableArea
(
Rectangle subjectArea,
Rectangle bounds,
AbstractInformationControlManager.Anchor anchor)
Computes the area available for an information control given an anchor and the subject area
within bounds . |
protected
Point
|
AbstractInformationControlManager.
computeInformationControlLocation
(
Rectangle subjectArea,
Point controlSize)
Computes the location of the information control depending on the
subject area and the size of the information control. |
protected
Point
|
AbstractInformationControlManager.
computeLocation
(
Rectangle subjectArea,
Point controlSize,
AbstractInformationControlManager.Anchor anchor)
Computes the display location of the information control. |
protected
Point
|
AbstractInformationControlManager.
computeSizeConstraints
(
Control subjectControl,
Rectangle subjectArea,
IInformationControl informationControl)
Computes the size constraints of the information control in points. |
protected void
|
AbstractInformationControlManager.
setInformation
(
Object information,
Rectangle subjectArea)
Sets the parameters of the information to be displayed. |
protected void
|
AbstractInformationControlManager.
setInformation
(
String information,
Rectangle subjectArea)
Sets the parameters of the information to be displayed. |
protected void
|
AbstractInformationControlManager.
showInformationControl
(
Rectangle subjectArea)
Shows the information control and starts the information control closer. |
void
|
AbstractInformationControlManager.IInformationControlCloser.
start
(
Rectangle subjectArea)
Tells this closer to start monitoring the subject and the information
control. |
protected boolean
|
AbstractInformationControlManager.
updateLocation
(
Point location,
Point size,
Rectangle displayArea,
AbstractInformationControlManager.Anchor anchor)
Checks whether a control of the given size at the given location would be completely visible
in the given display area when laid out by using the given anchor. |
Methods in
org.eclipse.jface.text.source with parameters of type
Rectangle
|
protected
Point
|
AnnotationBarHoverManager.
computeLocation
(
Rectangle subjectArea,
Point controlSize,
AbstractInformationControlManager.Anchor anchor)
|
protected
Point
|
AnnotationBarHoverManager.
computeSizeConstraints
(
Control subjectControl,
Rectangle subjectArea,
IInformationControl informationControl)
|
static void
|
ImageUtilities.
drawImage
(
Image image,
GC gc,
Canvas canvas,
Rectangle r,
int align)
Draws an image aligned inside the given rectangle on the given canvas. |
static void
|
ImageUtilities.
drawImage
(
Image image,
GC gc,
Canvas canvas,
Rectangle r,
int halign,
int valign)
Draws an image aligned inside the given rectangle on the given canvas. |
void
|
IAnnotationAccessExtension.
paint
(
Annotation annotation,
GC gc,
Canvas canvas,
Rectangle bounds)
Draws a graphical representation of the given annotation within the given bounds. |
void
|
IAnnotationPresentation.
paint
(
GC gc,
Canvas canvas,
Rectangle bounds)
Implement this method to draw a graphical representation
of this annotation within the given bounds. |
protected void
|
AnnotationBarHoverManager.
showInformationControl
(
Rectangle subjectArea)
|
void
|
AnnotationBarHoverManager.Closer.
start
(
Rectangle subjectArea)
Deprecated. |
Methods in
org.eclipse.jface.util that return
Rectangle
|
static
Rectangle
|
Geometry.
add
(
Rectangle rect1,
Rectangle rect2)
Returns a new Rectangle whose x, y, width, and height is the sum of the x, y, width, and height values of
both rectangles respectively. |
static
Rectangle
|
Geometry.
copy
(
Rectangle toCopy)
Returns a copy of the given rectangle |
static
Rectangle
|
Geometry.
createDiffRectangle
(int left,
int right,
int top,
int bottom)
Returns a rectangle which, when added to another rectangle, will expand each side
by the given number of units. |
static
Rectangle
|
Geometry.
createRectangle
(
Point position,
Point size)
Returns a new rectangle with the given position and dimensions, expressed
as points. |
static
Rectangle
|
Geometry.
getExtrudedEdge
(
Rectangle toExtrude,
int size,
int orientation)
Extrudes the given edge inward by the given distance. |
static
Rectangle
|
Geometry.
subtract
(
Rectangle rect1,
Rectangle rect2)
Returns a new difference Rectangle whose x, y, width, and height are equal to the difference of the corresponding
attributes from the given rectangles
Example: Compute the margins for a given Composite, and apply those same margins to a new GridLayout
// Compute the client area, in the coordinate system of the input composite's parent
Rectangle clientArea = Display.getCurrent().map(inputComposite,
inputComposite.getParent(), inputComposite.getClientArea());
// Compute the margins for a given Composite by subtracting the client area from the composite's bounds
Rectangle margins = Geometry.subtract(inputComposite.getBounds(), clientArea);
// Now apply these margins to a new GridLayout
GridLayout layout = GridLayoutFactory.fillDefaults().margins(margins).create();
|
static
Rectangle
|
Geometry.
toControl
(
Control coordinateSystem,
Rectangle toConvert)
Converts the given rectangle from display coordinates to the local coordinate system
of the given object into display coordinates. |
static
Rectangle
|
Geometry.
toDisplay
(
Control coordinateSystem,
Rectangle toConvert)
Converts the given rectangle from the local coordinate system of the given object
into display coordinates. |
Methods in
org.eclipse.jface.util with parameters of type
Rectangle
|
static
Rectangle
|
Geometry.
add
(
Rectangle rect1,
Rectangle rect2)
Returns a new Rectangle whose x, y, width, and height is the sum of the x, y, width, and height values of
both rectangles respectively. |
static
Point
|
Geometry.
centerPoint
(
Rectangle rect)
Returns the point in the center of the given rectangle. |
static
Rectangle
|
Geometry.
copy
(
Rectangle toCopy)
Returns a copy of the given rectangle |
static void
|
Geometry.
expand
(
Rectangle rect,
int left,
int right,
int top,
int bottom)
Moves each edge of the given rectangle outward by the given amount. |
static void
|
Geometry.
expand
(
Rectangle rect,
Rectangle differenceRect)
Moves each edge of the given rectangle outward by the given amount. |
static void
|
Geometry.
flipXY
(
Rectangle toFlip)
Swaps the X and Y coordinates of the given rectangle, along with the height and width. |
static int
|
Geometry.
getClosestSide
(
Rectangle boundary,
Point toTest)
Returns the edge of the given rectangle is closest to the given
point. |
static int
|
Geometry.
getCoordinate
(
Rectangle toMeasure,
boolean width)
Returns the x or y coordinates of the given rectangle. |
static int
|
Geometry.
getDimension
(
Rectangle toMeasure,
boolean width)
Returns the height or width of the given rectangle. |
static int
|
Geometry.
getDistanceFrom
(
Rectangle boundary,
Point toTest)
Returns the distance from the point to the nearest edge of the given
rectangle. |
static int
|
Geometry.
getDistanceFromEdge
(
Rectangle rectangle,
Point testPoint,
int edgeOfInterest)
Returns the distance of the given point from a particular side of the given rectangle. |
static
Rectangle
|
Geometry.
getExtrudedEdge
(
Rectangle toExtrude,
int size,
int orientation)
Extrudes the given edge inward by the given distance. |
static
Point
|
Geometry.
getLocation
(
Rectangle toQuery)
Returns the x,y position of the given rectangle. |
static int
|
Geometry.
getRelativePosition
(
Rectangle boundary,
Point toTest)
Determines where the given point lies with respect to the given rectangle. |
static
Point
|
Geometry.
getSize
(
Rectangle rectangle)
Returns the size of the rectangle, as a Point |
static void
|
Geometry.
moveInside
(
Rectangle inner,
Rectangle outer)
Repositions the 'inner' rectangle to lie completely within the bounds of the 'outer'
rectangle if possible. |
static void
|
Geometry.
moveRectangle
(
Rectangle rect,
Point delta)
Moves the given rectangle by the given delta. |
static void
|
Geometry.
normalize
(
Rectangle rect)
Normalizes the given rectangle. |
static void
|
Geometry.
set
(
Rectangle result,
Rectangle toCopy)
Sets result equal to toCopy |
static void
|
Geometry.
setCoordinate
(
Rectangle toSet,
boolean width,
int newCoordinate)
Sets one coordinate of the given rectangle. |
static void
|
Geometry.
setDimension
(
Rectangle toSet,
boolean width,
int newCoordinate)
Sets one dimension of the given rectangle. |
static void
|
Geometry.
setLocation
(
Rectangle rectangle,
Point newLocation)
Sets the x,y position of the given rectangle. |
static void
|
Geometry.
setSize
(
Rectangle rectangle,
Point newSize)
Sets the size of the given rectangle to the given size |
static
Rectangle
|
Geometry.
subtract
(
Rectangle rect1,
Rectangle rect2)
Returns a new difference Rectangle whose x, y, width, and height are equal to the difference of the corresponding
attributes from the given rectangles
Example: Compute the margins for a given Composite, and apply those same margins to a new GridLayout
// Compute the client area, in the coordinate system of the input composite's parent
Rectangle clientArea = Display.getCurrent().map(inputComposite,
inputComposite.getParent(), inputComposite.getClientArea());
// Compute the margins for a given Composite by subtracting the client area from the composite's bounds
Rectangle margins = Geometry.subtract(inputComposite.getBounds(), clientArea);
// Now apply these margins to a new GridLayout
GridLayout layout = GridLayoutFactory.fillDefaults().margins(margins).create();
|
static
Rectangle
|
Geometry.
toControl
(
Control coordinateSystem,
Rectangle toConvert)
Converts the given rectangle from display coordinates to the local coordinate system
of the given object into display coordinates. |
static
Rectangle
|
Geometry.
toDisplay
(
Control coordinateSystem,
Rectangle toConvert)
Converts the given rectangle from the local coordinate system of the given object
into display coordinates. |
Methods in
org.eclipse.swt.custom that return
Rectangle
|
Rectangle
|
CTabFolder.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
ViewForm.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
TableTree.
computeTrim
(int x,
int y,
int width,
int height)
Deprecated. |
Rectangle
|
StyledText.
getBlockSelectionBounds
()
Returns the block selection bounds. |
Rectangle
|
CTabItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
TableTreeItem.
getBounds
(int index)
Deprecated. Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
CTabFolder.
getClientArea
()
|
Rectangle
|
ViewForm.
getClientArea
()
|
Rectangle
|
CBanner.
getClientArea
()
|
Rectangle
|
TableTree.
getClientArea
()
Deprecated. |
Rectangle
|
StyledText.
getTextBounds
(int start,
int end)
Returns the smallest bounding rectangle that includes the characters between two offsets. |
Methods in
org.eclipse.swt.graphics with parameters of type
Rectangle
|
void
|
Rectangle.
add
(
Rectangle rect)
Destructively replaces the x, y, width and height values
in the receiver with ones which represent the union of the
rectangles specified by the receiver and the given rectangle. |
void
|
Region.
add
(
Rectangle rect)
Adds the given rectangle to the collection of polygons
the receiver maintains to describe its area. |
void
|
GC.
drawRectangle
(
Rectangle rect)
Draws the outline of the specified rectangle, using the receiver's
foreground color. |
void
|
GC.
fillRectangle
(
Rectangle rect)
Fills the interior of the specified rectangle, using the receiver's
background color. |
void
|
Rectangle.
intersect
(
Rectangle rect)
Destructively replaces the x, y, width and height values
in the receiver with ones which represent the intersection of the
rectangles specified by the receiver and the given rectangle. |
void
|
Region.
intersect
(
Rectangle rect)
Intersects the given rectangle to the collection of polygons
the receiver maintains to describe its area. |
Rectangle
|
Rectangle.
intersection
(
Rectangle rect)
Returns a new rectangle which represents the intersection
of the receiver and the given rectangle. |
boolean
|
Rectangle.
intersects
(
Rectangle rect)
Returns true if the given rectangle intersects
with the receiver and false otherwise. |
boolean
|
Region.
intersects
(
Rectangle rect)
Returns true if the given rectangle intersects
with any of the polygons the receiver maintains to describe
its area and false otherwise. |
void
|
GC.
setClipping
(
Rectangle rect)
Sets the area of the receiver which can be changed
by drawing operations to the rectangular area specified
by the argument. |
void
|
Region.
subtract
(
Rectangle rect)
Subtracts the given rectangle from the collection of polygons
the receiver maintains to describe its area. |
Rectangle
|
Rectangle.
union
(
Rectangle rect)
Returns a new rectangle which represents the union of
the receiver and the given rectangle. |
Methods in
org.eclipse.swt.printing that return
Rectangle
|
Rectangle
|
Printer.
computeTrim
(int x,
int y,
int width,
int height)
Given a client area (as described by the arguments),
returns a rectangle, relative to the client area's coordinates,
that is the client area expanded by the printer's trim (or minimum margins). |
Rectangle
|
Printer.
getBounds
()
Returns a rectangle describing the receiver's size and location. |
Rectangle
|
Printer.
getClientArea
()
Returns a rectangle which describes the area of the
receiver which is capable of displaying data. |
Methods in
org.eclipse.swt.widgets that return
Rectangle
|
Rectangle
|
Decorations.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
Group.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
TabFolder.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
Scrollable.
computeTrim
(int x,
int y,
int width,
int height)
Given a desired client area for the receiver
(as described by the arguments), returns the bounding
rectangle which would be required to produce that client
area. |
Rectangle
|
ToolBar.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
Text.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
Spinner.
computeTrim
(int x,
int y,
int width,
int height)
|
Rectangle
|
Monitor.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its device. |
Rectangle
|
Event.
getBounds
()
Gets the bounds. |
Rectangle
|
Shell.
getBounds
()
|
Rectangle
|
Caret.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent (or its display if its parent is null). |
Rectangle
|
Decorations.
getBounds
()
|
Rectangle
|
ToolItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
TreeItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
TableItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
Control.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent (or its display if its parent is null),
unless the receiver is a shell. |
Rectangle
|
CoolItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
TabItem.
getBounds
()
Returns a rectangle describing the receiver's size and location
relative to its parent. |
Rectangle
|
Display.
getBounds
()
Returns a rectangle describing the receiver's size and location. |
Rectangle
|
TreeItem.
getBounds
(int index)
Returns a rectangle describing the receiver's size and location
relative to its parent at a column in the tree. |
Rectangle
|
TableItem.
getBounds
(int index)
Returns a rectangle describing the receiver's size and location
relative to its parent at a column in the table. |
Rectangle
|
Monitor.
getClientArea
()
Returns a rectangle which describes the area of the
receiver which is capable of displaying data. |
Rectangle
|
Decorations.
getClientArea
()
|
Rectangle
|
Group.
getClientArea
()
|
Rectangle
|
TabFolder.
getClientArea
()
|
Rectangle
|
Scrollable.
getClientArea
()
Returns a rectangle which describes the area of the
receiver which is capable of displaying data (that is,
not covered by the "trimmings"). |
Rectangle
|
Display.
getClientArea
()
Returns a rectangle which describes the area of the
receiver which is capable of displaying data. |
Rectangle
|
TreeItem.
getImageBounds
(int index)
Returns a rectangle describing the size and location
relative to its parent of an image at a column in the
tree. |
Rectangle
|
TableItem.
getImageBounds
(int index)
Returns a rectangle describing the size and location
relative to its parent of an image at a column in the
table. |
Rectangle[]
|
Tracker.
getRectangles
()
Returns the bounds that are being drawn, expressed relative to the parent
widget. |
Rectangle
|
TreeItem.
getTextBounds
(int index)
Returns a rectangle describing the size and location
relative to its parent of the text at a column in the
tree. |
Rectangle
|
TableItem.
getTextBounds
(int index)
Returns a rectangle describing the size and location
relative to its parent of the text at a column in the
table. |
Rectangle
|
Display.
map
(
Control from,
Control to,
int x,
int y,
int width,
int height)
Maps a point from one coordinate system to another. |
Rectangle
|
Display.
map
(
Control from,
Control to,
Rectangle rectangle)
Maps a point from one coordinate system to another. |
Methods in
org.eclipse.ui.texteditor with parameters of type
Rectangle
|
static void
|
ImageUtilities.
drawImage
(
Image image,
GC gc,
Canvas canvas,
Rectangle r,
int align)
Deprecated. As of 3.0, replaced by
ImageUtilities.drawImage(Image, GC, Canvas, Rectangle, int)
|
static void
|
ImageUtilities.
drawImage
(
Image image,
GC gc,
Canvas canvas,
Rectangle r,
int halign,
int valign)
Deprecated. As of 3.0, replaced by
ImageUtilities.drawImage(Image, GC, Canvas, Rectangle, int, int)
|
void
|
DefaultMarkerAnnotationAccess.
paint
(
Annotation annotation,
GC gc,
Canvas canvas,
Rectangle bounds)
|
void
|
DefaultRangeIndicator.
paint
(
GC gc,
Canvas canvas,
Rectangle bounds)
|
void
|
MarkerAnnotation.
paint
(
GC gc,
Canvas canvas,
Rectangle r)
Deprecated. As of 3.0 replaced by
IAnnotationAccessExtension.paint(org.eclipse.jface.text.source.Annotation, GC, Canvas, Rectangle)
|
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.
|
|
|