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

Custom template

3 Answers 115 Views
ColorPicker
This is a migrated thread and some comments may be shown as answers.
Anton Khramov
Top achievements
Rank 1
Anton Khramov asked on 01 Jul 2009, 03:32 AM
Hi.
I want to create custom control template for colorpicker. In detail, i need to remove ColorButton and create my own template for expander button.
I've try ColorButtonStyle and ExpanderButtonStyle but it didn't help me.
Please help.

3 Answers, 1 is accepted

Sort by
0
Valentin.Stoychev
Telerik team
answered on 01 Jul 2009, 05:48 AM
Hi Anton Khramov,

Please check this example:
http://demos.telerik.com/silverlight/#ColorPicker/ColorPicker

check this style:
<Style x:Key="ColorButtonStyle" TargetType="Button"> ...

and how it is applied:
<telerik:RadColorPicker ColorButtonStyle="{StaticResource ColorButtonStyle}"  ...

If you still can't figure it out - please let us know.

Sincerely yours,
Valentin.Stoychev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Anton Khramov
Top achievements
Rank 1
answered on 01 Jul 2009, 06:30 AM
Hi, Valentin.

I've try to make empty color button template using following style.
<Style x:Key="ColorButtonStyle" TargetType="Button"
      <Setter Property="Template"
             <Setter.Value> 
                   <ControlTemplate TargetType="Button"
                        <Grid Height="0" Width="0"
                         </Grid> 
                    </ControlTemplate> 
               </Setter.Value> 
        </Setter> 
 </Style> 
 it makes color button empty, but space where button have placed still visible. Can i change style of container in which colorbutton placed.
0
Valentin.Stoychev
Telerik team
answered on 01 Jul 2009, 06:40 AM
Hi Anton Khramov,

If you want to hide the empty color use the "NoColorVisibility" property. Check - out this example:
http://demos.telerik.com/silverlight/#ColorPicker/ColorSelector

Best wishes,
Valentin.Stoychev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
ColorPicker
Asked by
Anton Khramov
Top achievements
Rank 1
Answers by
Valentin.Stoychev
Telerik team
Anton Khramov
Top achievements
Rank 1
Share this question
or