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 

on-the-fly topic lookup or dictionary

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
joe



Joined: 20 Jan 2005
Posts: 44

PostPosted: Mon Jan 31, 2005 5:21 am    Post subject: on-the-fly topic lookup or dictionary Reply with quote

This will select the last full word in whatever "edit" window you are in, i.e. any window in which you can edit text, where CTRL scanning works (CTRL + LEFT) specifically. It will then open google search via Internet Explorer with the selected text as the search term.

Ex: Running the hotkey with the cursor to the right of THIS word in an edit capable window/box will open up google to search for the term "THIS".

Direct application: This was designed to replace the following sequence of keystrokes that I used religiously: CTRL-SHIFT-LEFT, CTRL-C, (internet [button on keyboard, home page set to google]), CTRL-V, ENTER. I would do this for spell checking on the fly sometimes, as google lets you know if you've mispelled your search term.

Other application: As a dictionary (there's a link to dictionary.com's definition of your search term in the upper right corner of google's results page). Or, of course, as a topic search.

Code:

^!S::

send, ^+{LEFT}
send, ^C
phred = iexplore http://www.google.com/search?hl=en&q=%clipboard%
run, %phred%

return


note: AHK's "run, %URL%" will usurp any existing browser windows (at least on a WinXP Infernal Exploder system). If you use a different browser or your system behaves differently, edit the script to reflect this.

-joe
Back to top
View user's profile Send private message
DRSAMRAZA
Guest





PostPosted: Sun Feb 20, 2005 9:37 pm    Post subject: May be you like it Reply with quote

Hey Joe, Great idea. But, couple of things to mention

Why it has a restriction that a word has to be in an editor
What if I want this program to run in the tray all the time and be ready when I need it
and what if the clipboard holds a lot of junk like this whole message

the script will send the entire text to the dictionary search

Well here is the solution if you do not sue me for this. I took your snippet for a spin.

See it here at http://geocities.com/drsamraza/DictionarySearch.zip

Let me know what you feel.

Please read the second last line in the pop up message when you run it
Back to top
afterburner



Joined: 23 Jul 2005
Posts: 52

PostPosted: Sun Jul 24, 2005 4:27 am    Post subject: Reply with quote

The link is not working for me, where can I view it?
Back to top
View user's profile Send private message
corrupt



Joined: 29 Dec 2004
Posts: 2399

PostPosted: Sun Jul 24, 2005 4:39 am    Post subject: Reply with quote

Try here
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions 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