[ABAP] TextEdit Control (cl_gui_textedit) in einem cl_gui_docking_container verwenden, variable Zeilenlänge

DATA: o_dock TYPE REF TO cl_gui_docking_container.
DATA: o_edit TYPE REF TO cl_gui_textedit.

PARAMETERS: p_text TYPE string.

START-OF-SELECTION.

* Container-Objekt erzeugen
  o_dock = NEW #( no_autodef_progid_dynnr = abap_true
                  side = cl_gui_docking_container=>dock_at_bottom
                  ratio = 50 ).

* Editorobjekt erzeugen, Zeilenumbruch am rechten Fensterrand
  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 ).
  
* Text setzen
  o_edit->set_textstream( p_text ).

  WRITE space.