//# 0 errors, 20 messages
//#
/*
    //#TextPaneUI.java:1:1: class: com.dmdirc.addons.ui_swing.textpane.TextPaneUI
    //#TextPaneUI.java:1:1: method: com.dmdirc.addons.ui_swing.textpane.TextPaneUI.com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init
 * Copyright (c) 2006-2009 Chris Smith, Shane Mc Cormack, Gregory Holmes
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */

package com.dmdirc.addons.ui_swing.textpane;

import java.awt.Graphics2D;

import javax.swing.BorderFactory;
import javax.swing.JComponent;
import javax.swing.UIManager;
import javax.swing.border.Border;
import javax.swing.plaf.ComponentUI;

/**
 * TextPane UI
 */
public class TextPaneUI extends ComponentUI {
    //#TextPaneUI.java:36: method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.com.dmdirc.addons.ui_swing.textpane.TextPaneUI()
    //#input(void com.dmdirc.addons.ui_swing.textpane.TextPaneUI()): this
    //#TextPaneUI.java:36: end of method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.com.dmdirc.addons.ui_swing.textpane.TextPaneUI()

    /** {@inheritDoc} */
    @Override
    public void installUI(final JComponent c) {
        Border border = UIManager.getBorder("TextField.border");
    //#TextPaneUI.java:41: method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.installUI(JComponent)
    //#input(void installUI(JComponent)): c
    //#pre[1] (void installUI(JComponent)): c != null
    //#test_vector(void installUI(JComponent)): javax.swing.UIManager:getBorder(...)@41: Inverse{null}, Addr_Set{null}
        if (border == null) {
            border = BorderFactory.createEtchedBorder();
        }
        c.setBorder(border);
    }
    //#TextPaneUI.java:46: end of method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.installUI(JComponent)

    /** {@inheritDoc} */
    /*@Override
    public void paint(final Graphics g, final JComponent c) {
        if (c.isOpaque()) {
            g.setColor(c.getBackground());
            g.fillRect(0, 0, c.getWidth(), c.getHeight());
        }
        paint(g, c);
    }*/

    /** {@inheritDoc} */
    /*@Override
    public void update(final Graphics g, final JComponent c) {
        if (c.isOpaque()) {
            g.setColor(c.getBackground());
            g.fillRect(0, 0, c.getWidth(), c.getHeight());
        }
        paint(g, c);
    }*/

    protected void paintTextPane(final Graphics2D g, final TextPane c) {
    }
    //#TextPaneUI.java:69: method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.paintTextPane(Graphics2D, TextPane)
    //#TextPaneUI.java:69: end of method: void com.dmdirc.addons.ui_swing.textpane.TextPaneUI.paintTextPane(Graphics2D, TextPane)
}    //#output(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Descendant_Table[com/dmdirc/addons/ui_swing/textpane/TextPaneUI]
    //#output(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Dispatch_Table.installUI(Ljavax/swing/JComponent;)V
    //#output(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Dispatch_Table.paintTextPane(Ljava/awt/Graphics2D;Lcom/dmdirc/addons/ui_swing/textpane/TextPane;)V
    //#post(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Descendant_Table[com/dmdirc/addons/ui_swing/textpane/TextPaneUI] == &__Dispatch_Table
    //#post(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Dispatch_Table.installUI(Ljavax/swing/JComponent;)V == &installUI
    //#post(com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init): __Dispatch_Table.paintTextPane(Ljava/awt/Graphics2D;Lcom/dmdirc/addons/ui_swing/textpane/TextPane;)V == &paintTextPane
    //#TextPaneUI.java:: end of method: com.dmdirc.addons.ui_swing.textpane.TextPaneUI.com.dmdirc.addons.ui_swing.textpane.TextPaneUI__static_init
    //#TextPaneUI.java:: end of class: com.dmdirc.addons.ui_swing.textpane.TextPaneUI
