|
|
Display foreign language in JeditorPane
I wanna to display the other language like big5 in the JeditorPane, I
tried to do this:
import javax.swing.text.*;
import javax.swing.*;
import java.io.*;
import java.awt.*;
public class temp {
public static void main(String[] args) {
JEditorPane jep = new JEditorPane();
jep.setEditable(false);
jep.setContentType("text/html; charset=big5");
try {
jep.setPage("http://hk.yahoo.com");
}
catch (IOException e) {
jep.setContentType("text/html");
jep.setText("<html>Could not load http://www.oreilly.com
</html>");
}
JScrollPane scrollPane = new JScrollPane(jep);
JFrame f = new JFrame("O'Reilly & Associates");
// Next line requires Java 1.3
f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
f.getContentPane().add(scrollPane);
f.setSize(512, 342);
f.show();
}
}
It's not working... what's the problem? how can I solve it? any
detailed example
??
Cheers
Stephen
|
|
0
|
|
|
|
Reply
|
wksh834 (1)
|
9/29/2003 4:57:52 AM |
|
|
0 Replies
116 Views
(page loaded in 0.032 seconds)
Similiar Articles: A human model - comp.cad.solidworks... fully movable appendages and I remember that the parts were names in a foreign language ... C++ code for 3ds load and display on WinXP and Linux - comp ..... manipulation ... Unicode Character to Font Mapping - comp.fonts> Now assume that i have 2 characters that i need to display with code > 0x0FAB ... Note that I have no foreign language support installed, so the list of languages is ... IPv6 addresses in mysql databases - comp.databases.mysql ...... NTOA() to translate to and from the usual text display ... 77-osx10.4-powerpc/data tmpdir =3D /tmp language =3D /usr ... Insert statements and foreign keys etc.. - comp ... 'Deferred' functions? - comp.lang.javascriptYou need to be aware that there is no single language ... support several layout engines, some support "foreign ... >> You may display the error message, but please do not ... Insert statements and foreign keys etc.. - comp.databases.mysql ...> If you want foreign key constraints to work, yes. ... and/or the corresponding functions in your host language ... appropriate times (like at the time of an order) show ... programmer's calculator - comp.lang.java.helpI have Java macros all over my website to display in ... or maintaining dual versions for domestic and foreign ... lang.java.help Niue - a tiny, embeddable stack language ... DSP Job opening in Sacramento, CA - comp.dsp... Lyons wrote: >> >> Well, what I'm saying is that 20,000 guys' will >> show ... > If you think I must learn a foreign language to > to get by in the U.S., then we'll never ... Spell check - comp.mail.eudora.ms-windows... eudora.ms-windows/msg/c0d95ce64= 0aba5ea "Foreign ... 1033 1 7 > >#LID 1033 is the language ID for language ... Statistics for PDF document - comp.text.pdf Display ... key violations when there are no key violations - comp.databases ...In other words, there is a relationship (foreign key ... need to see at least the ddl (data definition language ... arch.fpga > There was no violations, nothing did show ... When Knuth and I were young - Part 5 - comp.lang.asm.x86 ...... it in RPG, COBOL, FORTRAN, PL/I, and machine language. ... in a ProLog PROM programmer to calculate and display a ... Scrolling in a JEditorPane - comp.lang.java.help When Knuth ... How do I display foreign language characters? - Yahoo! AnswersBest Answer: To install East Asian language files on your computer open the Control Panel. Double click the Open Regional and Language icon. On the ... Displaying foreign language characters on webpages? - Yahoo! UK ...Best Answer: Have you installed the language pack for you computer operated system? If your not XP professional then you might have to download the ... 7/22/2012 2:45:53 PM
|
|
|
|
|
|
|
|
|