-
Bug
-
Resolution: Not an Issue
-
P3
-
None
-
1.4.0, 5.0
-
tiger
-
sparc
-
generic
If JSlider.setSnapToTicks(false) is invoked on a JSlider and the mouse is used to
move the knob, the knob moves smoothly, as expected.
However, if the keyboard (ie, the left and right arrow keys) is used to move the
knob, the knob resolves to the closest tick mark; it doesn't move smoothly as when
the mouse is used to move the knob. This behavior seems to be the same as the
behavior when setSnapToTicks(true) is invoked on the slider.
The fact that the JSlider is expected to behave this way if setSnapToTicks(false) is
invoked on it and the keyboard is used to move the knob does not seem to be
specified.
If this is expected behavior, it should be specified.
This behavior is seen when the following JCK 1.5 test is executed:
api/javax_swing/interactive/JSliderTests.html#JSlider[JSliderTest0017]
This behavior can be recreated by running the attached program
(JSliderSnapToTicks.java), and using the keyboard to move the knob of the
slider. The program displays a JSlider on which setSnapToTicks(false) has
been invoked.
###@###.### 2003-10-08
move the knob, the knob moves smoothly, as expected.
However, if the keyboard (ie, the left and right arrow keys) is used to move the
knob, the knob resolves to the closest tick mark; it doesn't move smoothly as when
the mouse is used to move the knob. This behavior seems to be the same as the
behavior when setSnapToTicks(true) is invoked on the slider.
The fact that the JSlider is expected to behave this way if setSnapToTicks(false) is
invoked on it and the keyboard is used to move the knob does not seem to be
specified.
If this is expected behavior, it should be specified.
This behavior is seen when the following JCK 1.5 test is executed:
api/javax_swing/interactive/JSliderTests.html#JSlider[JSliderTest0017]
This behavior can be recreated by running the attached program
(JSliderSnapToTicks.java), and using the keyboard to move the knob of the
slider. The program displays a JSlider on which setSnapToTicks(false) has
been invoked.
###@###.### 2003-10-08