All Downloads are FREE. Search and download functionalities are using the official Maven repository.

test.DefaultCellEditor2 Maven / Gradle / Ivy

Go to download

A Mavenisation of the Quaqua Mac OSX Swing Look and Feel (Java library) Quaqua Look and Feel (C) 2003-2010, Werner Randelshofer. Mavenisation by Matt Gumbley, DevZendo.org - for problems with Mavenisation, see Matt; for issues with Quaqua, see the Quaqua home page. For full license details, see http://randelshofer.ch/quaqua/license.html

The newest version!
/*
 * @(#)DefaultCellEditor2.java  1.0  20 March 2005
 *
 * Copyright (c) 2004 Werner Randelshofer, Immensee, Switzerland.
 * All rights reserved.
 *
 * You may not use, copy or modify this file, except in compliance with the
 * license agreement you entered into with Werner Randelshofer.
 * For details see accompanying license terms.
 */

package test;

import java.awt.*;
import javax.swing.*;
import javax.swing.border.*;

/**
 * Please use  this default cell editor instead of
 * javax.swing.DefaultCellEditor.
 * 

* This default cell editor properly honours the font settings of the table * which contains the cell editor, and it also properly renders a border * around the field which is currently being edit. * * @author Werner Randelshofer * @version 1.0 20 March 2005 Created. */ public class DefaultCellEditor2 extends DefaultCellEditor { /** * Constructs a DefaultCellEditor that uses a text field. * * @param textField a JTextField object */ public DefaultCellEditor2(JTextField textField) { super(textField); textField.setBorder(new LineBorder(Color.black)); } /** * Constructs a DefaultCellEditor object that uses a check box. * * @param checkBox a JCheckBox object */ public DefaultCellEditor2(JCheckBox checkBox) { super(checkBox); checkBox.setBorder(new LineBorder(Color.black)); } /** * Constructs a DefaultCellEditor object that uses a * combo box. * * @param comboBox a JComboBox object */ public DefaultCellEditor2(JComboBox comboBox) { super(comboBox); comboBox.setBorder(new LineBorder(Color.black)); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy