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

Wrapping column headers & horizontal scrolling issue

1 Answer 44 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Elias Puurunen
Top achievements
Rank 1
Elias Puurunen asked on 12 Sep 2011, 08:36 PM
I've followed the tutorial posted in the documentation to wrap column header text.

http://www.telerik.com/help/silverlight/gridview-howto-wrap-text-column-header.html

However, I'm running into an issue where if I resize the column, then scroll it out of view (horizontally), the header resizes and becomes its original height until that column scrolls back into view.

Is this a known issue, and is there a workaround?

Is there any better way to wrap header text? This should be such a simple operation but has turned into a nightmare.

1 Answer, 1 is accepted

Sort by
0
Maya
Telerik team
answered on 16 Sep 2011, 09:14 AM
Hi Elias,

This would be the expected behavior since the visual elements are created when they are in the view port, recycled and reused on scrolling. Thus the header cell which height gets higher on resizing it, will be reused for the cells that come in the visible area afterwards. That is why its height gets lost. 
What you may try is to set MinHeight for GridViewHeaderRow, thus making it not to be shorter than that size:

<Style TargetType="telerik:GridViewHeaderRow">
            <Setter Property="MinHeight" Value="40" />
        </Style>


Regards,

Maya
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
GridView
Asked by
Elias Puurunen
Top achievements
Rank 1
Answers by
Maya
Telerik team
Share this question
or