@Retention(RUNTIME)
@Target({TYPE,FIELD})
public @interface Bounds
-
Optional Element Summary
Optional Elements
Modifier and Type |
Optional Element |
Description |
int[] |
bounds |
Specifies the bounds for the annotated component.
|
int[] |
max |
Sets the maximum size for the annotated component.
|
int[] |
min |
Sets the minimum size for the annotated component.
|
int[] |
preferred |
Sets the preferred size of this annotated component.
|
int[] |
size |
Resizes this component so that it has the given width and height.
|
-
Element Details
-
int[] preferred
Sets the preferred size of this annotated component. The returned array
should have a size of at least
2
and should contain the
following values:
preferred := { <width>, <height> }
- Returns:
- the preferred size for the annotated component.
- Default:
- {-1, -1}
-
int[] size
Resizes this component so that it has the given width and height. The
structure of this array is the following:
size := { <width>, <height> }
- Returns:
- the new size for the annotated component
- Default:
- {-1, -1}
-
int[] bounds
Specifies the bounds for the annotated component. This attribute is
structured as follows:
bounds := { <x>, <y>, <width>, <height> }
- Returns:
- the new bounds' values for the annotated component
- Default:
- {-1, -1, -1, -1}
-
int[] min
Sets the minimum size for the annotated component. The structure of
the returned array should be the same as defined in
preferred()
.
- Returns:
- the new minimum size
- See Also:
preferred()
- Default:
- {-1, -1}
-
int[] max
Sets the maximum size for the annotated component. The structure of
the returned array should be the same as defined in
preferred()
.
- Returns:
- the new maximum siz
- See Also:
preferred()
- Default:
- {-1, -1}