Delphi 2007 VCL Designer Theme Support

In the Delphi 2007 IDE, we enabled Windows theming which serves to upgrade the appearance of the entire IDE leaving behind the more classic Windows style. In fact, all new VCL applications in Delphi 2007 have themes enabled by using the new “Enabled runtime themes” checkbox on the Applications page of the Project Options dialog. This means you no longer have to add either the XPMan unit to your uses clause nor drop a TXPManifest component to theme a VCL applications.

Unfortunately, theming your application isn’t always a trivial task because not all 3rd party or custom controls behave properly when themed not to mention it can potentially really slow your application down if it wasn’t written with themes in mind. We recognize this and have built the Delphi 2007 VCL designer so that it will properly displays your controls depending whether “Enable runtime themes” is checked for your project.

For example, here is a screenshot with a “Enabled runtime themes” checked:

And the same application with themes disabled:

In addition, we’ve made numerous improvements to VCL to help reduce flicker and improve performance particularly when DoubleBuffered is enabled. Since this release is interface compatible with BDS 2006 there are additional changes which have to that will have to wait for the next major release.

[UPDATE: March 19, 2007] The IDE caption says “Highlander” because this is my developer build which includes all personalities and HL related bits.

7 thoughts on “Delphi 2007 VCL Designer Theme Support

  1. How do you enable doublebuffered? Is it a setting in the options dialog or something you have to add to your code?

  2. Tony,
    DoubleBuffered is a property on TWinControl that’s not (currently) published. I’ve written a few other posts that mention it which you can find by searching for "DoubleBuffered" from the search box on the top right corner of my blog.

  3. How does ‘Enable runtime themes’ differ from using the TXPManifest component?
    Does this strictly deal with controls, or does it impact how windows themselves are rendered?
    Right now I use (almost exclusively) DevExpress controls with theme support turned on. I’m wondering what impact ‘Enable runtime themes’ will have (if any) on my applications?

  4. Bruce,
    I’m working on a post which provides some more explanation but basically it’s no different from using TXPManifest or including XPMan in your application though we’re likely to deprecate both the component and that unit in the future.

  5. What is it about "enable runtime themes" that would make external (3rd party) apps that used to be able to run my app no longer able to do so? In other words, several other vendors use my apps as "built-in" for their apps simply by using a shell command to run my app. When I compile with the new "enable runtime themes" my app seems to ignore that request. Same app runs fine if I uncheck the "enable runtime themes" box when compiling.
    I also noticed that when I use ShellExecute to run one of my apps from another of mine, I have to set the Handle parameter to 0 (rather than a variable) for the run to work when I compile the target app with "enable runtime themes".
    Any way to get around this without requiring all of my external customers to somehow recode to continue to use our products in theirs?
    Thanks.
    Scott
    Postage $aver Software
    savepostage.com

  6. Scott,
    The option changes a resource embedded in the application which indicates to the Windows loader which controls to use. For support on the issues you’re seeing please either contact CodeGear or post to the public newsgroups.

Comments are closed.