ColorPaletteView color item spacing

2 posts, 0 answers
  1. Tracy
    Tracy avatar
    29 posts
    Member since:
    Sep 2010

    Posted 25 Aug 2011 Link to this post

    <telerik:RadColorPaletteView HorizontalAlignment="Left"  Width="150" 
                                 PaletteOrientation="Horizontal" PaletteColumnsCount="8"
                                 ItemsSource="{Binding AvailableColors}" 
                                 SelectedItem="{Binding TagColor, Mode=TwoWay}"

    We are using the ColorPaletteView with a defined set of 13 colors in two rows. There is sufficient spacing between the columns but vertically the color items seem to not have any spacing between them.

    How do I specify the spacing between the rows of color items?

  2. Petar Mladenov
    Petar Mladenov avatar
    2882 posts

    Posted 31 Aug 2011 Link to this post

    Hello Tracy,

     You can use Margin in the RadColorPaletteViewItems like so:

           <Style TargetType="telerik:RadColorPaletteViewItem" x:Key="itemsStyle">
               <Setter Property="Margin" Value="5 5 5 5" />
           <telerik:RadColorPaletteView x:Name="palette" ItemContainerStyle="{StaticResource itemsStyle}"/>
    Feel free to ask if you need further assistance.All the best,
    Petar Mladenov
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

  3. DevCraft R3 2016 release webinar banner
Back to Top