Class CRectangleLocation
java.lang.Object
bibliothek.gui.dock.common.CLocation
bibliothek.gui.dock.common.location.AbstractStackholdingLocation
bibliothek.gui.dock.common.location.CRectangleLocation
A location describing a normalized element by giving its relative position
and size (relative meaning that the element is positioned in a rectangle of
size 1/1).
- Author:
- Benjamin Sigg
-
Constructor Summary
ConstructorsConstructorDescriptionCRectangleLocation(CSplitLocation parent, double x, double y, double width, double height) Creates a new location. -
Method Summary
Modifier and TypeMethodDescriptionaside()Deprecated.findMode()Gets the mode this location represents.findProperty(DockableProperty successor) Gets a path describing this location in terms of the DockingFrames.findRoot()Gets the name of the station this location belongs to.doubleGest the relative heightGets the parent location of this location.doublegetWidth()Gets the relative widthdoublegetX()Gets the relative x-coordinatedoublegetY()Gets the relative y-coordinatetoString()Methods inherited from class bibliothek.gui.dock.common.location.AbstractStackholdingLocation
stack, stackMethods inherited from class bibliothek.gui.dock.common.CLocation
base, base, equals, expandProperty, expandProperty, external, findProperty, hashCode, maximized, maximized, maximized, maximized, minimized, minimized, normalized, working
-
Constructor Details
-
CRectangleLocation
Creates a new location.- Parameters:
parent- the parent that knows the id of the root stationx- the relative x-coordinate, a value between 0 and 1 is preferredy- the relative y-coordinate, a value between 0 and 1 is preferredwidth- the relative width, a value between 0 and 1 is preferredheight- the relative height, a value between 0 and 1 is preferred
-
-
Method Details
-
getX
public double getX()Gets the relative x-coordinate- Returns:
- a value between 0 and 1
-
getY
public double getY()Gets the relative y-coordinate- Returns:
- a value between 0 and 1
-
getWidth
public double getWidth()Gets the relative width- Returns:
- a value between 0 and 1
-
getHeight
public double getHeight()Gest the relative height- Returns:
- a value between 0 and 1
-
findRoot
Description copied from class:CLocationGets the name of the station this location belongs to. This can be the id of anyCStation. -
getParent
Description copied from class:CLocationGets the parent location of this location. Some root-locations may never have a parent. -
findMode
Description copied from class:CLocationGets the mode this location represents. -
findProperty
Description copied from class:CLocationGets a path describing this location in terms of the DockingFrames.- Specified by:
findPropertyin classCLocation- Parameters:
successor- the path of the elements above this location ornull- Returns:
- the path to this location or
null, can also besuccessor
-
aside
Deprecated.seeCLocation.aside()for an explanation.Description copied from class:CLocationReturns aCLocationthat describes the location of an element that should be inserted next to this location. -
toString
-
CLocation.aside()for an explanation.