Example usage for com.vaadin.ui.themes ValoTheme TEXTAREA_BORDERLESS

List of usage examples for com.vaadin.ui.themes ValoTheme TEXTAREA_BORDERLESS

Introduction

In this page you can find the example usage for com.vaadin.ui.themes ValoTheme TEXTAREA_BORDERLESS.

Prototype

String TEXTAREA_BORDERLESS

To view the source code for com.vaadin.ui.themes ValoTheme TEXTAREA_BORDERLESS.

Click Source Link

Document

Removes the border and background from the text area.

Usage

From source file:org.eclipse.hawkbit.ui.management.actionhistory.ActionHistoryTable.java

License:Open Source License

/**
 * create Message block for Actions.//www.ja v  a2  s  .  com
 *
 * @param messages
 *            as List of msg
 * @return Component as UI
 */
protected Component createMessagesBlock(final List<String> messages) {

    final TextArea textArea = new TextArea();
    textArea.addStyleName(ValoTheme.TEXTAREA_BORDERLESS);
    textArea.addStyleName(ValoTheme.TEXTAREA_TINY);
    textArea.addStyleName("inline-icon");
    textArea.setSizeFull();
    int index = 1;
    final StringBuilder updateStatusMessages = new StringBuilder();
    if (messages != null && !messages.isEmpty()) {
        /* Messages are available */
        for (final String msg : messages) {
            updateStatusMessages.append('[').append(index).append("]: ").append(msg).append('\n');
            index++;
        }
    } else {
        /* Messages are not available */
        updateStatusMessages.append(i18n.get("message.no.available"));
    }
    textArea.setValue(updateStatusMessages.toString());
    textArea.setReadOnly(Boolean.TRUE);
    return textArea;
}