JTextPane in Java Swing

Home  »  Java  »  Advance Java  »  Java Swing II  »  JTextPane


A text component that can be marked up with attributes that are represented graphically.

Method or Constructor Description
JTextPane()
JTextPane(StyledDocument)
Creates a text pane. The optional argument specifies the text pane's model.
StyledDocument getStyledDocument
setStyledDocument(StyledDocument)
Gets or sets the text pane's model.

A Simple example of JTextPane...



C:\>jdk1.4\bin>javac JTextPaneDemo.java
C:\>jdk1.4\bin>java JTextPaneDemo



"Output of JTextPaneDemo.class"


Download Complete Program

  -  



Java Swing-II


JOptionPane Class Input Dialog Boxes JSliders
JProgressBars JTables JTabbedPane
JMenu JPopupMenu JToolBar
JFileChooser JScrollBar JScrollPane
JRootPane JTextPane JTree
JSplitPane JDesktopPane JEditorPane




1 comment: