Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Python: How to click on the screen at a specific place in python, MAC OS

Tags:

python

macos

I want to use a python program to move the cursor around on the screen and click on a specific location in Mac OS.

I have seen some good threads on this for Windows and Ubuntu, but I'm looking for OSX.

Windows: Using Perl, Python, or Ruby, how to write a program to "click" on the screen at scheduled time?

Ubuntu: How to click on a coordinate on a screen?

like image 370
Rishi Avatar asked Aug 08 '26 00:08

Rishi


1 Answers

Instead of searching for "how to move the cursor in OSX using Python", you'll find much better results if you search for "how to move the cursor in OSX", then search for how to use that interface with Python.

It seems that Objective-C/Cocoa is used to integrate with the native Mac OS X interface, and the Python documentation recommends using PyObjC as a Python binding to Apple’s Objective-C/Cocoa framework.

Hopefully this is enough information to get you on your way.

like image 160
dln385 Avatar answered Aug 10 '26 13:08

dln385



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!