In fact, SM_CXSCREEN
and SM_CYSCREEN
should probably not be used at all. It just indicates the dimensions of the main monitor. These days, multiple monitors are not very useful. In VCL code, you should use Screen.Monitors[]
and its related properties to get information about your monitors.
As for FMX, there is no support for multiple monitors and there is no platform-independent way to find out screen size indicators. In your shoes, I would just use Screen.Monitors[]
and deal with the FMX port when you get to it. In any case, you will have to rewrite your entire GUI code when you send FMX, and this problem is the least of your problems.
Finally when you say
I want to put placeholders in my code when I port it to XE2
I hope you know that porting to FMX is optional. VCL is still supported and available in XE2, and I do not see it uninstalling for a long time. You can connect to XE2 without having anything to do with FMX.
source share