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

UI improvements and bug fixes #13

Merged
merged 13 commits into from
Sep 5, 2024

Conversation

mwomick
Copy link
Contributor

@mwomick mwomick commented Aug 31, 2024

Description

Major changes:

  • [Feature] Pre-render the canvas so we don't have to redraw the canvas on every draw update.
  • [Bug fix] Closing polygon using 'Enter' now clears the canvas before redrawing.
  • [Feature] Do not accumulate darkness of overlapping shapes. Instead, fill all polygons at the same time and blend colors once for a uniform fill.
  • [Bug fix] Immediately refresh the canvas on undo. Previously, one had to move the mouse to update the canvas.

Other changes:

  • Allow user to press upper or lower case letters to change draw mode (i.e. 'l'/'L' and 'p'/'P'). This reduces confusion because the documentation currently says press 'L' or 'P' but it means 'l' or 'p'. Now either are acceptable.
  • Some minimal refactoring
  • Now colors cycle periodically instead of randomly. The old method permitted some double coloring after all the colors in color_choices had been exhausted.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

How has this change been tested, please provide a testcase or example of how you tested the change?

Tested manually in Safari and Chrome.

Any specific deployment considerations

Some documentation might need to be updated to reflect the change in the keys used to switch draw modes.

@mwomick
Copy link
Contributor Author

mwomick commented Sep 4, 2024

@capjamesg I made a pull request this weekend that solves most of the remaining issues I identified and also added some minor features and optimizations. The main issue remaining is saving the canvas, but I don't want to prioritize that now since it's a tricky problem and doesn't seem to be a frequently used feature.

@capjamesg
Copy link
Collaborator

This looks great! I will merge now.

One idea for the future: It would be amazing if Ctrl + Z (undo) let you undo your last polygon.

@capjamesg capjamesg merged commit 86e8149 into roboflow:main Sep 5, 2024
1 check passed
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