DATA: o_edit TYPE REF TO cl_gui_textedit.
DATA: o_dock TYPE REF TO cl_gui_docking_container.
START-OF-SELECTION.
WRITE: / 'Zeile 1'.
WRITE: / 'Zeile 2'.
WRITE: / 'Zeile 3'.
* Container-Objekt erzeugen
o_dock = NEW #( no_autodef_progid_dynnr = abap_true
side = cl_gui_docking_container=>dock_at_bottom
ratio = 50 ).
* Editorobjekt erzeugen wordwrap an fester Position
o_edit = NEW #( wordwrap_mode = cl_gui_textedit=>wordwrap_at_windowborder
wordwrap_to_linebreak_mode = cl_gui_textedit=>true
parent = o_dock ).
* feste Zeichenbreite
o_edit->set_font_fixed( mode = cl_gui_textedit=>true ).
AT LINE-SELECTION.
* bei Doppelklick auf Zeile
IF o_edit IS BOUND.
* Inhalt des TextEdit löschen
o_edit->delete_text( ).
* Neuen text einfügen
o_edit->set_textstream( |{ sy-lisel }| ).
ENDIF.