0
votes

I Upgraded from C++ Builder XE7 to C++ Builder Berlin and I have a project with about 100 images in 6 ImageList controls.

In XE7 the transparency worked fine, but after the upgrade all images now have a black solid background instead of transparency.

I double checked that the ImageList's ColorDepth still was cd32bit, and it is. Everything looks file in the IDE, images are transparent, but as soon I run my application, all images have a black background instead of transparency.

Black background

I tried to drop a new TImageList, cd32bit depth and added some transparent PNG:s that worked fine in XE7. Still they show up with a black background in Runtime, but not in the IDE.

1
I have had this problem in the past. When migrating projects, many thing will stop working properly. The only way I was able to fix the issues was to not use the migrate function and instead create a new project with the same name and add all the units to it. Ever since I have made this a policy, not to use the migrate function. Always create a new project in the same directory, add all the units to it and remove the Unit1 that was created automatically. - Sam

1 Answers

0
votes

Finally figured it out!
I noted that all controls had the old Win XP style so I suspected that the wrong version of Comctl32.dll was loaded, the question was only how to change it?

The project is very old and was created before C++ Builder supported manifests. But in the project options, under Application you will find a section named "Manifest File".

Set it to "Auto Generate" and tick the checkbox "Enable Runtime Themes" and it will use the correct version of Comctl32.dll