|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.globalmentor.beans.BoundPropertyObject
com.guiseframework.event.GuiseBoundPropertyObject
com.guiseframework.component.layout.AbstractLayout<RegionConstraints>
com.guiseframework.component.layout.RegionLayout
public class RegionLayout
A layout that defines locations of components in internationalized relative terms.
This layout uses default constraints of Region.CENTER.
The region will span two of the components, if present, across the perpendicular flow.
Which flow is spanned across the other is determined by setting setSpanFlow(Flow).
For example, in a right-to-left top-to-bottom orientation, a span flow of Flow.LINE (the default)
will result in the top and bottom components spanning across the space used by the left, center, and right components.
Region| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.guiseframework.component.layout.AbstractLayout |
|---|
AbstractLayout.ConstraintsPropertyChangeListener |
| Field Summary | |
|---|---|
static java.lang.String |
FIXED_PROPERTY
The bound property of the fixed setting. |
static java.lang.String |
LINE_ALIGNMENT_PROPERTY
The bound property of the line alignment. |
static java.lang.String |
LINE_EXTENT_PROPERTY
The line extent (width in left-to-right top-to-bottom orientation) bound property. |
static java.lang.String |
PADDING_LINE_FAR_EXTENT_PROPERTY
The bound property of the line far padding extent. |
static java.lang.String |
PADDING_LINE_NEAR_EXTENT_PROPERTY
The bound property of the line near padding extent. |
static java.lang.String |
PADDING_PAGE_FAR_EXTENT_PROPERTY
The bound property of the page far padding extent. |
static java.lang.String |
PADDING_PAGE_NEAR_EXTENT_PROPERTY
The bound property of the page near padding extent. |
static java.lang.String |
PAGE_ALIGNMENT_PROPERTY
The bound property of the page alignment. |
static java.lang.String |
PAGE_EXTENT_PROPERTY
The page extent (height in left-to-right top-to-bottom orientation) bound property. |
static java.lang.String |
SPAN_FLOW_PROPERTY
The bound property of the span flow. |
| Fields inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS |
| Constructor Summary | |
|---|---|
RegionLayout()
Default constructor with Flow.LINE span flow. |
|
RegionLayout(Flow spanFlow)
Span flow constructor. |
|
| Method Summary | |
|---|---|
RegionConstraints |
createDefaultConstraints()
Creates default constraints for the container. |
double |
getAlignment(Flow flow)
Returns the default alignment of the indicated flow relative to the beginning of the alignment axis. |
Component |
getComponent(Region region)
Retrieves a component for a given region. |
java.lang.Class<? extends RegionConstraints> |
getConstraintsClass()
|
Extent |
getExtent(Flow flow)
Returns the default extent of the indicated flow. |
double |
getLineAlignment()
|
Extent |
getLineExtent()
Returns the default extent of the line flow. |
Extent |
getPaddingExtent(Border border)
Returns the default padding extent of the indicated border. |
Extent |
getPaddingLineFarExtent()
Returns the default padding extent of the line far page near border. |
Extent |
getPaddingLineNearExtent()
Returns the default padding extent of the line near page near border. |
Extent |
getPaddingPageFarExtent()
Returns the default padding extent of the line far page far border. |
Extent |
getPaddingPageNearExtent()
Returns the default padding extent of the line near page far border. |
double |
getPageAlignment()
|
Extent |
getPageExtent()
Returns the default extent of the page flow. |
Flow |
getSpanFlow()
|
boolean |
isFixed()
|
void |
setAlignment(Flow flow,
double newAlignment)
Sets the alignment of a given flow. |
void |
setExtent(Flow flow,
Extent newExtent)
Sets the default extent of a given flow. |
void |
setFixed(boolean newFixed)
Sets whether the sizes of the regions are fixed or will dynamically change to support the given content. |
void |
setLineAlignment(double newAlignment)
Sets the default alignment of the line flow. |
void |
setLineExtent(Extent newExtent)
Sets the default extent of the line flow. |
void |
setPaddingExtent(Border border,
Extent newPaddingExtent)
Sets the default padding extent of a given border. |
void |
setPaddingExtent(Extent newPaddingExtent)
Sets the default padding extent of all borders. |
void |
setPaddingLineFarExtent(Extent newPaddingExtent)
Sets the default padding extent of the line far border. |
void |
setPaddingLineNearExtent(Extent newPaddingExtent)
Sets the default padding extent of the line near border. |
void |
setPaddingPageFarExtent(Extent newPaddingExtent)
Sets the default padding extent of the page far border. |
void |
setPaddingPageNearExtent(Extent newPaddingExtent)
Sets the default padding extent of the page near border. |
void |
setPageAlignment(double newAlignment)
Sets the alignment of the page flow. |
void |
setPageExtent(Extent newExtent)
Sets the default extent of the page flow. |
void |
setSpanFlow(Flow newSpanFlow)
Sets the logical axis which will span components across the other logical axis. |
| Methods inherited from class com.guiseframework.component.layout.AbstractLayout |
|---|
addComponent, componentConstraintsChanged, fireConstraintsPropertyChange, getComponentConstraintsChangeListener, getConstraints, getConstraintsPropertyChangeListener, getOwner, removeComponent, setOwner |
| Methods inherited from class com.guiseframework.event.GuiseBoundPropertyObject |
|---|
getSession |
| Methods inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.guiseframework.component.layout.Layout |
|---|
getSession |
| Methods inherited from interface com.globalmentor.beans.PropertyBindable |
|---|
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, hasPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener |
| Field Detail |
|---|
public static final java.lang.String FIXED_PROPERTY
public static final java.lang.String LINE_ALIGNMENT_PROPERTY
public static final java.lang.String PAGE_ALIGNMENT_PROPERTY
public static final java.lang.String LINE_EXTENT_PROPERTY
public static final java.lang.String PAGE_EXTENT_PROPERTY
public static final java.lang.String PADDING_LINE_NEAR_EXTENT_PROPERTY
public static final java.lang.String PADDING_LINE_FAR_EXTENT_PROPERTY
public static final java.lang.String PADDING_PAGE_NEAR_EXTENT_PROPERTY
public static final java.lang.String PADDING_PAGE_FAR_EXTENT_PROPERTY
public static final java.lang.String SPAN_FLOW_PROPERTY
| Constructor Detail |
|---|
public RegionLayout()
Flow.LINE span flow.
public RegionLayout(Flow spanFlow)
spanFlow - The logical axis which will span components across the other logical axis.
java.lang.NullPointerException - if the given span flow is null.| Method Detail |
|---|
public boolean isFixed()
public void setFixed(boolean newFixed)
Boolean.
newFixed - true if the sizes of the regions are fixed, or false if the regions will dynamically change to support the given content.FIXED_PROPERTYpublic double getAlignment(Flow flow)
flow - The flow for which an alignment should be returned.
public double getLineAlignment()
public double getPageAlignment()
public void setAlignment(Flow flow,
double newAlignment)
Double.
flow - The flow for which the alignment should be set.newAlignment - The alignment of the region relative to the beginning of the given flow.
java.lang.NullPointerException - if the given flow is null.LINE_ALIGNMENT_PROPERTY,
PAGE_ALIGNMENT_PROPERTY,
RegionConstraints.setAlignment(Flow, double)public void setLineAlignment(double newAlignment)
Double.
newAlignment - The line alignment of the region relative to the beginning of the alignment axis.LINE_ALIGNMENT_PROPERTYpublic void setPageAlignment(double newAlignment)
Double.
newAlignment - The page alignment of the region relative to the beginning of the alignment axis.PAGE_ALIGNMENT_PROPERTYpublic Extent getExtent(Flow flow)
flow - The flow for which an extent should be returned.
public Extent getLineExtent()
null if no preferred extent has been specifiedpublic Extent getPageExtent()
null if no preferred extent has been specified
public void setExtent(Flow flow,
Extent newExtent)
flow - The flow for which the extent should be set.newExtent - The new requested extent of the region, or null there is no extent preference.
java.lang.NullPointerException - if the given flow is null.LINE_EXTENT_PROPERTY,
PAGE_EXTENT_PROPERTY,
RegionConstraints.setExtent(Flow, Extent)public void setLineExtent(Extent newExtent)
newExtent - The new requested extent of the region, or null there is no extent preference.LINE_EXTENT_PROPERTYpublic void setPageExtent(Extent newExtent)
newExtent - The new requested extent of the region, or null there is no extent preference.PAGE_EXTENT_PROPERTYpublic Extent getPaddingExtent(Border border)
border - The border for which a padding extent should be returned.
public Extent getPaddingLineNearExtent()
public Extent getPaddingLineFarExtent()
public Extent getPaddingPageNearExtent()
public Extent getPaddingPageFarExtent()
public void setPaddingExtent(Border border,
Extent newPaddingExtent)
border - The border for which the padding extent should be set.newPaddingExtent - The padding extent.
java.lang.NullPointerException - if the given border and/or padding extent is null.PADDING_LINE_NEAR_EXTENT_PROPERTY,
PADDING_LINE_FAR_EXTENT_PROPERTY,
PADDING_PAGE_NEAR_EXTENT_PROPERTY,
PADDING_PAGE_FAR_EXTENT_PROPERTY,
RegionConstraints.setPaddingExtent(Border, Extent)public void setPaddingLineNearExtent(Extent newPaddingExtent)
newPaddingExtent - The padding extent.
java.lang.NullPointerException - if the given padding extent is null.PADDING_LINE_NEAR_EXTENT_PROPERTYpublic void setPaddingLineFarExtent(Extent newPaddingExtent)
newPaddingExtent - The padding extent, or null if the default padding extent should be used.
java.lang.NullPointerException - if the given padding extent is null.PADDING_LINE_FAR_EXTENT_PROPERTYpublic void setPaddingPageNearExtent(Extent newPaddingExtent)
newPaddingExtent - The padding extent, or null if the default padding extent should be used.
java.lang.NullPointerException - if the given padding extent is null.PADDING_PAGE_NEAR_EXTENT_PROPERTYpublic void setPaddingPageFarExtent(Extent newPaddingExtent)
newPaddingExtent - The padding extent, or null if the default padding extent should be used.
java.lang.NullPointerException - if the given padding extent is null.PADDING_PAGE_FAR_EXTENT_PROPERTYpublic void setPaddingExtent(Extent newPaddingExtent)
setPaddingExtent(Border, Extent) for each border.
newPaddingExtent - The padding extent.
java.lang.NullPointerException - if the given padding extent is null.PADDING_LINE_NEAR_EXTENT_PROPERTY,
PADDING_LINE_FAR_EXTENT_PROPERTY,
PADDING_PAGE_NEAR_EXTENT_PROPERTY,
PADDING_PAGE_FAR_EXTENT_PROPERTYpublic Flow getSpanFlow()
public void setSpanFlow(Flow newSpanFlow)
newSpanFlow - The logical axis which will span components across the other logical axis.
java.lang.NullPointerException - if the given span flow is null.SPAN_FLOW_PROPERTYpublic java.lang.Class<? extends RegionConstraints> getConstraintsClass()
public RegionConstraints createDefaultConstraints()
#CENTER_CONSTRAINTS.
The new extents will have the default alignment, extent, and padding.
public Component getComponent(Region region)
region - The region for which a component should be returned.
null if no component has the given region specified.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||