[python-win32] mouse cursor coordinates

Jacob Kruger jacobk at mailzone.co.za
Tue Feb 7 07:26:25 CET 2012


OK, did another web search relating to this now, and found the following 
page:
http://atcoalition.org/article/large-computer-pointerscursors

Either way, there they mention that on windows, if you go to mouse pointer 
options, there's an option you can enable/turn on:
Show location of pointer when I press the CTRL key

And it apparently makes the mouse cursor turn into a relatively visible 
bulls eye type pointer then...?

Also means that if partially sighted guys find the right .cur file to maybe 
replace the specifically used bullseye file with, they should easily enough 
be able to implement something like a large cross hair cursor based on a 
keystroke as such, using built in windows functionality.

Stay well

Jacob Kruger
Blind Biker
Skype: BlindZA
'...fate had broken his body, but not his spirit...'

----- Original Message ----- 
From: "Jacob Kruger" <jacobk at mailzone.co.za>
To: <python-win32 at python.org>
Sent: Friday, February 03, 2012 9:43 PM
Subject: Re: [python-win32] mouse cursor coordinates


> Ok, just tested it using win32gui.GetCursorPos function, and it does seem 
> to obtain coordinates outside primary window as well, so let's see - 
> thanks.
>
> Stay well
>
> Jacob Kruger
> Blind Biker
> Skype: BlindZA
> '...fate had broken his body, but not his spirit...'
>
> ----- Original Message ----- 
> From: "Tim Roberts" <timr at probo.com>
> To: "Python-Win32 List" <python-win32 at python.org>
> Sent: Friday, February 03, 2012 8:22 PM
> Subject: Re: [python-win32] mouse cursor coordinates
>
>
>> Jacob Kruger wrote:
>>> Wondering off-hand if there's a simple/easy way to obtain mouse cursor
>>> coordinates, and, also, how simple is it to interact with operating
>>> system, in terms of if the mouse cursor is in fact outside the GUI as
>>> such - if that makes sense?
>>
>> win32gui.GetCursorPos will return the current mouse position in screen
>> coordinates.
>>
>> Your second question is not clear to me.  An application does not
>> receive mouse messages when the mouse goes outside its window, unless it
>> is using "mouse capture".  If you click on a button control and hold the
>> mouse button down, then drag the mouse outside the button, you'll notice
>> that the button window stays depressed until you release the mouse.
>> That happens because the button control "captures the mouse".  All mouse
>> messages are directed only to the button until it releases capture,
>> which it will do when the mouse button is released.
>>
>> Beyond that, you'll have to ask a more specific question.
>>
>> -- 
>> Tim Roberts, timr at probo.com
>> Providenza & Boekelheide, Inc.
>>
>> _______________________________________________
>> python-win32 mailing list
>> python-win32 at python.org
>> http://mail.python.org/mailman/listinfo/python-win32
>
> _______________________________________________
> python-win32 mailing list
> python-win32 at python.org
> http://mail.python.org/mailman/listinfo/python-win32 



More information about the python-win32 mailing list