September 2005
Beginner
576 pages
13h 6m
English
One of the easiest ways for a user to enter numeric input is by using a slider, a component that can be dragged from side to side or up and down.
Sliders are represented in Swing by the JSlider class. Figure 16.2 shows what a slider component looks like.

Sliders enable a number to be chosen from between a minimum and maximum range of values. These values can be displayed on a label that includes the minimum value, maximum value, and intermediate values (as shown later in Figure 16.3).
You can create a horizontal slider with one of the following ...
Read now
Unlock full access