Browse Source

change the column count variable to row count in createHorizontalLines.

Apply the applyGrid (async) name change to the CLI and Test Centre.
master
Craig Oates 6 years ago
parent
commit
d05e830151
  1. 2
      DeathSocket/ImageServices.fs
  2. 4
      DeathSocketCLI/Commands.fs
  3. 2
      TestCentre/LibraryTests.fs

2
DeathSocket/ImageServices.fs

@ -21,7 +21,7 @@
let graphics = Graphics.FromImage img let graphics = Graphics.FromImage img
let pen = new Pen (spec.colour, width = spec.penWidth) let pen = new Pen (spec.colour, width = spec.penWidth)
let horizontalLines = let horizontalLines =
createHorizontalLines (img.Size.Width) (img.Size.Height) (spec.columns) createHorizontalLines (img.Size.Width) (img.Size.Height) (spec.rows)
let verticalLines = createVerticalLines (img.Size.Width) (img.Size.Height) (spec.columns) let verticalLines = createVerticalLines (img.Size.Width) (img.Size.Height) (spec.columns)
for line in horizontalLines do graphics.DrawLines (pen, line) for line in horizontalLines do graphics.DrawLines (pen, line)
for line in verticalLines do graphics.DrawLines (pen, line) for line in verticalLines do graphics.DrawLines (pen, line)

4
DeathSocketCLI/Commands.fs

@ -38,7 +38,7 @@
try try
printfn "[INFO.] Adding default grid to image..." printfn "[INFO.] Adding default grid to image..."
buildDefaultSpec imgPath newPath buildDefaultSpec imgPath newPath
|> applyGrid |> applyGridAsync
|> Async.RunSynchronously |> Async.RunSynchronously
showEndOfCommandMessage showEndOfCommandMessage
with with
@ -57,7 +57,7 @@
try try
printfn "[INFO.] Adding grid to image..." printfn "[INFO.] Adding grid to image..."
buildSpec imgPath numRows numColumns pWidth colour newPath buildSpec imgPath numRows numColumns pWidth colour newPath
|> applyGrid |> applyGridAsync
|> Async.RunSynchronously |> Async.RunSynchronously
showEndOfCommandMessage showEndOfCommandMessage
with with

2
TestCentre/LibraryTests.fs

@ -85,7 +85,7 @@
penWidth = float32 1 penWidth = float32 1
rows = 10 rows = 10
columns = 10 } columns = 10 }
applyGrid spec applyGridAsync spec
|> Async.RunSynchronously |> Async.RunSynchronously
(File.Exists sPath) = true (File.Exists sPath) = true

Loading…
Cancel
Save