Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Font size and alv grid problem

shiz0frenik
Participant
0 Kudos

Hi, guys, i've got a screen which i draw at screen painter inside which i display mine alv grid, but when i try to change font size in SAP settings mine screen changes size too, it becoming less if i set font size smaller that i had, and it becomes greater if i set it bigger. Can i set the screen to not change size,deppending on font size ? I used only custom control at screen painter

5 REPLIES 5

raymond_giuseppi
Active Contributor

AFAIK classic dynpro size are defined in number of rows and columns.

If you want to fully manage the size of dynpro use some OO managed container.

e.g. Attach a container for ALV to a side of a custom containber or a default one such as cl_gui_container=>screen0 with a class such as CL_GUI_DOCKING_CONTAINER. There you can handle size in pixel or mm (look for parameter such as METRIC, and constants such as docking_container->metric_pixel in the class methods)

Sandra_Rossi
Active Contributor
0 Kudos

What are you trying to do? Do you want your ALV to use the whole available space in your SAP GUI window?

shiz0frenik
Participant
0 Kudos

sandra.rossi, yes. and to not change size, if i will change font Size in sap setting. I've done it with
CL_GUI_DOCKING_CONTAINER,but is it possible with cl_gui_custom_container or any other classes ?

raymond_giuseppi
Active Contributor
0 Kudos

Did you try it, like CL_GUI_DOCKING_CONTAINER, CL_GUI_CUSTOM_CONTAINER also has some SET_METRIC, SET_WIDTH and SET_HEIGHT methods.

What is the effect when container should be greater than the defined area of the main dynpro?

Sandra_Rossi
Active Contributor
0 Kudos

Here, I'm not talking about font size at all, but you may possibly want to display more information in the screen, use all space available.

With large screens, in Windows, the screen area of SAP GUI in a maximized window of SAP GUI is smaller than the space offered by the window. The system container CL_GUI_CONTAINER=>SCREEN0 (if modal level is 0 = main screen/not a popup) can be used to cover the whole window.

This is just to show that the full screen is covered (this program is missing important call to method FREE to free control inside full screen).

REPORT ztest.

DATA go_textedit TYPE REF TO cl_gui_textedit.
PARAMETERS dummy.

AT SELECTION-SCREEN OUTPUT.
  IF go_textedit IS NOT BOUND.
    CREATE OBJECT go_textedit
      EXPORTING
        parent = cl_gui_container=>screen0.
  ENDIF.