Revision 23162 trunk/extensions/extTopology/src/org/gvsig/topology/ui/util/HTMLPanel.java
HTMLPanel.java | ||
---|---|---|
55 | 55 |
import javax.swing.JScrollPane; |
56 | 56 |
import javax.swing.text.html.HTMLEditorKit; |
57 | 57 |
|
58 |
import com.iver.andami.PluginServices; |
|
58 | 59 |
import com.iver.andami.ui.mdiManager.IWindow; |
59 | 60 |
import com.iver.andami.ui.mdiManager.WindowInfo; |
60 | 61 |
|
61 | 62 |
public class HTMLPanel extends JPanel implements IWindow{ |
62 | 63 |
private static final long serialVersionUID = 1490785370826172129L; |
64 |
|
|
63 | 65 |
private JScrollPane scrollPanel; |
64 | 66 |
private JEditorPane htmlPanel; |
65 | 67 |
private StringBuffer htmlText = new StringBuffer(); |
66 | 68 |
private WindowInfo viewInfo; |
67 | 69 |
|
70 |
private String title; |
|
68 | 71 |
|
69 |
public HTMLPanel(String htmlBody) { |
|
72 |
public HTMLPanel(String title, String htmlBody) {
|
|
70 | 73 |
super(); |
74 |
this.title = title; |
|
75 |
|
|
71 | 76 |
setLayout(new BorderLayout()); |
72 | 77 |
scrollPanel = new JScrollPane(); |
73 | 78 |
htmlPanel = new JEditorPane(); |
74 | 79 |
htmlPanel.setEditable(false); |
75 | 80 |
htmlPanel.setEditorKit(new HTMLEditorKit()); |
76 | 81 |
|
82 |
|
|
77 | 83 |
initialize(htmlBody); |
78 | 84 |
|
79 | 85 |
scrollPanel.setViewportView(htmlPanel); |
... | ... | |
103 | 109 |
WindowInfo.MAXIMIZABLE | |
104 | 110 |
WindowInfo.ICONIFIABLE | |
105 | 111 |
WindowInfo.PALETTE); |
106 |
viewInfo.setTitle("Informe de la ruta calculada");//Internacionalizar esto
|
|
107 |
viewInfo.setWidth(400);
|
|
108 |
viewInfo.setHeight(350);
|
|
112 |
viewInfo.setTitle(title);
|
|
113 |
viewInfo.setWidth(200);
|
|
114 |
viewInfo.setHeight(250);
|
|
109 | 115 |
} |
110 | 116 |
return viewInfo; |
111 | 117 |
} |
Also available in: Unified diff