Probably its the best I describe in detail what I try to achive:
I made myself a component to modally display forms embedded into the main window. The background of the main form is captured, gray shaded and the embedded form is displayed in the center. That part is already finished and works fine.
The component also should have a functionality like 'ShowMessage', i.e. the message text is centered in the main form. Attached a screenshot how it looks under Windows, as said, there it works with rvk's solution.
So what I need is to know the actual height of the text in the Memo so that I can do the size adjustment and centering.
If I have the (actual) number of lines instead of the height, I can easily calculate the height. But it also has to work when the Memo is not fully extended, but in a scrolling mode because of the limited area.
As you can see, the Memo is in ReadOnly configuration, the user still can mark and copy the text.
Regards~