JDK-4779930 : windows look&feel: scrollbar arrows are off by one pixel
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 1.4.2
  • Priority: P4
  • Status: Closed
  • Resolution: Cannot Reproduce
  • OS: solaris_10
  • CPU: generic
  • Submitted: 2002-11-15
  • Updated: 2022-08-30
  • Resolved: 2022-08-30
Related Reports
Relates :  
Description
In Swing's windows look and feel, the arrows in scrollbar buttons are
shifted one pixel too far to the left, making then off-center.

This sounds harmless, but in fact significantly contributes to Swing
applications looking "off" on the windows platform.  look&feel fidelity
issues should be given a very high priority.

This was reported as part of 4268204 (marked as integrated) but was never
actually fixed.

Comments
PUBLIC COMMENTS In Swing's windows look and feel, the arrows in scrollbar buttons are shifted one pixel too far to the left, making then off-center.
24-09-2004

EVALUATION The algorithm used in BasicArrowButton.java is slightly off from the windows algorithm and thus the smaller arrows are rendered offset. Analysis of the algorithm used on Windows2000 for the upper scrollbutton of a native vertical scrollbar produces the following metrics given variation of the desktop property "Scrollbar:Size": SB Size 8 9 10 11 12 13 14 15 16 17 18 19 =========================================================== tip-x 4 4 4 5 5 6 6 7 7 8 8 9 tip-y 3 4 4 4 4 5 4? 5 6 6 6 7 arrow-hgt 2 2 2 2 3 3 3 3 4 4 4 5? We need to re-write our algorithm to match. ###@###.### 2002-12-04
04-12-2002