Skip to content

Commit

Permalink
Fix offset for Fill method
Browse files Browse the repository at this point in the history
  • Loading branch information
adrianstevens committed Jun 2, 2024
1 parent beac2a4 commit 5bf9444
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Source/LedMatrix8x16Wing/Driver/LedMatrix8x16Wing.cs
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,10 @@ public void Fill(Color fillColor, bool updateDisplay = false)
{
Fill(0, 0, Width, Height, fillColor);

if (updateDisplay) Show();
if (updateDisplay)
{
Show();
}
}

/// <summary>
Expand All @@ -174,7 +177,7 @@ public void Fill(int x, int y, int width, int height, Color fillColor)
{
for (int j = 0; j < height; j++)
{
DrawPixel(i, j, isColored);
DrawPixel(x + i, y + j, isColored);
}
}
}
Expand Down

0 comments on commit 5bf9444

Please sign in to comment.