Example usage for com.vaadin.ui RichTextArea setValue

List of usage examples for com.vaadin.ui RichTextArea setValue

Introduction

In this page you can find the example usage for com.vaadin.ui RichTextArea setValue.

Prototype

@Override
public void setValue(String value) 

Source Link

Document

Sets the value of this object.

Usage

From source file:org.hip.vif.web.util.VIFViewHelper.java

License:Open Source License

/** Helper method to create a text field.
 *
 * @param inContent String the field's content
 * @param inWidth int the field width (in pixels)
 * @param inHeight int the field width (in pixels)
 * @param inValidator {@link Validator} the field's validator or <code>null</code>, if no validation is applied
 * @return {@link RichTextArea} */
public static RichTextArea createTextArea(final String inContent, final int inWidth, final int inHeight,
        final Validator inValidator) {
    final RichTextArea out = new RichTextArea();
    out.setValue(inContent);
    if (inValidator != null) {
        out.addValidator(inValidator);//from   w w  w  . ja va2s.  c  o  m
    }
    out.setWidth(inWidth, Unit.PIXELS);
    out.setHeight(inHeight, Unit.PIXELS);
    out.setStyleName("vif-editor"); //$NON-NLS-1$
    return out;
}