/** * Returns an instance of Renderer which may be used as a table/tree/list cell renderer. * This method must be called on the AWT event thread. If you <strong>know</strong> you will * be passing it legal HTML (legal as documented here), call {@link Renderer#setHtml setHtml(true)} on the * result of this call <strong>after calling getNNNCellRenderer</strong> to provide this hint. * * @return A cell renderer that can render HTML. */ public static final Renderer createRenderer() { return new HtmlRendererImpl(); }
/** * For HTML rendering jobs outside of trees/lists/tables, returns a JLabel which will paint its text using * the lightweight HTML renderer. The result of this call will implement {@link Renderer}. * <strong>Do not add the result of this call to the AWT hierarchy</strong>. It is not a general purpose <code>JLabel</code>, and * will not behave correctly. Use the result of this call to paint or to measure text. Example: * <pre> * private final JLabel label = HtmlRenderer.createLabel(); * * public void paint(Graphics g) { * // background/whatever painting code here... * label.setText(someHtmlText); * label.paint(g); * } * </pre> * * * @return a label which can render a subset of HTML very quickly */ public static final JLabel createLabel() { return new HtmlRendererImpl(); }
/** * Returns an instance of Renderer which may be used as a table/tree/list cell renderer. * This method must be called on the AWT event thread. If you <strong>know</strong> you will * be passing it legal HTML (legal as documented here), call <code>setHtml(true)</code> on the * result of this call <strong>after calling getNNNCellRenderer</code> to provide this hint. * * @return A cell renderer that can render HTML. */ public static final Renderer createRenderer () { return new HtmlRendererImpl(); }
/** * Returns an instance of Renderer which may be used as a table/tree/list cell renderer. * This method must be called on the AWT event thread. If you <strong>know</strong> you will * be passing it legal HTML (legal as documented here), call <code>setHtml(true)</code> on the * result of this call <strong>after calling getNNNCellRenderer</code> to provide this hint. * * @return A cell renderer that can render HTML. */ public static final Renderer createRenderer () { return new HtmlRendererImpl(); }
/** * For HTML rendering jobs outside of trees/lists/tables, returns a JLabel which will paint its text using * the lightweight HTML renderer. The result of this call will implement the <code>Renderer</code> interface. * <strong>Do not add the result of this call to the AWT hierarchy. It is not a general purpose JLabel, and * will not behave correctly. Use the result of this call to paint or to measure text. Example: * <pre> * private final JLabel label = HtmlRenderer.createLabel(); * * public void paint (Graphics g) { * //background/whatever painting code here... * label.setText (someHtmlText); * label.paint (g); * } * </pre> * * * @return A JLabel which can render a subset of html very quickly * if the text should be rendered as plain text even <i>if</i> it contains * HTML markup. */ public static final JLabel createLabel () { return new HtmlRendererImpl(); }
/** * For HTML rendering jobs outside of trees/lists/tables, returns a JLabel which will paint its text using * the lightweight HTML renderer. The result of this call will implement the <code>Renderer</code> interface. * <strong>Do not add the result of this call to the AWT hierarchy. It is not a general purpose JLabel, and * will not behave correctly. Use the result of this call to paint or to measure text. Example: * <pre> * private final JLabel label = HtmlRenderer.createLabel(); * * public void paint (Graphics g) { * //background/whatever painting code here... * label.setText (someHtmlText); * label.paint (g); * } * </pre> * * * @return A JLabel which can render a subset of html very quickly * if the text should be rendered as plain text even <i>if</i> it contains * HTML markup. */ public static final JLabel createLabel () { return new HtmlRendererImpl(); }