473,385 Members | 1,312 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Mouse manipulation

I am writing a script that interacts with the computer screen.

Is there a module (either built in or add on) that would allow the
script to manipulate the mouse pointer ? -- eg right click, move two
pixels to the right, left click etc?

thank you.

Jan 30 '06 #1
5 1658
arkestra a écrit :
I am writing a script that interacts with the computer screen.

Is there a module (either built in or add on) that would allow the
script to manipulate the mouse pointer ? -- eg right click, move two
pixels to the right, left click etc?

Under Windows, see the SendInput Win32 function (use win32all). Under
Linux, you can write a C binding for the XTest extension.
Jan 30 '06 #2

arkestra schreef:
I am writing a script that interacts with the computer screen.

Is there a module (either built in or add on) that would allow the
script to manipulate the mouse pointer ? -- eg right click, move two
pixels to the right, left click etc?

thank you.


pygame is able to do that.

Jan 30 '06 #3
Rinzwind wrote:
arkestra schreef:
I am writing a script that interacts with the computer screen.

Is there a module (either built in or add on) that would allow the
script to manipulate the mouse pointer ? -- eg right click, move two
pixels to the right, left click etc?

thank you.


pygame is able to do that.


Do you happen to know which of Pygame's packages allow that? I've
searched the docs and Googled for it but it doesn't seem obvious to me
which supports that functionality. (Is it done by posting native events
to the event queue, or is there more direct support? An example or a
link to relevant background info would be appreciated.)

-Peter

Jan 30 '06 #4
I have found something that is similar to what I was looking for -->the
SendKeys module.

But what I am realy looking for is the same thing, but for the mouse :)

Thanks again.

Feb 1 '06 #5
I posted too soon. I installed win32all and the missing dll for 4.2

win32api.SetCursorPos((1,2)) does it!

Thanks for the help.

Feb 1 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: John Champaign | last post by:
Hi all, I'm working on an educational applet for a child with special needs. He's got a bit of a trick to make my life more difficult... To interact with the applet he needs to click on...
9
by: I. Kobrinsky | last post by:
I'm new here. I started a personal password-program, a trial that includes username, logincounter and password. So my intention is to hide pwd while tipping. So I'm thinking about two popular...
9
by: Job | last post by:
Hi, I would like to find out what ASP/ASP.net can do with image manipulation. Does ASP have built in functions (eg. after upload to server) to manipulate images, like rotate, scale, crop etc.?...
4
by: WaterWalk | last post by:
Hello, I'm currently learning string manipulation. I'm curious about what is the favored way for string manipulation in C, expecially when strings contain non-ASCII characters. For example, if...
8
by: shotokan99 | last post by:
i have this situation. i have a query string: http://www.myquerystring.com?x=xxxxx what this url does is it will return or start downloading a .png file. what i wanted to do is trap this png...
0
by: L'eau Prosper Research | last post by:
Press Release: L'eau Prosper Research (Website: http://www.leauprosper.com) releases new TradeStation 8 Add-on - L'eau Prosper Market Manipulation Profiling Tools Set. L'eau Prosper Market...
0
by: L'eau Prosper Research | last post by:
NEW TradeStation 8 Add-on - L'eau Prosper Market Manipulation Profiling Tools Set By L'eau Prosper Research Press Release: L'eau Prosper Research (Website: http://www.leauprosper.com) releases...
4
by: mike | last post by:
I have the opportunity to rescue a project that uses a mouse to sense the relative position of a machine. The hardware is built...just needs to be programmed. Stop snickering!!! I didn't do it...I...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.