How to align merged column header /

4 posts, 0 answers
  1. Yong Gu Kang
    Yong Gu Kang avatar
    103 posts
    Member since:
    Jan 2010

    Posted 04 Feb 2012 Link to this post

    Hi telerik,

    As shown attached image, merged column header always aligned left-align.
    How can I align it center ?

    Tks
    Kang
  2. Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 06 Feb 2012 Link to this post

    Hi Yong-Gu,

     

    If you take a look at the default template of CommonColumnHeader you may see that the VerticalContentAlignment of this element is set to centered. What you may do is to create simple style targeted at this element and increase the specified Padding, something like the following:


    <Style TargetType="telerik:CommonColumnHeader">
        <Setter Property="Padding" Value="75,0,3,0"/>
    </Style>


    You may see the result at the attached picture. Feel free to change it in the way you need. 
    Hope this helps! 


    Regards,
    Vanya Pavlova
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. Yong Gu Kang
    Yong Gu Kang avatar
    103 posts
    Member since:
    Jan 2010

    Posted 12 Feb 2012 Link to this post

    Hi, Pavlova

    Great, Thank you.
    Hope to be declarative by xaml in the furture.

    RGDS
    Kang
  4. Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 15 Feb 2012 Link to this post

    Hi Yong-Gu,

     

    Another option to achieve this is through defining a header for the corresponding column group. 
    Please refer to our online documentation "Column Headers" for further reference.   


    Regards,
    Vanya Pavlova
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Back to Top