File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes Swing Web Browser problems Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Swing Web Browser problems" Watch "Swing Web Browser problems" New topic

Swing Web Browser problems

Jack Fletcher

Joined: Oct 09, 2012
Posts: 13
Hi guys,

I'm trying to create a simple web browser using Swing and AWT.
So far I only have the basic structure written and plan to add more but I have encountered a pitfall in that when my code is run I am presented with two windows.
One is sized properly and has no title, the other has the correct title of 'My Web Browser' but is not sized and neither display the components which I have added eg. the JEditorPane to display the html page.

My code is below I would appreciate any points in the right direction!

Campbell Ritchie

Joined: Oct 13, 2005
Posts: 46334
Have you tried a JEditorPane with editable set false? Try here for a tutorial.

I shall move your post to the GUIs forum.
Darryl Burke

Joined: May 03, 2008
Posts: 5115

Jack, please BeForthrightWhenCrossPostingToOtherSites <- link

luck, db
There are no new questions, but there may be new answers.
I agree. Here's the link:
subject: Swing Web Browser problems
It's not a secret anymore!