style: apply CSharpier formatting to all C# sources
Repo-wide sweep with the pinned CSharpier 1.3.0 tool. Whitespace and line-wrapping only; OpenNest.Engine.Tests (109) and OpenNest.IO.Tests pass after reformat, full solution builds 0 errors. Added .csharpierignore so csproj/config XML keeps its existing layout (CSharpier's XML wrapping churns attributes with zero benefit). Formatting is now enforceable: dotnet csharpier check . passes.
This commit is contained in:
@@ -1,21 +1,25 @@
|
||||
using OpenNest.Geometry;
|
||||
using OpenNest.Math;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using OpenNest.Geometry;
|
||||
using OpenNest.Math;
|
||||
|
||||
namespace OpenNest.RectanglePacking
|
||||
{
|
||||
internal class PackBottomLeft : PackEngine
|
||||
{
|
||||
public PackBottomLeft(Bin bin)
|
||||
: base(bin)
|
||||
{
|
||||
}
|
||||
: base(bin) { }
|
||||
|
||||
public override void Pack(List<Item> items)
|
||||
{
|
||||
var byArea = items.Select(i => i.Clone() as Item).OrderByDescending(i => i.Area()).ToList();
|
||||
var byLength = items.Select(i => i.Clone() as Item).OrderByDescending(i => System.Math.Max(i.Width, i.Length)).ToList();
|
||||
var byArea = items
|
||||
.Select(i => i.Clone() as Item)
|
||||
.OrderByDescending(i => i.Area())
|
||||
.ToList();
|
||||
var byLength = items
|
||||
.Select(i => i.Clone() as Item)
|
||||
.OrderByDescending(i => System.Math.Max(i.Width, i.Length))
|
||||
.ToList();
|
||||
|
||||
var resultA = PackWithOrder(byArea);
|
||||
var resultB = PackWithOrder(byLength);
|
||||
|
||||
Reference in New Issue
Block a user