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

RadDockingPane Header Backgroung Color

3 Answers 92 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Raghu
Top achievements
Rank 1
Raghu asked on 06 Jun 2011, 11:28 AM
I want to change RadDocumentPane Header Tab Background Color,Is there any Property as Background Property is not Working for me.

3 Answers, 1 is accepted

Sort by
0
Dani
Telerik team
answered on 08 Jun 2011, 12:22 PM
Hello Raghu,

To change the background of the DocumentHost tab you need to generate the RadDocumentPane template from Expression Blend. This will make all brushes related to the button chrome of the tab available. You can use the attached sample as a reference, just open the Resources tab on the right in Blend to spot the brushes that correspond to the proper state of the ButtonChrome.

Greetings,
Dani
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Raghu
Top achievements
Rank 1
answered on 08 Jun 2011, 01:15 PM
Hi Dani


I want to change the RadDocumentPane Header Background Color Dynamically at runtime.
Please Send the code for solving it dynamically.

Thanks for previous reply

Thanks
Raghu
0
Dani
Telerik team
answered on 09 Jun 2011, 09:41 AM
Hi Raghu,

What you can do is to add another visual element in the PaneDocumentHostTemplate. Then, template bind its Background property. For example:

<ControlTemplate x:Key="PaneDocumentHostTemplate" TargetType="telerik:RadPane">
    <Telerik_Windows_Controls_Chromes:ButtonChrome x:Name="Chrome" ... />
                     <!-- Add one more element: --> 
                     <Border CornerRadius="{StaticResource PaneDocumentHostCornerRadius}"  BorderThickness="1 1 1 0"
                Background="{TemplateBinding Background}" Margin="0 -1 0 0" />
                     <Telerik_Windows_Controls_Primitives:TabItemContentPresenter  .../>
</ControlTemplate>

Then, any Background applied to the DocumentPane will apply to the tab:
<telerik:RadDocumentPane Header="Document 1" Title="Document 1" Background="Yellow" Style="{StaticResource RadDocumentPaneStyle}" />

You can use this fact to dynamically change the Background of the DocumentPane and the change will be reflected in the tab background.

I hope this helps.

Best wishes,
Dani
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Docking
Asked by
Raghu
Top achievements
Rank 1
Answers by
Dani
Telerik team
Raghu
Top achievements
Rank 1
Share this question
or