Re: JAVA TEXT AREA GUI problem
- From: "Andrew Thompson" <andrewthommo@xxxxxxxxx>
- Date: 23 Sep 2006 21:20:04 -0700
KL wrote:
Is anybody know how to create a JAVA TEXT AREA
That is one of ..
- Java text area (generic)
- Java TextArea (AWT)
- Java JTextArea (Swing)
...so please be specific and refrain from SHOUTING at us.
...with multiple color text
in each line?
Many Swing components are 'HTML aware',
but not JTextArea's .. E.G.
<sscce>
import javax.swing.*;
class HTMLTextArea {
public static void main(String[] args) {
String content =
"<html><body><h1>Ha!</h1><p style='color: red'>Blah...";
JTextArea ta = new JTextArea(content);
JOptionPane.showMessageDialog(null, ta);
JLabel l = new JLabel(content);
JOptionPane.showMessageDialog(null, l);
}
}
<sscce>
Andrew T.
.
- Follow-Ups:
- Re: JAVA TEXT AREA GUI problem
- From: KL
- Re: JAVA TEXT AREA GUI problem
- From: KL
- Re: JAVA TEXT AREA GUI problem
- Prev by Date: Re: list of java guis
- Next by Date: Re: JAVA TEXT AREA GUI problem
- Previous by thread: list of java guis
- Next by thread: Re: JAVA TEXT AREA GUI problem
- Index(es):
Relevant Pages
|