Search code examples
delphifiremonkey

FMX Style lost on old version of Windows


I'm having a doubt about styling applications in FMX.

I developed an application using Delphi 11 on Windows 10, but when I open the app on an older version of Windows, some components lose their style, for example TButton, TEdit, TProgressBar, etc.

Can we fix that? Or, is this a compatibility issue?

ob:occurs in modified components in Style Designer

Windows 7 and 8.1

image

Windows 10

image

Any tips or ideas to solve the problem?


Solution

  • FMX can apply distinct styles to each of your target platforms so it's up to you to ensure that your style is available across all of them (major Windows versions are considered distinct platforms as well).

    You can check your supported platforms by opening your TStyleBook and looking into the "Platform" selector. Chances are you only have Windows 10 Desktop and Default listed. To apply the styles you already have to Windows 7, Windows 8.1 and other platforms:

    • Add platforms by clicking the "Add new platform" button (just right from the selector), choose your target platform and finally copy/paste your styles from Windows 10 Desktop.
    • Move all your styles from the Windows 10 Desktop platform to the Default platform. When no specific style for a platform is defined the Default one is applied.