Page 2 of 2

Re: Mouse over in Ruby is buggy?

PostPosted: Thu Jan 07, 2021 11:22 pm
by trogluddite
tulamide wrote:we humans have a hard time reading code that isn't tidy and structured

I wouldn't argue against anything you said there - and I wish that DSPr had taken your advice when they originally designed the Ruby mouse handling (amongst other things)! This whole thread wouldn't have been necessary if "isInMousePoint" didn't interact with the other mouse methods in such a hidden way - and it shouldn't have taken a decade of collective effort to work out the logic behind it, which is neither well explained in the user guide nor made clear by stock toolbox examples.

As for FlowStone's built-in "safety nets" (e.g. having the default dragging cursor change) - I've always been a bit in two minds about them. Certainly, they help novices to make working modules, but they can also encourage lazy coding practices that come back to bite you when things get more complicated. It's as well that there is both an explanation of what DSPr seemed to intend, and your reminder that we can sometimes improve on that!