Widget Header Background Color:
My implementation : I have used infragistic tile control for my widgets. For, widget customizations like iGoogle we have given one customization option Header Background Color. User can select any color from given list & when he/she saved this settings Header color will get changed on widget. This color is getting assigned by below css tag in TileGeneric.xaml<igTiles:TileHeaderPresenter.Background> <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0"> <GradientStop Color="#FF8B8989" Offset="0"/> <GradientStop Color="#FF333333" Offset="0.539"/> </LinearGradientBrush></igTiles:TileHeaderPresenter.Background>Issue : How do I change this color at runtime? If I give any color of my colorlist in above css tag then that is being applied on all widgets. But I want Header color based on user selection for particular to that widget & user's selection. And that is why I need to change header color at runtime.
Right Now, we are using label for header caption. So,I have implemented this with changing that label's background color. But that is not proper I know. The exact approach should be changing that css tag's color at runtime. Please guide me how to do that?
Hello,
I am just checking the progress of this issue and was wondering if you managed to achieve your goal or if you need any further assistance on the matter.
If the above suggestion helped you solve your issue please verify the thread as answered so other users may take better advantage of it.
Hi Peter,
Really sorry for getting to you so lately... Actually I have custom object WidgetTile which is derived from Tile.
This WidgetTile has public property WidgetData which has BackgroundColor property. So, I tried your suggestion with below code in TileGeneric.xaml
<Style TargetType="{x:Type igTiles:TileHeaderPresenter}">
<Setter Property="Background" Value="{Binding Path=WidgetTile.WidgetData.BackgroundColorProperty, RelativeSource={RelativeSource Mode=Self}}" />
</Style>
But it doesn't work for me. My code for setting tile's label's background color getting executed. But minimize, maximize & close button's background remains always "Black".
Would you guide me why is it so?
Thanks a lot,
Darshini Patel