horizontalAlignment
Sets where a component's content sits along its width, when it is given more width than it needs.
Applies to labels, to everything built on a button, and to single-line text fields.
Return
this chain with the horizontal alignment declared on it.
Parameters
alignment
a HorizontalAlignment SwingConstants value; LEADING and TRAILING resolve against the component's orientation. Any other value is refused with an IllegalArgumentException.