Fix and further refine drawing & selection behavior

[#73959546]

- Fix a bug visible after switching one shape tool to another
- Let user activate tool again to lock drawing mode
- Fix style & lint errors