/*
 * SwingTextArea.fx
 */

package cookery.control;

/**
 * @author Nick Apperley
 */

import javafx.ext.swing.SwingComponent;
import javax.swing.JTextArea;

import java.awt.Dimension;

/**
 * Wrapper for the Swing Text Area control.
 <p>Do ignore since it is non operational (does not work).</p>
 * @author Nick Apperley
*/
public class SwingTextArea extends SwingComponent{
    override var visible = true on replace newValue{
        component.setVisible(newValue);
    };
    public var dimensions: Integer[] = [50, 20] on replace newValue{
        component.setPreferredSize(new Dimension(newValue[0], newValue[1]));
    };
    def component = new JTextArea();

    override function createJComponent(){
        return component;
    }
}
