Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update tools.js's TOOL_RECTANGLE so that rectangles have sharp edge, working around weirdness in latest Firefox #329

Merged
merged 1 commit into from
Nov 10, 2023

Conversation

milksteakjellybeans
Copy link
Contributor

As discussed in #326, the drawing of rectangles show a blurred/anti-aliased edge in the recent versions of Firefox. This change restores sharp edges in Firefox. The change is modeled after how the existing code handles the degenerate case of drawing the rectangle (when the rectangle is either not as tall or not as wide as double the rectangle line width), but this version just draws four rectangles, one for each side. There's probably a lot more efficient ways to do this, but this was the simplest fix that fit in with the paradigm that I saw.

… working around weirdness in latest Firefox

As discussed in 1j01#326,
the drawing of rectangles show a blurred/anti-aliased edge in the recent versions of Firefox.  This change restores sharp edges in Firefox.  The change is modeled after how the existing code  handles the degenerate case of drawing the rectangle (when the rectangle is either not as tall or not as wide as double the rectangle line width), but this version just draws four rectangles, one for each side.
@1j01 1j01 merged commit c5cf784 into 1j01:master Nov 10, 2023
1 check passed
@1j01
Copy link
Owner

1j01 commented Nov 10, 2023

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants