Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 176
  • Last Modified:

32-bit icons

Does anyone know how to get these working? I need them in a toolbar control and a listview control (with View=Details) .. Whenever I try adding them, any areas with alpha show up as pure black. I've tried a manifest file, but that doesn't seem to be working. I prefer no external controls, but if that's the only way, then I guess I have no choice.
0
UrbanPuppet
Asked:
UrbanPuppet
1 Solution
 
gregoryyoungCommented:
0
 
UrbanPuppetAuthor Commented:
That's for buttons, but how about toolbars and listviews? I don't see a paint event for them.
0
 
gregoryyoungCommented:
"When you set the Image property of a Microsoft Windows Form (Winform) control to a 32-bit alpha-blended icon, the icon that is displayed on the control loses the alpha channel. The transparent regions of the icon are rendered as solid. This behavior occurs at design time and at run time for the Winform control. "

only the example is a button .
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Daniellus83Commented:
No paint event? try this:

        ToolBar1.Refresh()
        ListView1.Refresh()
0
 
planoczCommented:
Try changing your transparent properties to Black in your listview control
0
 
UrbanPuppetAuthor Commented:
gregoryyoung, I realize it's an example, but it's an example work-around and I need one for other controls.. It has to be possible to do this..
daniellus83, just tried, those don't help show the alpha.
planocz, that would (if anything) just hide it, I want the alpha to show..

Thanks for even clicking/responding in the first place guys, but I'm still looking for a definite answer
0
 
gregoryyoungCommented:
I believe the workaround is fairly clear, you need to override the entire paint method to call DrawIcon yourself, this sounds a whole lot easier than it is .... I would recommend just grabbing this http://www.binarymission.co.uk/binarylistview.aspx which fixes this and a few other bugs.

0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now