From af018991e2f1814073d2210a949cd5ce5a3752b3 Mon Sep 17 00:00:00 2001 From: Olivia Date: Sat, 17 Dec 2016 20:13:40 +0100 Subject: [PATCH] Fixing stylecop warnings on whitespace and usings. --- src/ImageSharp/Colors/PackedPixel/IPackedPixel.cs | 1 + src/ImageSharp/Drawing/Brushes/Brushes`2.cs | 4 ++-- src/ImageSharp/Drawing/Brushes/PatternBrush`2.cs | 6 +++--- src/ImageSharp/Drawing/Draw.cs | 1 + src/ImageSharp/Drawing/Processors/DrawPathProcessor.cs | 8 ++++---- src/ImageSharp/Drawing/Processors/FillShapeProcessor.cs | 2 +- src/ImageSharp/Drawing/Shapes/LinearPolygon.cs | 2 +- 7 files changed, 13 insertions(+), 11 deletions(-) diff --git a/src/ImageSharp/Colors/PackedPixel/IPackedPixel.cs b/src/ImageSharp/Colors/PackedPixel/IPackedPixel.cs index 5706d907d..08257fa68 100644 --- a/src/ImageSharp/Colors/PackedPixel/IPackedPixel.cs +++ b/src/ImageSharp/Colors/PackedPixel/IPackedPixel.cs @@ -6,6 +6,7 @@ namespace ImageSharp { using System; + /// /// An interface that represents a packed pixel type. /// diff --git a/src/ImageSharp/Drawing/Brushes/Brushes`2.cs b/src/ImageSharp/Drawing/Brushes/Brushes`2.cs index 5d2f81dc8..2e2eb5ad3 100644 --- a/src/ImageSharp/Drawing/Brushes/Brushes`2.cs +++ b/src/ImageSharp/Drawing/Brushes/Brushes`2.cs @@ -3,10 +3,10 @@ // Licensed under the Apache License, Version 2.0. // -using System; - namespace ImageSharp.Drawing.Brushes { + using System; + /// /// A collection of methods for creating generic brushes. /// diff --git a/src/ImageSharp/Drawing/Brushes/PatternBrush`2.cs b/src/ImageSharp/Drawing/Brushes/PatternBrush`2.cs index 203fa85cd..cdbdf23ad 100644 --- a/src/ImageSharp/Drawing/Brushes/PatternBrush`2.cs +++ b/src/ImageSharp/Drawing/Brushes/PatternBrush`2.cs @@ -5,10 +5,10 @@ namespace ImageSharp.Drawing.Brushes { + using System; using System.Numerics; using Processors; - using System; /// /// Provides an implementation of a pattern brush for painting patterns. @@ -30,12 +30,12 @@ namespace ImageSharp.Drawing.Brushes /// 0 /// 0 /// - /// Warning when use array initializer across multiple lines the bools look inverted i.e. + /// Warning when use array initializer across multiple lines the bools look inverted i.e. /// new bool[,]{ /// {true, false, false}, /// {false,true, false} /// } - /// would be + /// would be /// 10 /// 01 /// 00 diff --git a/src/ImageSharp/Drawing/Draw.cs b/src/ImageSharp/Drawing/Draw.cs index e3d1be350..0f58c5727 100644 --- a/src/ImageSharp/Drawing/Draw.cs +++ b/src/ImageSharp/Drawing/Draw.cs @@ -220,6 +220,7 @@ namespace ImageSharp { return source.DrawPolygon(pen, new Polygon(new LinearLineSegment(points)), options); } + /// /// Draws the provided Points as a closed Linear Polygon with the provided Pen. /// diff --git a/src/ImageSharp/Drawing/Processors/DrawPathProcessor.cs b/src/ImageSharp/Drawing/Processors/DrawPathProcessor.cs index b1b3e8dc9..af0af20fa 100644 --- a/src/ImageSharp/Drawing/Processors/DrawPathProcessor.cs +++ b/src/ImageSharp/Drawing/Processors/DrawPathProcessor.cs @@ -34,7 +34,7 @@ namespace ImageSharp.Drawing.Processors private readonly IPath[] paths; private readonly RectangleF region; private readonly GraphicsOptions options; - + /// /// Initializes a new instance of the class. /// @@ -56,7 +56,7 @@ namespace ImageSharp.Drawing.Processors : this(pen, new[] { path }, options) { } - + /// /// Initializes a new instance of the class. /// @@ -134,10 +134,10 @@ namespace ImageSharp.Drawing.Processors currentPoint.X = offsetX; currentPoint.Y = offsetY; - var dist = Closest(currentPoint); + var dist = this.Closest(currentPoint); var color = applicator.GetColor(dist); - + var opacity = this.Opacity(color.DistanceFromElement); if (opacity > Epsilon) diff --git a/src/ImageSharp/Drawing/Processors/FillShapeProcessor.cs b/src/ImageSharp/Drawing/Processors/FillShapeProcessor.cs index 6ced979e5..0dee0095e 100644 --- a/src/ImageSharp/Drawing/Processors/FillShapeProcessor.cs +++ b/src/ImageSharp/Drawing/Processors/FillShapeProcessor.cs @@ -73,7 +73,7 @@ namespace ImageSharp.Drawing.Processors { polyStartY = 0; } - + using (PixelAccessor sourcePixels = source.Lock()) using (IBrushApplicator applicator = this.fillColor.CreateApplicator(rect)) { diff --git a/src/ImageSharp/Drawing/Shapes/LinearPolygon.cs b/src/ImageSharp/Drawing/Shapes/LinearPolygon.cs index 2b7a0292a..03069b678 100644 --- a/src/ImageSharp/Drawing/Shapes/LinearPolygon.cs +++ b/src/ImageSharp/Drawing/Shapes/LinearPolygon.cs @@ -25,7 +25,7 @@ namespace ImageSharp.Drawing.Shapes { this.innerPolygon = new Polygon(new LinearLineSegment(points)); } - + /// /// Gets the bounding box of this shape. ///