Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How do you display HTML Content inside a Java (Swing) Application?

849048Mar 21 2011
Hello all,

I have spent quite a lot of time searching for a component which is able to render HTML code (i.e. loaded from a file) inside a Java Swing application. Just like an inline browser. I would like to make use of standard CSS stylesheets and HTML 4. I know that JEditorPane does not meet these requirements. There are other components which do basically a good job like Eclipse Browser Plugin (SWT). But the problem with these components is, that they rely on a previously installed browser.

JWebPane is not part of JDK7 as far as I have seen, so this is also no solution for my case.

I'm interested to hear, how other Java professionals solve this problem. What is your way of solving this problem? Do you buy a component such as the one from WebRenderer.com? Or do you implement something own? Or do you use another GUI framework?

For my project, I have some restrictions:
- Must run on Windows, Mac and Linux
- Should not require a preinstalled webbrowser (dependency)
- Should be HTML 4 and CSS compliant


I am very glad to hear from you.

Thank you very much for your help. I really appreciate that.

Best regards,
André Gasser
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 18 2011
Added on Mar 21 2011
0 comments
259 views