Skip to content

Commit

Permalink
this seems like overkill
Browse files Browse the repository at this point in the history
  • Loading branch information
tomlm committed Nov 20, 2024
1 parent 4408182 commit e073ab7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Consolonia.Core/Drawing/DrawingContextImpl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -302,9 +302,9 @@ public Matrix Transform
/// <param name="line">line</param>
private void DrawLineInternal(IPen pen, Line line)
{
if (pen.Thickness == 0) return;
if (pen.Thickness.IsNearlyEqual(0)) return;

if (pen.Thickness == UnderlineThickness || pen.Thickness == StrikethroughThickness)
if (pen.Thickness.IsNearlyEqual(UnderlineThickness) || pen.Thickness.IsNearlyEqual(StrikethroughThickness))
{
if (line.Vertical)
throw new NotSupportedException("Vertical strikethrough or underline text decorations is not supported.");
Expand Down

0 comments on commit e073ab7

Please sign in to comment.