Avalonia.Controls.TreeDataGrid icon indicating copy to clipboard operation
Avalonia.Controls.TreeDataGrid copied to clipboard

Make it possible to disable sorting of a column by the user

Open Developer-Alexander opened this issue 1 year ago • 1 comments

Maybe I am not familiar enough with this control but I did not find a way to disable sorting so that the user is not allowed to sort. It would be great to have something like a "CanSort" property per control or per column.

This might become an issue as sorting has a massive impact on the performance. Especially when the source collection is updated very frequently.

Developer-Alexander avatar Jun 09 '23 11:06 Developer-Alexander

In the TextColumn constructor, you can provide a TextColumnOptions instance. This has a "CanUserSortColumn" boolean property which can be set.

xLEGiON avatar Oct 08 '23 16:10 xLEGiON