Is there a way to prevent the CL_SALV_TABLE instance from being removed from leading spaces in the display?
I have the following code snippet in which I put one space before the text Master and two spaces before the text Slave .
REPORT zzy. CLASS lcl_main DEFINITION FINAL CREATE PRIVATE. PUBLIC SECTION. CLASS-METHODS: main. ENDCLASS. CLASS lcl_main IMPLEMENTATION. METHOD main. TYPES: BEGIN OF l_tys_test, name TYPE string, value TYPE i, END OF l_tys_test, l_tyt_test TYPE STANDARD TABLE OF l_tys_test WITH EMPTY KEY. DATA(lt_test) = VALUE l_tyt_test( ( name = `Root` value = 0 ) ( name = ` Master` value = 1 ) ( name = ` Slave` value = 2 ) ). cl_salv_table=>factory( IMPORTING r_salv_table = DATA(lo_salv_table) CHANGING t_table = lt_test ). lo_salv_table->display( ). ENDMETHOD. ENDCLASS. START-OF-SELECTION. lcl_main=>main( ).
Unfortunately, leading spaces are clipped in the view.

In this tutorial, the guy seems to have done it somehow.
source share