AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to determine cursor position

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Guestz
Guest





PostPosted: Wed Feb 24, 2010 1:20 am    Post subject: How to determine cursor position Reply with quote

Is there a way to determine the entry cursor position?

I don't mean the mouse position, I mean the where text shows up on the screen when you type.

I can't find anything in the tutorial on how to determine it's position.

Thanks in advance
Back to top
Guest






PostPosted: Wed Feb 24, 2010 1:24 am    Post subject: Reply with quote

ControlGetPos might helps
Back to top
None



Joined: 28 Nov 2009
Posts: 3086

PostPosted: Wed Feb 24, 2010 1:28 am    Post subject: Reply with quote

Quote:
A_CaretX and A_CaretY: The current X and Y coordinates of the caret (text insertion point). The coordinates are relative to the active window unless CoordMode is used to make them relative to the entire screen. If there is no active window or the caret position cannot be determined, these variables are blank.
Question Question Question
Back to top
View user's profile Send private message
ribbet.1



Joined: 20 Feb 2007
Posts: 197
Location: D.C.

PostPosted: Wed Mar 10, 2010 9:30 pm    Post subject: Reply with quote

None wrote:
Quote:
A_CaretX and A_CaretY: The current X and Y coordinates of the caret (text insertion point). The coordinates are relative to the active window unless CoordMode is used to make them relative to the entire screen. If there is no active window or the caret position cannot be determined, these variables are blank.
Question Question Question


Any suggestions for applications that don't work with A_CaretX and Y, such as Adobe Acrobat? Reports the same position no matter what.
Back to top
View user's profile Send private message
SoLong&Thx4AllTheFish



Joined: 27 May 2007
Posts: 4999

PostPosted: Wed Mar 10, 2010 9:35 pm    Post subject: Reply with quote

ribbet.1 wrote:
Any suggestions for applications that don't work with A_CaretX and Y, such as Adobe Acrobat? Reports the same position no matter what.
Many have tried, all have failed Sad So for now the answer seems no although it SHOULD be possible as there are applications that can see the caret position in such programs like firefox, thunderbird and acrobat.
_________________
AHK Wiki FAQ
TF : Text files & strings lib, TF Forum
Back to top
View user's profile Send private message
ribbet.1



Joined: 20 Feb 2007
Posts: 197
Location: D.C.

PostPosted: Wed Mar 10, 2010 9:46 pm    Post subject: Reply with quote

hugov wrote:
ribbet.1 wrote:
Any suggestions for applications that don't work with A_CaretX and Y, such as Adobe Acrobat? Reports the same position no matter what.
Many have tried, all have failed Sad So for now the answer seems no although it SHOULD be possible as there are applications that can see the caret position in such programs like firefox, thunderbird and acrobat.


I can't find a "crying" emoticon, HugoV. Thanks for the reply though!

Acrobat is such a piece of crippleware. They make me feel like it's 1995 all over again!
Back to top
View user's profile Send private message
ribbet.1



Joined: 20 Feb 2007
Posts: 197
Location: D.C.

PostPosted: Thu Mar 11, 2010 1:53 am    Post subject: Reply with quote

OK, little workaround, should work in my case, maybe not for others. In this instance, I search for a certain bit of text. When the text is found, it's highlighted. I can then use PixelSearch to find the first instance of the highlight color, which will be the coords of the top left corner of said highlighted text block. Which is enough for me to work with in this instance.
Back to top
View user's profile Send private message
jerryo



Joined: 07 Oct 2009
Posts: 7

PostPosted: Sat Feb 12, 2011 10:23 pm    Post subject: Reply with quote

Anybody got any further on this little issue, please?
*looks for praying smiley*
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group