JDK-4684377 : JEditorPane garbles HTML Table content's display
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 1.4.0
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: solaris_7
  • CPU: sparc
  • Submitted: 2002-05-14
  • Updated: 2003-03-25
  • Resolved: 2003-03-25
Related Reports
Duplicate :  
Relates :  
Description
I used the same test program from bug 4314198 using JDK1.4 to read a plain HTML file with tables. (See the attached file). 9 out of 10 test runs, the text contents in the table display got squashed.

Please evaluate. Thanks!

--------------------------------------------------
java version
--------------------------------------------------
% java -version
java version "1.4.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-b92)
Java HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode)

--------------------------------------------------
test program
--------------------------------------------------
public class TestHTMLRead extends javax.swing.JFrame
    implements java.awt.event.ActionListener
{
    java.net.URL url;
    javax.swing.JEditorPane editorPane;
    javax.swing.JScrollPane scrollPane;
    javax.swing.JButton     reloadButton;

    public TestHTMLRead()
    {
        editorPane = new javax.swing.JEditorPane();
        scrollPane = new javax.swing.JScrollPane(editorPane);
        getContentPane().add(java.awt.BorderLayout.CENTER, scrollPane);

        reloadButton = new javax.swing.JButton("Reload");
        reloadButton.addActionListener(this);
        getContentPane().add(java.awt.BorderLayout.SOUTH, reloadButton);
        setSize(750, 425);
        setDefaultCloseOperation(javax.swing.JFrame.DISPOSE_ON_CLOSE);
    }

    public void reloadBrowser()
    {
        try {
            url = new java.net.URL("file:/tmp/report.html");
            editorPane.setPage(url);
        } catch (java.io.IOException ex) { ex.printStackTrace(); }
    }

    public void actionPerformed(java.awt.event.ActionEvent event)
    {
        Object source = event.getSource();
        if (source == reloadButton)
        {
            reloadBrowser();
        }
    }

    public static void main(String[] argv)
    {
        (new TestHTMLRead()).show();
    }
}

--------------------------------------------------
sample html file
--------------------------------------------------
See attachment (report.html).
 

Comments
WORK AROUND
11-06-2004

SUGGESTED FIX
11-06-2004

PUBLIC COMMENTS
10-06-2004

EVALUATION I have not noticed any problem. Could you tell me what should I look at? ###@###.### 2002-05-14 ---------------- I can reproduce the bug. Thank you Jessica for the info. ###@###.### 2002-05-28 Name: dsR10138 Date: 03/24/2003 This bug is fixed by the fix to bug 4765331. I'm closing this bug as a duplicate of 4765331. ###@###.### 2003-03-24 ======================================================================
24-03-2003