I would like to sort a List(Of RectangleF) somehow.
It is going to be huge, so I would rather not have to create a separate class that implements Comparable –
Is it possible to somehow override the RectangleF itself, to add a Comparable, and ovverride a CompareTo to compare by X ?
I am using VB.NET, but I would appreciate C# advice as well.
You can use LINQ’s
OrderBymethods to sort however you choose.For example, if you want to order the list by X, you could do: