Trim code
[taxeditor.git] / eu.etaxonomy.taxeditor.store / src / main / java / eu / etaxonomy / taxeditor / ui / element / TextWithLabelElement.java
index 57092b726c31a456325d0903f934d431694e981e..efe1877a287fd27098b4bd04e4941c6109c7f69e 100644 (file)
@@ -20,10 +20,6 @@ import eu.etaxonomy.cdm.common.CdmUtils;
 import eu.etaxonomy.taxeditor.preference.Resources;
 
 /**
- * <p>
- * TextWithLabelElement class.
- * </p>
- *
  * @author n.hoffmann
  * @version $Id: $
  */
@@ -35,9 +31,7 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
 
     private final boolean isMultiLine;
 
-    /** Constant <code>MAX_HEIGHT=0</code> */
     public static final int MAX_HEIGHT = 0;
-    /** Constant <code>SINGLE=-1</code> */
     public static final int SINGLE = -1;
 
     protected TextWithLabelElement(CdmFormFactory formFactory, ICdmFormElement parentElement, boolean isMultiLine) {
@@ -60,28 +54,6 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         this(formFactory, parentElement, labelString, initialText, textHeight, textLimit, false, style);
     }
 
-    /**
-     * <p>
-     * Constructor for TextWithLabelElement.
-     * </p>
-     *
-     * @param formFactory
-     *            a {@link eu.etaxonomy.taxeditor.ui.element.CdmFormFactory}
-     *            object.
-     * @param parentElement
-     *            a {@link eu.etaxonomy.taxeditor.ui.element.ICdmFormElement}
-     *            object.
-     * @param labelString
-     *            a {@link java.lang.String} object.
-     * @param initialText
-     *            a {@link java.lang.String} object.
-     * @param textHeight
-     *            a {@link java.lang.Integer} object.
-     *            @param textLimit max characters allowed to enter
-     * @param style
-     *            a int.
-     * @wbp.parser.entryPoint
-     */
     protected TextWithLabelElement(CdmFormFactory formFactory, ICdmFormElement parentElement, String labelString,
             String initialText, Integer textHeight, Integer textLimit, boolean isMultiLine, int style) {
         super(formFactory, parentElement);
@@ -91,16 +63,6 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         init(formFactory, labelString, initialText, textHeight, textLimit, isMultiLine, style, getLayoutComposite());
     }
 
-    /**
-     * @param formFactory
-     * @param labelString
-     * @param initialText
-     * @param textHeight
-     * @param textLimit
-     * @param isMultiLine
-     * @param style
-     * @param layoutComposite
-     */
     protected void init(CdmFormFactory formFactory, String labelString, String initialText, Integer textHeight,
             Integer textLimit, boolean isMultiLine, int style, Composite layoutComposite) {
         if (labelString != null) {
@@ -154,7 +116,6 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         }
         else{
             layoutData = LayoutConstants.FILL();
-            layoutData.grabHorizontal = true;
         }
         if (textHeight != null && textHeight > 0) {
             (layoutData).heightHint = textHeight;
@@ -196,13 +157,6 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         }
     }
 
-    /*
-     * (non-Javadoc)
-     *
-     * @see
-     * org.eclipse.swt.events.ModifyListener#modifyText(org.eclipse.swt.events
-     * .ModifyEvent)
-     */
     /** {@inheritDoc} */
     @Override
     public void modifyText(ModifyEvent e) {
@@ -233,9 +187,6 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         text.setForeground(getColor(symbolicName));
     }
 
-    /* (non-Javadoc)
-     * @see eu.etaxonomy.taxeditor.ui.element.IEnableableFormElement#isEnabled()
-     */
     @Override
     public boolean isEnabled() {
         return text.isEnabled();
@@ -263,36 +214,16 @@ public class TextWithLabelElement extends AbstractCdmFormElement implements Modi
         setBackground(selected ? SELECTED : getPersistentBackground());
     }
 
-    /*
-     * (non-Javadoc)
-     *
-     * @see eu.etaxonomy.taxeditor.forms.AbstractCdmFormElement#setFocus()
-     */
     /** {@inheritDoc} */
     @Override
     public void setFocus() {
         text.setFocus();
     }
 
-    /**
-     * <p>
-     * getMainControl
-     * </p>
-     *
-     * @return a {@link org.eclipse.swt.widgets.Control} object.
-     */
     public Control getMainControl() {
         return text;
     }
 
-    /**
-     * <p>
-     * setTextLimit
-     * </p>
-     *
-     * @param limit
-     *            a int.
-     */
     public void setTextLimit(int limit) {
         text.setTextLimit(limit);
     }