FireMonkey Native Windows Controls
Go Up to FireMonkey Native Controls
This topic describes the native Windows controls of FireMonkey.
- 1 FireMonkey Native Windows Control Presentation
- 2 Available FireMonkey Native Windows Controls
- 3 Visual Changes to Native Windows Controls
- 4 Adding Native Windows Controls to Your Application
- 5 Combining Native Windows Controls With Non-native Controls
- 6 Advantages of the Native Windows Controls
- 7 Limitations of Native Windows Controls
- 8 See Also
FireMonkey Native Windows Control Presentation
FireMonkey provides native presentation for certain visual components.
- Set the ControlType property to
Styledin order to have the standard FireMonkey presentation of the control.
Styledis the default value of ControlType.
- Set the ControlType property to
Platformto have the native styling of that control.
Available FireMonkey Native Windows Controls
The following list contains all the controls that support native presentation:
Visual Changes to Native Windows Controls
When the ControlType property of a visual component is set to
Platform, the presentation of this control in the Form Designer changes to indicate that it is a native control and an small phone-like icon appears in the bottom right corner.
The following images demonstrate the look of native Windows controls at with the ControlType property set to
Platform, at design time and at run time:
|Control||Design time||Run time|
Adding Native Windows Controls to Your Application
To add native Windows controls to your application:
- Drop a component that supports native presentation on the form (list of supported controls).
- In the Object Inspector Properties, set the ControlType property to
Platform. The presentation of the component at design-time changes (see Visual Changes to Native Windows Controls).
- Run your application.
Edit1.ControlType := TPresentedControl.TControlType.Platform;
Edit1->ControlType = TPresentedControl::TControlType::Platform;
Combining Native Windows Controls With Non-native Controls
We do not recommend that you combine non-native controls with native controls, because the native controls do not support the Z-order of the form: a native control is always on top of other controls on your form. However, there are some non-native controls that you may combine with native controls because they support the Z-order of native controls.
The following list contains all the controls that have the ControlType property and therefore may be combined with native controls:
The following list contains all the controls that do not have the ControlType property but may also be combined with native controls:
Advantages of the Native Windows Controls
Some controls support additional functionality when you use them as native controls:
TMemo and TEdit
- Additional context-menu items:
- Undo: Undo the last action.
- Right to left Reading order: Changes the reading order and justifies text on the right side of the control. See Microsoft Documentation - To set right-to-left reading order for more information.
- Show Unicode control characters: Shows Unicode control characters.
- Insert a Unicode control character: Inserts a Unicode control character.
- Open IME: IME stands for
Microsoft Global Input Method Editor. It enables the typing of Japanese, Chinese and Korean into supporting applications on other versions of Windows.
The features above are provided in the context menu of the control, therefore the context menu of the memo control or the edit control is different for
|Control||Context menu (
||Context menu (|
Limitations of Native Windows Controls
Before using the native controls, consider the following limitations:
- Native controls do not support predefined or custom styles. When the ControlType property of a native control is set to
Platform, the value of the StyleLookup property is ignored.
- Native controls have limited support for transparent background. Transparent controls are not painted correctly.
- Native controls do not support the Z-order of the form: a native control is always on top of other FireMonkey controls available on your form. See Combining Native Windows Controls With Non-native Controls for details.
- The following event handlers are not supported and cannot be implemented:
- The following events occur but you cannot use them as intended (to override the visualization of the control). However, you may use them as an indication of when the system repaints the control:
There are also some control-specific limitations:
The following event is not supported and cannot be implemented in TMemo:
TMemo and TEdit
Setting parameter values in the
OnKeyXX event handler does not suppress the key input.
For example, if you set
KeyChar := #0; in the OnKeyDown event handler and press the
s key, the native presentation still outputs the
s, while the styled presentation does not output anything.
The above limitation applies to these event handlers:
- FireMonkey Native Controls
- FireMonkey Native iOS Controls
- FireMonkey Native Android Controls
- Customizing FireMonkey ListView Appearance
- FireMonkey Native Controls sample