Pack.setHorizontal

void setHorizontal()

Sets the pack to horizontal layout.