TextArea as GridPro column editor

I use a textarea as custom column editor in GridPro like so:

TextArea textArea = new TextArea();
textArea.setWidth("1000px");
this.addEditColumn(KalkulationPositionDto::getText)
    .custom(textArea, (dto, value) -> {
        dto.setText(value);
        dto.store();
    })
    .setHeader("Text")
    .setKey("text")
    .setAutoWidth(true)
    .setFlexGrow(0)
    .setResizable(true)
    .setSortable(true);

The value to show can be quite long ~1000 characters and need multiple rows (more than the two default rows)
If I double click the column in order to edit, the underlying textarea is not rendered properly as the screenshot shows.

  • the grid itself ist set to setAllRowsVisible(true);this.setSizeFull();
  • all parent components up to the view are set to full size too

How can I properly use a textarea as GridPro column editor for large text amounts ?
image.png

I don’t think this case is really supported and you are better off implementing your own custom logic which opens a overlay and close it after editing the text area ia done

yeah, it might be possible to get it working somewhat decently, but I’ll second knoobie’s recommendation to open a dialog or something for the editing instead.

in general, in-line editing is not a good fit for anything more complex than single-line fields

ok, make sense … thanks!

Inline editing multiline fields becomes even more tricky if you want to allow moving to the next field with enter.