|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdsto.dfc.swt.util.Geometry
public final class Geometry
Basic geometrical utilities for SWT.
| Field Summary | |
|---|---|
static int |
BOTTOM
|
static int |
BOTTOM_LEFT
|
static int |
BOTTOM_RIGHT
|
static int |
CENTER
|
static int |
LEFT
|
static int |
MID_BOTTOM
|
static int |
MID_LEFT
|
static int |
MID_RIGHT
|
static int |
MID_TOP
|
static int |
RIGHT
|
static int |
TOP
|
static int |
TOP_LEFT
|
static int |
TOP_RIGHT
|
| Method Summary | |
|---|---|
static org.eclipse.swt.graphics.Point |
bumpRectangle(org.eclipse.swt.graphics.Rectangle windowRect)
Return a rectangle's position, adjusting so it does not go outside the screen. |
static void |
bumpRectangle(org.eclipse.swt.graphics.Rectangle parentRect,
org.eclipse.swt.graphics.Rectangle childRect)
Ensure that childRect is in parentRect, and move it into it if not. |
static boolean |
contains(org.eclipse.swt.graphics.Rectangle r1,
org.eclipse.swt.graphics.Rectangle r2)
Test if one rectangle fully contains another. |
static int |
offsetForAlignment(int parentLength,
int childLength,
int alignment)
Calculate offset from a parent length necessary to align a child length. |
static org.eclipse.swt.graphics.Point |
offsetForAlignment(org.eclipse.swt.graphics.Point parentSize,
org.eclipse.swt.graphics.Point childSize,
int alignment)
Calculate offset of a child region from a parent region necessary to align child region. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int CENTER
public static final int LEFT
public static final int RIGHT
public static final int TOP
public static final int BOTTOM
public static final int TOP_LEFT
public static final int MID_TOP
public static final int TOP_RIGHT
public static final int MID_RIGHT
public static final int BOTTOM_RIGHT
public static final int MID_BOTTOM
public static final int BOTTOM_LEFT
public static final int MID_LEFT
| Method Detail |
|---|
public static org.eclipse.swt.graphics.Point offsetForAlignment(org.eclipse.swt.graphics.Point parentSize,
org.eclipse.swt.graphics.Point childSize,
int alignment)
parentSize - Size of parent region.childSize - Size of child region;alignment - Alignment of child relative to parent.
public static int offsetForAlignment(int parentLength,
int childLength,
int alignment)
parentLength - Size of parent region.childLength - Size of child region;alignment - Alignment of child relative to parent. One of LEFT/TOP,
CENTER or RIGHT/BOTTOM.public static org.eclipse.swt.graphics.Point bumpRectangle(org.eclipse.swt.graphics.Rectangle windowRect)
public static void bumpRectangle(org.eclipse.swt.graphics.Rectangle parentRect,
org.eclipse.swt.graphics.Rectangle childRect)
public static boolean contains(org.eclipse.swt.graphics.Rectangle r1,
org.eclipse.swt.graphics.Rectangle r2)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||