Programming Examples

Are you a Programmer or Application Developer or a DBA? Take a cup of coffee, sit back and spend few minutes here :)

Tag Archive for ‘VERTICAL_SPLIT’

JSplitPane – Splitting the Components

JSplitPane Example

The example shows two JTextField controls. A JSplitPane splits these two text fields vertically by running a divider horizontally. You can see the divider with a pair of arrows on the left side. These arrows help to expand the component when clicked. For example, if you click the down-arrow, top text field expands and bottom text field holds only the minimal needed space. When you click the down-arrow again, the JSplitPane hides bottom text field and shows only the top text field. This aspect is called One-Click-Expandable.

We can also adjust the size of the component by manually moving the divider. Note, the split pane can divide the component horizontally as well. Now, we will create this example and learn about the JSplitPane and in the meantime, you can watch the below YouTube video to learn the basics.

Continue Reading →