JDK-8039464 : The scrollbar in JScrollPane has no right border if used WindowsLookAndFeel
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 7u51,8,9
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: windows_7
  • CPU: x86_64
  • Submitted: 2014-03-27
  • Updated: 2014-07-29
  • Resolved: 2014-04-25
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8 JDK 9
8u20 b13Fixed 9Fixed
Description
FULL PRODUCT VERSION :
1.7 u51

ADDITIONAL OS VERSION INFORMATION :
Windows 7 64

A DESCRIPTION OF THE PROBLEM :
When the JScrollPane a lot of item and the scrollbar small is
the right border of the scrollbar di not show.

REGRESSION.  Last worked in version 7u51

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Here is a simple Applet that show the problem

import javax.swing.JApplet;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;

public class ScrollbarApplet extends JApplet

{
	public void init()
	{
		try {
			UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");	
		} 
		catch (InstantiationException e) {}
		catch (ClassNotFoundException e) {}
		catch (UnsupportedLookAndFeelException e) {} 
		catch (IllegalAccessException e) {}

		JTextArea textArea = new JTextArea(5, 2000);		
		JScrollPane pane = new JScrollPane(textArea);
		this.add(pane);
	}
}

ACTUAL -
The small horizontal scrollbar has no right border

REPRODUCIBILITY :
This bug can be reproduced always.

---------- BEGIN SOURCE ----------
import javax.swing.JApplet;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;

public class ScrollbarApplet extends JApplet

{
	public void init()
	{
		try {
			UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");	
		} 
		catch (InstantiationException e) {}
		catch (ClassNotFoundException e) {}
		catch (UnsupportedLookAndFeelException e) {} 
		catch (IllegalAccessException e) {}

		JTextArea textArea = new JTextArea(5, 2000);		
		JScrollPane pane = new JScrollPane(textArea);
		this.add(pane);
	}
}
---------- END SOURCE ----------


Comments
http://cr.openjdk.java.net/~malenkov/8039464.9.1/
22-04-2014

It is reproducible with the Windows L&F on jdk8b129 and jdk9 (custom build).
08-04-2014

is it reproducible on 8 ?
08-04-2014