openExternal(url); else setPage(url); url = null; setText(externals.get(reference)); scrollToReference(reference);
setContentType("text/html"); setEditable(false); setEditorKit(new ClasspathHTMLEditorKit()); this.addHyperlinkListener(new HyperlinkListener() this.addMouseListener(new MouseAdapter()
public void mouseReleased(MouseEvent e) { if(popup=e.isPopupTrigger()) { doPopup(e.getPoint()); } }
/** * Open an url in this pane. */ public void setPage(URL url) { try { // Hack??? Allow relative file urls to be loaded setDocument(getEditorKit().createDefaultDocument()); super.setPage(url); // history.add(url); } catch(IOException ex) { BrowserPane.this.setText("Could not open page: "+ex); } }
ImageIcon logo = (ImageIcon)icons.getIcon("logo"); BrowserPane bp = new BrowserPane(); bp.setText(infotext); bp.setDefaultOpenMode(true); bp.setBackground(bg); lab.setBackground(bg);
BrowserPane addons = new BrowserPane(); addons.setText("Some of these settings require add-ons <br> available from the " +"<a href=\"http://www.activecomponents.org/download\">" +"Jadex download page</a>."); addons.setCaretPosition(0); addons.setDefaultOpenMode(true); int index = this.getContentPane().getComponentCount(); this.getContentPane().add(addons, new GridBagConstraints(0, index, 1, 1, 1, 1, GridBagConstraints.NORTHEAST,
if(report!=null) details.setExternals(report.getDocuments()); details.setText(report.getErrorHTML()); details.setExternals(null); details.setText(model.getDescription()); details.setExternals(null); details.setText("<pre>"+error+"</pre>"); details.setExternals(null); details.setText("");
/** * Creates a tool panel with tabs for each tool tab. * * @param tools The tools to be presented in a tabbed pane. */ public ToolPanel(ToolTab[] tools) { this.details = new BrowserPane(); this.tabs = new JTabbedPane(); this.tools = tools; for(int i = 0; i < tools.length; i++) { this.tabs.addTab(tools[i].getName(), tools[i].getIcon(), tools[i]); } // add the change listener to the tab tabs.addChangeListener(new PaneChangeListener()); this.content = new JSplitPane(JSplitPane.VERTICAL_SPLIT, tabs, new JScrollPane(details)); content.setOneTouchExpandable(true); content.setResizeWeight(1.0); content.setDividerLocation(65535); // Proportional (1.0) doesn't work. this.setLayout(new BorderLayout()); this.add(BorderLayout.CENTER, content); }
/** * Open an url in external browser. */ protected void openExternal(URL url) { try { BrowserLauncher2.openURL(url.toString()); } catch(IOException e) { BrowserPane.this.setText("Could not start browser: "+e); } }
if(report!=null) details.setExternals(report.getDocuments()); details.setText(report.getErrorHTML()); details.setExternals(null); details.setText(model.getDescription()); details.setExternals(null); details.setText("<pre>"+error+"</pre>"); details.setExternals(null); details.setText("");
details = new BrowserPane();
/** * Show element details. */ public void showElementDetails(Map element) { // Todo: better layout this.details.setText(element.toString()); // Hack? to show detail panel. if(content.getDividerLocation() > content.getMaximumDividerLocation()) content.setDividerLocation(content.getLastDividerLocation()); }
this.details = new BrowserPane(); details.setMinimumSize(new Dimension(400,100)); details.setPreferredSize(new Dimension(400,100));
public void mousePressed(MouseEvent e) { if(popup=e.isPopupTrigger()) { doPopup(e.getPoint()); } }
this.details = new BrowserPane(); details.setMinimumSize(new Dimension(400,100)); details.setPreferredSize(new Dimension(400,100));