Columns are not cannot be re-sized beyond grid width when at least one column has Width set to *. This is not the behavior that I would expect and in my opinion it makes the * option almost useless because as soon as you use it, resizing columns behaviors awkwardly where the grid always tries to maintain a static total width and steals the width from other existing columns when a column is made wider.
I would expect the behavior for Width * instead to fill the available space if there is additional available horizontal space within the RadGridView control to fill. Generally this would be equal to the situation where a horizontal scroll bar is not automatically shown because it is not needed. If there is no additional horizontal space to consume with the * columns(s) then either their MinWidth values and/or Auto behavior come into play to determine what the size of these columns should be. After initial layout is done and the user attempts to re-size a column, then any column should allow resizing to grow the column larger up until it's MaxWidth value and push any columns to extend into the clipped region causing horizontal scroll to become active if it wasn't already.
If I change the definition of Column1 so that it has a Width of Auto instead of * so effectively there are no * columns then everything works as expected. Well almost, that is except for when the total width of all columns is less than the width of the GridView control itself then I get what a lot of people describe as the "extra blank column" which I understand is just there because there are no * columns to automatically fill the space. This is where I would expect a properly behaving * column to kick in and properly consume that available space, but only in this situation.
<
Window
x:Class
=
"TelerikRadGridViewTest.MainWindow"
xmlns:telerik
=
"http://schemas.telerik.com/2008/xaml/presentation"
Title
=
"MainWindow"
Height
=
"350"
Width
=
"525"
>
<
Grid
>
<
telerik:RadGridView
Name
=
"grdEstimates"
Margin
=
"5,1,0,0"
ShowGroupPanel
=
"False"
IsFilteringAllowed
=
"False"
AutoGenerateColumns
=
"False"
IsReadOnly
=
"True"
>
<
telerik:RadGridView.Columns
>
<
telerik:GridViewDataColumn
Header
=
"Column1"
Width
=
"*"
SortMemberPath
=
"Column1"
UniqueName
=
"Column1"
/>
<
telerik:GridViewDataColumn
Header
=
"Column2"
Width
=
"Auto"
SortMemberPath
=
"Column2"
UniqueName
=
"Column2"
/>
<
telerik:GridViewDataColumn
Header
=
"Column3"
Width
=
"Auto"
SortMemberPath
=
"Column3"
UniqueName
=
"Column3"
/>
<
telerik:GridViewDataColumn
Header
=
"Column4"
Width
=
"Auto"
SortMemberPath
=
"Column4"
UniqueName
=
"Column4"
/>
<
telerik:GridViewDataColumn
Header
=
"Column5"
Width
=
"Auto"
SortMemberPath
=
"Column5"
UniqueName
=
"Column5"
DataFormatString
=
"{}{0:C}"
/>
<
telerik:GridViewDataColumn
Header
=
"Column7"
Width
=
"Auto"
SortMemberPath
=
"Column7"
UniqueName
=
"Column7"
DataFormatString
=
"{}{0:C}"
/>
<
telerik:GridViewDataColumn
Header
=
"Column7"
Width
=
"Auto"
SortMemberPath
=
"Column7"
UniqueName
=
"Column7"
/>
</
telerik:RadGridView.Columns
>
</
telerik:RadGridView
>
</
Grid
>
</
Window
>
I would expect the behavior for Width * instead to fill the available space if there is additional available horizontal space within the RadGridView control to fill. Generally this would be equal to the situation where a horizontal scroll bar is not automatically shown because it is not needed. If there is no additional horizontal space to consume with the * columns(s) then either their MinWidth values and/or Auto behavior come into play to determine what the size of these columns should be. After initial layout is done and the user attempts to re-size a column, then any column should allow resizing to grow the column larger up until it's MaxWidth value and push any columns to extend into the clipped region causing horizontal scroll to become active if it wasn't already.
If I change the definition of Column1 so that it has a Width of Auto instead of * so effectively there are no * columns then everything works as expected. Well almost, that is except for when the total width of all columns is less than the width of the GridView control itself then I get what a lot of people describe as the "extra blank column" which I understand is just there because there are no * columns to automatically fill the space. This is where I would expect a properly behaving * column to kick in and properly consume that available space, but only in this situation.