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

Icon in RadPane header for office2013 (black and white changes)

2 Answers 28 Views
Docking
This is a migrated thread and some comments may be shown as answers.
B
Top achievements
Rank 2
B asked on 26 Mar 2015, 09:57 AM
Hi,

I followed the instructions here:

http://docs.telerik.com/devtools/wpf/controls/raddocking/how-to/add-icon-pane-header

I do see the icon in the header, but for the Office2013 template I want to change the icon to white when the pane is selected, because black on dark blue doesn't look nice (see screenshot)

Is there a way to do that? Is there a "SelectedHeaderTemplate" that I could use to specifiy a white icon?

Regards,

Bayram

2 Answers, 1 is accepted

Sort by
0
B
Top achievements
Rank 2
answered on 26 Mar 2015, 01:18 PM
I found a way to do it, by binding the image to the IsSelected of the RadPane:

<conv:BoolToImageConverter x:Key="CockpitBoolToImageConverter"
                           FalseImage="/PowerBrowser;component/Modules/Images/OutlookBar/Cockpit.png"
                           TrueImage="/PowerBrowser;component/Modules/Images/OutlookBar/White/Cockpit.png"/>
 
 
<DataTemplate x:Key="CockpitPaneHeaderTemplate">
    <Grid>
        <Image Source="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=telerik:RadPane}, Path=IsSelected,
                    Converter={StaticResource CockpitBoolToImageConverter}}"
               Width="16"
               Height="16"
               x:Name="CockpitImage"
               Visibility="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=telerik:DocumentHost},
                    Converter={StaticResource NullToVisibilityConverterInverse}}" />
        <TextBlock Text="{Binding}"
                   Visibility="{Binding ElementName=CockpitImage, Path=Visibility, Converter={StaticResource NotVisibilityConverter}}"/>
    </Grid>
</DataTemplate>
0
Nasko
Telerik team
answered on 30 Mar 2015, 11:39 AM
Hello Demir,

We are glad that you managed to achieve the desired appearance of RadDocking. If you have any additional questions or concerns regarding Telerik controls, please do not hesitate to contact us.

Regards,
Nasko
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
Tags
Docking
Asked by
B
Top achievements
Rank 2
Answers by
B
Top achievements
Rank 2
Nasko
Telerik team
Share this question
or