Re: Is there any way to move to a certain position in AppleScript Editor 2.3
Re: Is there any way to move to a certain position in AppleScript Editor 2.3
- Subject: Re: Is there any way to move to a certain position in AppleScript Editor 2.3
- From: Tommy Bollman <email@hidden>
- Date: Wed, 28 Jul 2010 23:15:10 +0200
Hello.
I found the solution in some Apple provided AppleScript Editor Scripts.
tell application "AppleScript Editor"
tell its document 1
set selection to character 19
-- or from the handler I stole it from: set selection to characters this_offset thru (this_offset + (length of the target_string) - 1)
end tell
end tell
I have to use or uses System Events to push a key in order to move the windows to a location in both Smile and Script Debugger, so this will work fine. I sense that this will work tomorrow too.
On 28 Jul 2010, at 22:09, Tommy Bollman wrote:
> Hello.
>
> Well, it may have done it that single time, but it does not work now. Do anybody of you know the *curse* for moving the cursor
> in a window in AppleScript Editor, which preferably does not come with a price tag.
>
> If anybody know about a command line utility which moves the cursor in in a cocoa window, by addressing the window by its id, then
> I'll live happily with that.
>
> Thanks
> On 27 Jul 2010, at 01:42, Tommy Bollman wrote:
>
>> Hello.
>>
>> "set insertion point of text of document 1 to {40, 1}"
>>
>> did the trick, sorry for the bother.
>>
>> I'm coming back on this as I soon have something to show you.
>>
>> "Be pestered and reap the rewards!" :-)
>>
>>
>> On 27 Jul 2010, at 01:27, Tommy Bollman wrote:
>>
>>> Hello.
>>>
>>> I can't find a way to move the curser to a given character position in Script Editor. I have only found the character range of the selection-object and that appear to be read only.
>>>
>>> I cant anything about gui scripting yet. Is this some how possible with gui-scripting, setting the AXRange, if there is an AX range.
>>> Or do anybody know about some workaround, or the right curses?
>>>
>>> Thanks.
>>>
>>> Best regards
>>>
>>>
>>>
>>> Tommy Bollman
>>> --------------------------------------------------------------------------------------------------
>>> Mollison's Bureaucracy Hypothesis:
>>> If an idea can survive a bureaucratic review
>>> and be implemented it wasn't worth doing.
>>>
>>
>> Best regards
>>
>>
>>
>> Tommy Bollman
>> --------------------------------------------------------------------------------------------------
>> Mollison's Bureaucracy Hypothesis:
>> If an idea can survive a bureaucratic review
>> and be implemented it wasn't worth doing.
>>
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> AppleScript-Users mailing list (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>> Archives: http://lists.apple.com/archives/applescript-users
>>
>> This email sent to email@hidden
>>
>
> Best regards
>
>
>
> Tommy Bollman
> --------------------------------------------------------------------------------------------------
> Mollison's Bureaucracy Hypothesis:
> If an idea can survive a bureaucratic review
> and be implemented it wasn't worth doing.
>
Best regards
Tommy Bollman
--------------------------------------------------------------------------------------------------
Mollison's Bureaucracy Hypothesis:
If an idea can survive a bureaucratic review
and be implemented it wasn't worth doing.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden