Change the action performed by scroll wheel

How can I change the action performed by scroll wheel? By default, I can zoom in and zoom out using the scroll wheel. How can I change it so that the selected object rotates when I scroll?

Why do I need this: I want to see if I can read mouse actions (clicks and scroll wheel movements) via SketchUp and make it function differently.


When your custom Ruby Tool is active.

  • You can read mouse clicks (and do things.)

    • button down events (and do things.)
    • button up events (and do things.)
    • button double clicks (and do things.)
  • You can respond to the mouse moving (and do things.)

  • You can respond to the mouse entering or leaving the SU client view area (and do things.)

But the scroll wheel is not yet exposed in the SketchUp Ruby API.

You could easily create a “Z-spin” tool that uses the left and right mouse buttons.

Thanks Dan.

Could you please point me to a piece of code which reads mouse clicks or a plugin that does this. I am new to SketchUp, so I am not sure how to look for information.

Thanks again.

The Example Rudy Scripts on Extension Warehouse are a good starting point…

1 Like