Ugly “disabled” images of TMainMenu

后端 未结 2 348
臣服心动
臣服心动 2020-12-24 09:03

Delphi 2010, Win32 VCL. I need to create a main menu for my application with the most standard look. TMainMenu looks nice in all Windows versions, the only bad thing is when

相关标签:
2条回答
  • 2020-12-24 09:19

    If you can provide your images as PNG you can use TPngImageList from PngComponents. It has different options to make a blended or grayscaled disabled image. The PNG format allows you to make use of alphablending.

    0 讨论(0)
  • 2020-12-24 09:36

    There's a great post on Galfar's Lair blog which describes the problem, and has code for a workaround, overriding the TImageList DoDraw method.

    Here's the pic (linked) showing the 'before' and 'after'.

    alt text

    I think this relates to pretty much all Delphi versions.

    0 讨论(0)
提交回复
热议问题