getSize
getSize: (Rectangle) -> DimensionThe size, as a new Dimension.
Rectangle.new(…)
WidgetItem.new(…):getCanvasBounds()
WidgetItem.new(…):getDraggingCanvasBounds()| Method | Returns | Description |
|---|---|---|
getSize() | Dimension | The size, as a new Dimension. |
getLocation() | Point | The corner, as a new Point. |
setLocation(number, number) | () | (Rectangle, number, number) -> (): Move the corner to x, y. |
setLocation(Point) | () | |
setSize(number, number) | () | (Rectangle, number, number) -> (): Resize. |
setSize(Dimension) | () | |
setBounds(number, number, number, number) | () | Set every field. |
add(number, number) | () | (Rectangle, number, number) -> (): Grow to include the point, as AWT's add. |
add(Point) | () | |
add(Rectangle) | () | |
translate(number, number) | () | Move by dx, dy, clamped as AWT clamps. |
grow(number, number) | () | Grow by h on the left and right and v top and bottom. |
intersection(Rectangle) | Rectangle | The overlap, as a new rectangle (empty, with AWT's negative size, when there is none). |
union(Rectangle) | Rectangle | The smallest rectangle holding both. |
new(number, number, number, number) | Rectangle | (number, number, number, number) -> Rectangle: The rectangle at x, y, width by height. |
new(number, number) | Rectangle | |
new(Point) | Rectangle | |
new(Dimension) | Rectangle | |
new(Rectangle) | Rectangle | |
new() | Rectangle |
| Field | Type | Description |
|---|---|---|
x | number | The x, AWT's field. |
y | number | The y, AWT's field. |
width | number | The width, AWT's field. |
height | number | The height, AWT's field. |
| Method | Returns | Description |
|---|---|---|
Component.getBounds | Rectangle | The bounds in the parent, as a new Rectangle. |
Graphics.getClipBounds | Rectangle? | The clip's bounds in user space, or nil with none. |
JList.getCellBounds | Rectangle? | The bounds of the cells of rows index0 to index1 (their union), or nil when either row is outside the model. |
JViewport.getViewRect | Rectangle | The visible part of the view, in view coordinates. |
LayoutableRenderableEntity.getBounds | Rectangle? | getBounds(): where the last render put it (nil for a TooltipComponent). |
Overlay.getBounds | Rectangle | Where it was last drawn: location and the size render answered. A copy. |
Overlay.getParentBounds | Rectangle? | The area dragging keeps it inside, or nil for the canvas. Nil; override it. |
RectangleClass.new | Rectangle | (number, number, number, number) -> Rectangle: The rectangle at x, y, width by height. |
Shape.getBounds | Rectangle | The integer bounding rectangle: the exact bounds with their edges rounded outward to whole pixels. |
Widget.getBounds | Rectangle | The canvas area the widget covers: [getCanvasLocation] (the draw record once the layer points install, the layout before) and its laid-ou… |
WidgetItem.getCanvasBounds | Rectangle | (WidgetItem) -> Rectangle: Where it is drawn, the drag included. The same Rectangle while the item is drawn there (and a new one once a… |
WidgetItem.getDraggingCanvasBounds | Rectangle? | Where it is drawn while dragged, nil when it is not: the same Rectangle getCanvasBounds() hands out while it is dragged. |
getSizegetSize: (Rectangle) -> DimensionThe size, as a new Dimension.
getLocationgetLocation: (Rectangle) -> PointThe corner, as a new Point.
setLocationsetLocation: ((Rectangle, number, number) -> ()) & ((Rectangle, Point) -> ())(Rectangle, number, number) -> (): Move the corner to x, y.
(Rectangle, Point) -> (): Move the corner to p.
setSizesetSize: ((Rectangle, number, number) -> ()) & ((Rectangle, Dimension) -> ())(Rectangle, number, number) -> (): Resize.
(Rectangle, Dimension) -> (): Resize to d.
setBoundssetBounds: (Rectangle, number, number, number, number) -> ()Set every field.
addadd: ((Rectangle, number, number) -> ()) & ((Rectangle, Point) -> ()) & ((Rectangle, Rectangle) -> ())(Rectangle, number, number) -> (): Grow to include the point, as AWT's add.
(Rectangle, Point) -> (): Grow to include p.
(Rectangle, Rectangle) -> (): Grow to include r.
translatetranslate: (Rectangle, number, number) -> ()Move by dx, dy, clamped as AWT clamps.
growgrow: (Rectangle, number, number) -> ()Grow by h on the left and right and v top and bottom.
intersectionintersection: (Rectangle, Rectangle) -> RectangleThe overlap, as a new rectangle (empty, with AWT's negative size, when there is none).
unionunion: (Rectangle, Rectangle) -> RectangleThe smallest rectangle holding both.
newnew: ((number, number, number, number) -> Rectangle) & ((number, number) -> Rectangle) & ((Point) -> Rectangle) & ((Dimension) -> Rectangle) & ((Rectangle) -> Rectangle) & (() -> Rectangle)(number, number, number, number) -> Rectangle: The rectangle at x, y, width by height.
(number, number) -> Rectangle: A width by height rectangle at the origin.
(Point) -> Rectangle: An empty rectangle at p.
(Dimension) -> Rectangle: A rectangle of size d at the origin.
(Rectangle) -> Rectangle: A copy of r.
() -> Rectangle: The empty rectangle at the origin.