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

Border missing from Expander

5 Answers 103 Views
Expander
This is a migrated thread and some comments may be shown as answers.
Scott Waye
Top achievements
Rank 2
Iron
Veteran
Iron
Scott Waye asked on 24 Mar 2011, 11:32 PM
Hi,

The 2011 Q1 release (and the lastest hotfix) seem to have lost the border on the RadExpander.  I'm using Office Blue, but looking at the demos, none of the themes seem to have a border any more.

How can I get it back?

--
Scott

5 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 30 Mar 2011, 09:48 AM
Hi Scott Waye,

Recently we introduces some changes in the RadExpander ControlTemplate and functionality in order to improve its performance. However, I am not sure to which Border you are referring to. Therefore I wanted to ask you to please send us a snapshot indicating how you need to style the RadExpander and which Border is missing.

Looking forward towards your reply,
Tina Stancheva
the Telerik team
0
Scott Waye
Top achievements
Rank 2
Iron
Veteran
Iron
answered on 30 Mar 2011, 10:05 PM
I can explain by saying what I am trying to do to get my borders back.  I am using the style:

                    <Style TargetType="Controls:RadExpander">
                        <Setter Property="BorderBrush" Value="#FF83A5D2"/>
                        <Setter Property="BorderThickness" Value="1"/>
                    </Style>

Which gets me back a blue border around the control (which it used to have in 2010 Q3).  However there is no property for CornerRadius so it currently looks very square.  If you add that, I will be able to get the expander looking as it did with something like:

                    <Style TargetType="Controls:RadExpander">
                        <Setter Property="BorderBrush" Value="#FF83A5D2"/>
                        <Setter Property="BorderThickness" Value="1"/>
                        <Setter Property="BorderCornerRadius" Value="3"/>
                    </Style>

In 2010 Q3 for the Office blue theme you had in Expander.xaml:

<CornerRadius x:Key="Expander_BorderRadius">3</CornerRadius>

and
            <Border BorderBrush="{TemplateBinding BorderBrush}"
                    BorderThickness="{TemplateBinding BorderThickness}"
                    CornerRadius="{StaticResource Expander_BorderRadius}"

But in 2011 Q1 the border radius resource is not present.

Hope that makes it clear.

--
Scott
0
Tina Stancheva
Telerik team
answered on 05 Apr 2011, 12:49 PM
Hello Scott Waye,

You can edit the default ControlTemplate of the control to set a CornerRadius to the Border hosting the control's elements:
<ControlTemplate x:Key="ExpanderTemplate" TargetType="telerik:RadExpander">
    <Grid HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}">
             ...
        <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}"
                CornerRadius="{StaticResource Expander_BorderRadius}">
                ...
        </Border>
    </Grid>
</ControlTemplate>

Please have a look at it and let us know if it works for you.

Kind regards,
Tina Stancheva
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
Scott Waye
Top achievements
Rank 2
Iron
Veteran
Iron
answered on 05 Apr 2011, 09:27 PM
Yes, I'm sure that will work.  It would be better if you just put it back in the theme though.  Why did you remove it?
0
Tina Stancheva
Telerik team
answered on 07 Apr 2011, 01:35 PM
Hi Scott Waye,

We will add the CornerRadius property back to the ControlTemplate and the theme as soon as possible. You can track the item from here.

I updated your Telerik account accordingly.

Best wishes,
Tina Stancheva
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
Expander
Asked by
Scott Waye
Top achievements
Rank 2
Iron
Veteran
Iron
Answers by
Tina Stancheva
Telerik team
Scott Waye
Top achievements
Rank 2
Iron
Veteran
Iron
Share this question
or