Skip to content

Instantly share code, notes, and snippets.

import java.awt.BorderLayout;
import javax.swing.JEditorPane; import javax.swing.JFrame; import javax.swing.JScrollPane; import javax.swing.JSplitPane;
import javax.swing.SwingUtilities; import javax.swing.text.html.HTMLEditorKit; import javax.swing.text.html.StyleSheet;
/** * Test application for HTMLEditorKit bug. */ public class HTMLEditorKitBugTest { public static void main(String[] args)
{ SwingUtilities.invokeLater(new Runnable() { @Override public void run() { new HTMLEditorKitBugTest().run();} }); }
private void run() { JSplitPane split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT); split.setLeftComponent(new
JScrollPane(createCustomisedEditorPane())); split.setRightComponent(new JScrollPane(createNormalEditorPane()));