-
Bug
-
Resolution: Fixed
-
P2
-
5.0
-
b42
-
x86
-
linux
###@###.### 2004-01-27
J2SE Version (please include all output from java -version flag):
java version "1.5.0-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-beta-b32)
Java HotSpot(TM) Client VM (build 1.5.0-beta-b32, mixed mode)
Does this problem occur on J2SE 1.4 or 1.4.1 or 1.4.2? Yes / No (pick one)
No. works fine with 1.4.2.
Operating System Configuration Information (be specific):
Linux (Debian Unstable), can be reproduced on RedHat 7.3 as well
Hardware Configuration Information (be specific):
Dell Inspiron 8500, 1GB RAM, Nvidia graphics adapter
Bug Description:
Graphics.copyarea() is used in may scrolling components. The
documentation states that paint() is invoked for regions that could not
be copied because they were obscured by an overlapping window:
* If a portion of the source rectangle lies outside the bounds
* of the component, or is obscured by another window or component,
* <code>copyArea</code> will be unable to copy the associated
* pixels. The area that is omitted can be refreshed by calling
* the component's <code>paint</code> method.
This works fine with J2SDK1.4.2 but does no longer work with J2SDK
1.5.0b32 on Linux. Works fine on Windows.
Steps to Reproduce (be specific):
Run the attached program on Linux and try scrolling using either
scrollbar or mousewheel. Observe that the overlapped window causes
repaint errors.
Test program:
import javax.swing.*;
public class CopyAreaTest
{
public static void main(String[] args)
{
StringBuffer buf = new StringBuffer();
for (int i = 0; i < 1000; i++)
{
buf.append("This is line"+i+"\n");
}
JTextArea textArea = new JTextArea(buf.toString());
JFrame frame = new JFrame("Test");
frame.getContentPane().add(new JScrollPane(textArea));
frame.pack();
frame.setBounds(100,100,500,500);
frame.show();
JWindow window = new JWindow(frame);
window.setBounds(150,150,200,200);
window.show();
}
}
- duplicates
-
JDK-5010984 JScrollPane doesn't repaint unobscured areas while scrolling
-
- Closed
-