This is a migrated thread and some comments may be shown as answers.

tile Image opacity

2 Answers 141 Views
Panorama
This is a migrated thread and some comments may be shown as answers.
Czeshirecat
Top achievements
Rank 2
Iron
Iron
Czeshirecat asked on 15 Sep 2016, 11:33 AM

Hi.

The two halves of the screen shot are the same tile in different states.

The first, in "No" state,  has a background image that is an opaque bitmap.

The second, in "Yes" state, shows the same tile, same background image, but its foreground Image is set to an opaque plain black bitmap painted with a solid white circle containing a green tick. This is to give a gray blind effect.

The bottom part of the tile is made up of several docked lightvisualelements to create a slider button.

I notice that the gray blind seems to be painted opaquely over the other elements, which I was pleased about as I actually wanted this effect. Is tile.Image always painted opaque? But I noticed that the bottom section of the tile isn't obscured or affected by by the blind, which again is what I want, but is this because of the presence of all the docking and visual elements?.

The problem is that I wanted the white, ticked circle to appear solid. Is this not possible by painting the circle as part of the image? Or do I need to add it as yet another docked visual tile element and set that one's image to the circle?

2 Answers, 1 is accepted

Sort by
0
Czeshirecat
Top achievements
Rank 2
Iron
Iron
answered on 15 Sep 2016, 11:37 AM
Argh. Sorry.  I don't seem to be able to edit my post. Please insert Translucent into everywhere I've put Opaque. The function I used is called SetOpacity so I used that word instead of translucent everywhere. I'm so dumb.
0
Hristo
Telerik team
answered on 19 Sep 2016, 02:49 PM
Hi , 

Thank you for writing.

The ImageOpacity property of RadTileElement is responsible for setting a transparency to the image used as a background, so you can try increasing its value. If I understand correctly the circle is part of the entire image and it should be affected by increasing the ImageOpacity property.

As a separate solution, you can create an image having a transparent part and also make the circle solid in its center. Then you can set is as a BackgroundImage of the tile element.

I hope this helps. Should you have further questions please do not hesitate to write back.

Regards,
Hristo Merdjanov
Telerik by Progress
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms. For more information check out this blog post and share your thoughts.
Tags
Panorama
Asked by
Czeshirecat
Top achievements
Rank 2
Iron
Iron
Answers by
Czeshirecat
Top achievements
Rank 2
Iron
Iron
Hristo
Telerik team
Share this question
or