// Path: swing/src/main/java/org/kobjects/nativehtml/swing/HtmlComponent.java
// public class HtmlComponent extends JComponent implements InternalLinkHandler {
//   private final SwingPlatform platform = new SwingPlatform();
//   private DefaultRequestHandler requestHandler = new DefaultRequestHandler(platform);
//   private HtmlParser htmlProcessor = new HtmlParser(platform, requestHandler, null);
//   
//   
//   public HtmlComponent() {
//     this.setLayout(new BorderLayout());
//     requestHandler.setInternalLinkHandler(this);
//   }
// 
//   public void addInternalLinkPrefix(String s) {
//     requestHandler.addInternalLinkPrefix(s);
//   }
// 
//   public void loadHtml(URI url) {
//     requestHandler.openInternalLink(url);
//   }
// 
//   public void loadHtml(String html, URI baseUrl) {
//     loadHtml(new StringReader(html), baseUrl);
//   }
//   
//   public void loadHtml(Reader reader, URI baseUrl) {
//     Element element = htmlProcessor.parse(reader, baseUrl);
//     
//     removeAll();
//     if (element instanceof AbstractSwingComponentElement) {
//       add((AbstractSwingComponentElement) element, BorderLayout.CENTER);
//       ((AbstractSwingComponentElement) element).invalidate();
//     }
//     revalidate();
//   }
// 
//   
// }


import java.awt.BorderLayout;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.beans.PropertyChangeListener;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.net.MalformedURLException;
import java.net.URI;
import java.net.URISyntaxException;
import javax.swing.AbstractAction;
import javax.swing.Action;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import org.kobjects.nativehtml.swing.HtmlComponent;
package org.kobjects.nativehtml.demo.swing;




public class SwingDemo {

	
    public static void main(String[] args) throws IOException, URISyntaxException {
// Path: swing/src/main/java/org/kobjects/nativehtml/swing/HtmlComponent.java
// public class HtmlComponent extends JComponent implements InternalLinkHandler {
//   private final SwingPlatform platform = new SwingPlatform();
//   private DefaultRequestHandler requestHandler = new DefaultRequestHandler(platform);
//   private HtmlParser htmlProcessor = new HtmlParser(platform, requestHandler, null);
//   
//   
//   public HtmlComponent() {
//     this.setLayout(new BorderLayout());
//     requestHandler.setInternalLinkHandler(this);
//   }
// 
//   public void addInternalLinkPrefix(String s) {
//     requestHandler.addInternalLinkPrefix(s);
//   }
// 
//   public void loadHtml(URI url) {
//     requestHandler.openInternalLink(url);
//   }
// 
//   public void loadHtml(String html, URI baseUrl) {
//     loadHtml(new StringReader(html), baseUrl);
//   }
//   
//   public void loadHtml(Reader reader, URI baseUrl) {
//     Element element = htmlProcessor.parse(reader, baseUrl);
//     
//     removeAll();
//     if (element instanceof AbstractSwingComponentElement) {
//       add((AbstractSwingComponentElement) element, BorderLayout.CENTER);
//       ((AbstractSwingComponentElement) element).invalidate();
//     }
//     revalidate();
//   }
// 
//   
// }


// Path: demo-swing/src/main/java/org/kobjects/nativehtml/demo/swing/SwingDemo.java
import java.awt.BorderLayout;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.beans.PropertyChangeListener;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.net.MalformedURLException;
import java.net.URI;
import java.net.URISyntaxException;
import javax.swing.AbstractAction;
import javax.swing.Action;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import org.kobjects.nativehtml.swing.HtmlComponent;

package org.kobjects.nativehtml.demo.swing;




public class SwingDemo {

	
    public static void main(String[] args) throws IOException, URISyntaxException {
    	final HtmlComponent htmlComponent = new HtmlComponent();