Beauty is a terrible force.
Consider especially the meaning of the word scary.
To connect to an XP themes application, you just need to add a special resource containing a manifest to it, or put a manifest file named <your_application_name> .exe.manifest. As a result, however, the application does not always work correctly and displays as it should. It is for this reason that I always prefer the second use case for the manifest - with an external file. It can always be deleted, including if the user has problems due to the connection of the manifest, you can simply advise in response to his complaint to delete this file - which is much faster than passing him a version of the distribution kit in which the manifest resource is not included in executable module.
It's no secret that by adding an external manifest file, you can try to "improve" the appearance of any 32-bit application, even made and released before the advent of the XP operating system. I wonder how many of you have tried to improve the Delphi shell interface this way. For example, I managed to achieve a positive effect for Delphi 6 by putting the manifest file Delphi32.exe.manifest in its \ bin directory. Version 5, however, could not start after this improvement. But this trick passed with a bang for Delphi 2. At least, the bookmarks of the pages of the edited modules have become more distinguishable, and now you can clearly see which bookmark is active.
In fact, things are not so simple, and in order for the themes to start working correctly, something must be added in the code. At a minimum, you need to call the InitCommonControls API function (which is executed by itself if you already use "general" controls like list view or tree view in the application, but which must be called additionally if there are no such visual objects in the application).
To correctly connect themes to the XP MCK application, it is recommended to use the TKOLMHXP component, the author of which is Dmitry Zharov aka Gandalf. This component will provide both the connection of the manifest (moreover, it is possible to choose the connection method: as a resource or as an external file), and call the required API functions. In addition, with its help, you can correctly fill in the fields of the manifest (which is actually an XML document). Although the values of these fields have no effect on the functioning of the manifest.
The appearance of some controls may differ from what was expected to be seen when connecting the manifest. For example, RichEdit does not want to render using XP themes until you add the conditional compilation symbol GRAPHCTL_XPSTYLES (remember to rebuild - Build - the project). This is done because additional code is required to work correctly with the manifest, and this code is not needed at all if you do not intend to use the manifest (or the appearance of the RichEdit window with a regular frame does not upset you, and saving a few dozen bytes of code is more important ).
Similar problems are found for tabbed pages - TabControl. When creating it, I decided to use a regular panel as a background for each page, and it is in no way affected by the manifest. As a result, the inside of the page looks a little faded compared to the colorful off-page views. To fix this problem, add the conditional compilation symbol NEW_ALIGN (after sufficient testing, and possibly very soon, this version of the code will be standard, while the previous version of the alignment will, on the contrary, become optional).
It should also be noted that when connecting the manifest, there may be problems with the transparency of many types of controls (for which the Transparent = true property). Some of them turn black, some are not displayed correctly. To solve problems with the toolbar, they had to go to unprecedented measures altogether: his MCK mirror had to add the FixFlatXP property, set by default, which controls code generation in such a way as to avoid the appearance of a black bar instead of the toolbar. That not only slightly increases the code, but also prohibits the use of certain combinations of options.