|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SpacePartitionerInterface
SpacePartitionerInterface is designed to allow a given amount of space to be partitioned between a number of elements. An example of an element would be a column in an AutoSizingGridLayout.
AutoSizingGridLayout
,
EqualSpacePartitioner
,
ProportionalSpacePartitioner
,
MinMaxSpacePartitioner
Method Summary | |
---|---|
int |
getPartitionedSpace(int[] sizes,
int totalSize,
int[] preferredSizes)
Partition the space represented by totalSize into parts and store the
resulting size in the sizes array. |
Method Detail |
---|
int getPartitionedSpace(int[] sizes, int totalSize, int[] preferredSizes)
totalSize
into parts and store the
resulting size in the sizes
array. preferredSizes
may also be
passed in to specify a preferred size for each of the parts.
Note that the length of the sizes
array and the preferredSizes
array should be equal if the preferredSizes
array is specified.
sizes
- The array to return the sizes of the parts in.totalSize
- The amount of space to split up between the parts.preferredSizes
- The preferred size of the parts. This may be null to indicate
that no preferred size is available.
totalSize
left over after the space has been allocated.
Note that for some implementations, this value may be negative.
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |