FMX.Forms.TScreen.Size
Delphi
function Size: TSize;
C++
System::Types::TSize __fastcall Size(void);
Properties
| Type | Visibility | Source | Unit | Parent |
|---|---|---|---|---|
| function | public | FMX.Forms.pas FMX.Forms.hpp |
FMX.Forms | TScreen |
Description
Returns the screen dimensions in logical units.
Size calls the GetScreenSize method from the IFMXScreenService platform service, which returns the screen height and width in logical units (density-independent pixels).
Size returns the screen height and width in compliance with the screen orientation. That is, if the orientation is vertical (for example Portrait), then Height >= Width. If the orientation is horizontal (for example Landscape), then Height < Width.
If Size cannot retrieve the screen dimensions, it returns Height = 0 and Width = 0.