/[classpath]/classpath/javax/swing/JEditorPane.java
ViewVC logotype

Diff of /classpath/javax/swing/JEditorPane.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.28 by abalkiss, Thu Dec 8 20:00:42 2005 UTC revision 1.29 by abalkiss, Thu Dec 8 20:16:37 2005 UTC
# Line 518  public class JEditorPane extends JTextCo Line 518  public class JEditorPane extends JTextCo
518    
519    public JEditorPane()    public JEditorPane()
520    {    {
521      init(createDefaultEditorKit());      init();
522        setEditorKit(createDefaultEditorKit());
523    }    }
524    
525    public JEditorPane(String url) throws IOException    public JEditorPane(String url) throws IOException
# Line 528  public class JEditorPane extends JTextCo Line 529  public class JEditorPane extends JTextCo
529    
530    public JEditorPane(String type, String text)    public JEditorPane(String type, String text)
531    {    {
532      init(createEditorKitForContentType(type));      init();
533        setEditorKit(createEditorKitForContentType(type));
534      setText(text);      setText(text);
535    }    }
536    
537    public JEditorPane(URL url) throws IOException    public JEditorPane(URL url) throws IOException
538    {    {
539      this();      init ();
540        setEditorKit (createEditorKitForContentType("text/html"));;
541      setPage(url);      setPage(url);
542    }    }
543        
544    /**    /**
545     * Called by the constructors to set the EditorKit and set up the     * Called by the constructors to set up the default bindings for content
546     * default bindings for content types and EditorKits.     * types and EditorKits.
    *  
    * @param kit the initial EditorKit  
547     */     */
548    void init(EditorKit kit)    void init()
549    {    {
     setEditorKit(kit);  
550      editorMap = new HashMap();      editorMap = new HashMap();
551      registerMap = new HashMap();      registerMap = new HashMap();
552      registerEditorKitForContentType("application/rtf",      registerEditorKitForContentType("application/rtf",

Legend:
Removed from v.1.28  
changed lines
  Added in v.1.29

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26