Highlight the text of the common AHK script to retrieve translator

The term work can be roughly divided into three translator part: retrieving translation, save the results, reading and processing a search result.

1. For retrieval, it is a dictionary, and the other is Google / watercress / libgen / video site search.

2. After the search requirements is to record the results obtained, especially as pdf annotation recorded.

3. Demand after recorded is easily read, particularly saved in CSV format, to facilitate the production of the glossary.

This article first treatment of the first demand, the next two deal with the latter two.

AHK script is the most simple solution, anyway, there is no ready-made desktop search software.

 

 

Retrieval procedures must be minimized, but must ensure that the correct search terms can be selected. This is difficult to properly select, because search terms may be longer or shorter, there is no fixed one-off operation can be selected. So step to select the search term can only be done manually, or enter it directly.

The following are two retrieval: one is the search terms is readily available in the reading process that is retrieved, and the other is the case of the search terms entered on their own needs. The latter already have an existing code: https:? //Www.autohotkey.com/boards/viewtopic.php f = 6 & t = 7373

The following is my very humble pdf read retrieval code:

 

 

 

; Only when the Internet and read the pdf is available, so as not to interfere with other inputs. You can easily modify according to their own readers. everything path must be modified to route your computer.
; Shift + basic operation is the first letter of the search engine. It can be customized according to their own search habits.

Ahk_exe firefox.exe #IfWinActive
#IfWinActive, ahk_exe BookxNote.exe
#IfWinActive, ahk_exe Acrobat.exe

; beep beep miles miles
+ B ::
{
    the Send, C ^
    Sleep 50
    the Run, https://search.bilibili.com/all? 22 is `% =% keyword% Clipboard%` 22 is
    the Return
}

; bean reading
+ D ::
{
    the Send, C ^
    Sleep 50
    the Run, https://search.douban.com/book/subject_search?search_text=`%22%clipboard 22 is CAT & `%% 1001 =
    the Return
}


; Google
+ G ::
{
    the Send, C ^
    Sleep 50
    RUN, http://www.google.com/search?q=`%22%clipboard%`%22
    the Return
}



; Libgen
+ L ::
{
    the Send, C ^
    Sleep 50
    RUN, https://libgen.is/ ? the search.php REQ = `% 22 is% Clipboard%`% 22 is & lg_topic = Libgen & Open = 0 & View = Simple & RES = 25 & phrase =. 1 & column = DEF
    the Return
}


; tubing
+ Y ::
{
    the Send, ^ C
    Sleep 50
    the Run, HTTPS: // WWW. youtube.com/results?search_query=`%22%clipboard%`%22
    the Return
}


; local search Everything
+ V ::
Send, Ctrl Down} {C} {Ctrl up
IfWinExist ahk_class EVERYTHING
    WinActivate
the else
    RUN G: \ software archive \ Convert \ Everything-1.4.1.965.x64- portable \ Everything.exe
    
Sleep 500
Send ^v
send {Enter}
    Return



   

 

Guess you like

Origin www.cnblogs.com/tanyixinlu/p/12610208.html