try { int nw = Integer.parseInt(tf.getText()); getSelectedChar().setWidth(nw); line.repaint(); } catch (NumberFormatException e) {}
if (isEnabled()) try { int nw = Integer.parseInt(tf.getText()); getSelectedChar().setWidth(nw); line.repaint(); } catch (NumberFormatException e) {}
        public void setWidthToTF()        {            try            {                int nw = Integer.parseInt(tf.getText());                getSelectedChar().setWidth(nw);                line.repaint();            }            catch (NumberFormatException e)            {}        }