I added GRAB_CURSOR and BLOCKING to my modal operator so the mouse cursor wraps around when I perform certain operations.

I also have a simple text UI that I made using blf.draw(...)

Since my UI is drawn using event.mouse_x and event.mouse_y my UI eventually gets drawn out of view because those values keep growing endlessly now.

What command can I use to get the mouse cursor position after it wraps around so I can use that specifically to draw my UI inside the 3D view?


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.