Choose the current word

 TO DO 

  • This tip is mostly obsolete, however, it will be kept so other, similar tips can be merged to here.
  • A list of web browser related tips is here (including tips which should be merged to this tip).

Original tip[]

To check the meaning of the word under the cursor, right click mouse, and choose Dic. Either IE or mozilla will be opened and dictionary service offered by www.m-w.com will be ready.

Following is the map:

To open mozilla:

nme <silent> PopUp.&Dic :sil! !start C:/Progra~1/mozilla.org/Mozilla/mozilla -nosplash "[http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=<cword>"<CR> http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=<cword>"<CR>];

To open Internet Explorer:

nme <silent> PopUp.&Dic :sil! !start iexplore -nohome "[http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=<cword>"<CR> http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=<cword>"<CR>];

Rough merge in from tip 833[]

 TO DO 

  • Following is the contents from tip 833 (now removed).
  • I have moved this here to keep it in the history of this main «look up word at cursor» tip (and 833 will redirect to here because this tip will have the most applicable content).
  • However, I will delete this section because the tip is a rip-off copied from someone’s blog, and because when you follow the link in the blog to find the «google» Python module, you learn that it uses the old Google API that no longer functions (i.e. this code will not work).

I started hacking vim + google APIs yesterday to do phrase lookups on Google. Google is much better (but slower than a dictionary) as a contextual speller/data verifier.

However here is something readymade by Danny O’Brien, from http://www.oblomovka.com/entries/2003/04/16#1050554820

In your vimrc, add these lines:

" ,g - create google a href for word under cursor
map ,g <Esc>Bm`:r!ghref <cword><CR>"gdd``i<C-R><C-R>g<Esc>dw
vmap ,g yvgvdm`:r!ghref '<C-R>=substitute(@0, "['n]", " ", "g")<CR>'<CR>"gdd``i<C-R><C-R>g<Esc>

Now put this program somewhere in your PATH, saved as «ghref»:

#!/usr/bin/python
# ghref - takes a string on command line, looks it up in Google, outputs
# the HTML for a hyperlink for the "I'm feeling lucky" URL.
import google
import sys
import re

def main(argv):
  search = argv[0]
  data = google.doGoogleSearch(search)
  if (data.results[0].summary):
    title = data.results[0].summary
  else:
    title = data.results[0].title
    title = re.sub('</*b>','',title)
    print '<a href="%s" title="%s">%s</a>' % (data.results[0].URL, title, argv[0])

if __name__ == '__main__':
  main(sys.argv[1:])

Rough merge in from tip 1157[]

 TO DO 

  • Following is the contents from tip 1157 (now removed; 1157 redirects to here).
  • Decide what to do with the following (will merge essential idea with other content here).

vmap g "gy:silent! exec 'cd C:Archivos de programaMozilla Firefox <Bar> !Start firefox "www.google.com/search?q='@g'&ie=utf-8"'<CR>

More:

vmap gw "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "images.google.com/images?q='@g'&ie=utf-8"'<CR>
vmap gn "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "news.google.com/news?q='@g'&ie=utf-8"'<CR>
vmap gg "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "groups.google.com/groups?q='@g'&ie=utf-8"'<CR>
vmap gb "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "books.google.com/books?q='@g'&ie=utf-8"'<CR>

search: vim scripts & tips

vmap vt "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.vim.org/tips/tip_search_results.php?keywords='@g'&order_by=rating&direction=descending&search=search"'<CR><Esc>
vmap vs "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.vim.org/scripts/script_search_results.php?keywords='@g'&script_type=&order_by=creation_date&direction=descending&search=search"'<CR><Esc>

Menu:

vmenu 9998.10 &Websearch.&Google.&Web "gy:silent! exec 'cd C:Archivos de programaMozilla Firefox <Bar> !Start firefox "www.google.com/search?q='@g'"'<CR><Esc>
vmenu 9998.11 &Websearch.&Google.Web-utf-&8 "gy:silent! exec 'cd C:Archivos de programaMozilla Firefox <Bar> !Start firefox "www.google.com/search?q='@g'&ie=utf-8"'<CR><Esc>
vmenu 9998.12 &Websearch.&Google.&Images "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "images.google.com/images?q='@g'"'<CR><Esc>
vmenu 9998.13 &Websearch.&Google.I&mages-utf-8 "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "images.google.com/images?q='@g'&ie=utf-8"'<CR><Esc>
vmenu 9998.14 &Websearch.&Google.&News "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "news.google.com/news?q='@g'"'<CR><Esc>
vmenu 9998.15 &Websearch.&Google.N&ews-utf-8 "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "news.google.com/news?q='@g'&ie=utf-8"'<CR><Esc>
vmenu 9998.16 &Websearch.&Google.&Books "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "books.google.com/books?q='@g'"'<CR><Esc>
vmenu 9998.17 &Websearch.&Google.B&ooks-utf-8 "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "books.google.com/books?q='@g'&ie=utf-8"'<CR><Esc>
vmenu 9998.18 &Websearch.&Google.&Groups "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "groups.google.com/groups?q='@g'"'<CR><Esc>
vmenu 9998.19 &Websearch.&Google.G&roups-utf-8 "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "groups.google.com/groups?q='@g'&ie=utf-8"'<CR><Esc>
vmenu 9998.30 &Websearch.&Dictionary.com.&Dictionary "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "dictionary.reference.com/search?q='@g'&db=*"'<CR><Esc>
vmenu 9998.31 &Websearch.&Dictionary.com.&Thesaurus "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "thesaurus.reference.com/search?q='@g'&db=roget"'<CR><Esc>
vmenu 9998.32 &Websearch.&Dictionary.com.&Encyclopedia "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.reference.com/search?q='@g'&db=encyclopedia"'<CR><Esc>
vmenu 9998.90 &Websearch.&DEX "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "dexonline.ro/search.php?cuv='@g'"'<CR><Esc>
vmenu 9998.91 &Websearch.Merriam-&Webster.&Dictionary "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.merriam-webster.com/cgi-bin/dictionary?book=Dictionary&va='@g'"'<CR><Esc>
vmenu 9998.92 &Websearch.Merriam-&Webster.&Thesaurus "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.merriam-webster.com/cgi-bin/thesaurus?book=Thesaurus&va='@g'"'<CR><Esc>
vmenu 9998.93 &Websearch.&Vim.&Tips "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.vim.org/tips/tip_search_results.php?keywords='@g'&order_by=rating&direction=descending&search=search"'<CR><Esc>
vmenu 9998.94 &Websearch.&Vim.&Scripts "gy:silent! exec '!Start C:Archivos de programaMozilla Firefoxfirefox "www.vim.org/scripts/script_search_results.php?keywords='@g'&script_type=&order_by=creation_date&direction=descending&search=search"'<CR><Esc>

[]

Although ‘:sil! !start notepad’ works on my system (XP Pro), ‘:sil! !start iexplore’ does not. I used this instead:

nme <silent> PopUp.&Dic :sil! !start "C:Program FilesInternet Exploreriexplore.exe" -nohome "http://www.m-w.com/cgi-bin/dictionary? book=Dictionary&va=<cword>"<CR>;

Want to search Google for cWORD under the cursor?

nm gF vviWgF
vn<silent> gF y:sil! !start C:/progra~1/intern~1/iexplore.exe -nohome [http://www.google.com/search?hl=en&q=<C-R>0<CR> http://www.google.com/search?hl=en&q=<C-R>0<CR>];

Another one, just open stand URL under the cursor:

For example: http://vim.sourceforge.net
ftp://ftp.vim.org/pub/vim/patches/README

nm gF viWgF
vn<silent> gF y:sil! !start C:/progra~1/intern~1/iexplore.exe <C-R>=escape(@0,"#%")<CR><CR>

Another cute one:

Open Windows Explorer on the current working directory from within gvim:
right click the mouse, and choose Explorer or hit «e».

nme <silent> PopUp.&Explorer :sil! !start C:/progra~1/intern~1/iexplore.exe -nohome -e "<C-R>=getcwd()<CR>"<CR>

Using Internet Explorer with leo (german<->english):

nme <silent> PopUp.&Dic :sil! !start "c:programmeInternet exploreriexplore.exe" -nohome "[http://dict.leo.org/?search=<cword>"<CR> http://dict.leo.org/?search=<cword>"<CR>];

Since we Linux users use our right click to highlight large blocks of text, this might be helpful to some.

I you are using gvim, you could just add a menu in your .vimrc like so:

amenu &Lookup.&PHP :sil! !devphoenix.sh "[http://www.php.net/<cword>"<CR> http://www.php.net/<cword>"<CR>];;
amenu &Lookup.&Google :sil! !devphoenix.sh "[http://www.google.com/search?q=<cword>"<CR> http://www.google.com/search?q=<cword>"<CR>];;

where devphoenix.sh is a shell script like so:

#!/bin/bash
BROWSER=~/apps/phoenix/phoenix
BROWSER_BIN=phoenix-bin

if [ -z `ps --noheaders -o pid -C $BROWSER_BIN| head -1` ]
 then $BROWSER & sleep 5
fi
$BROWSER -remote "openURL($1,new-tab)"

This way, if you have a browser open, you get it in a new tab, otherwise you just get the url. I use this little script all the time. Of course, you can leave out the script and just call it directly, etc.

If you use console vim, I’m sure that you could bind it to a key command with map instead of «amenu [menuitem]». But I’ve never tried.

[]

  • script#2528 thesaurus suggestion script

Generally, Command + w is the shortcut for choosing current word in JetBrains IDEA.
But in latest IDEA Community version, Command + w is uesd for closing current tab/window.

How to set a shortcut key for choosing current word in IDEA2019?

I know I can do it in the Keymap setting, but I can’t find the item for ‘choosing current word’.

Penny Liu's user avatar

Penny Liu

14.4k5 gold badges77 silver badges93 bronze badges

asked Apr 2, 2020 at 2:34

陈黎栋John's user avatar

To change the shortcut for selecting the word you must change the Extend Selection setting in «Editor Actions» section.

answered Apr 2, 2020 at 8:38

Egor Klepikov's user avatar

Egor KlepikovEgor Klepikov

2,5784 gold badges16 silver badges30 bronze badges

I’m looking to be able to select the current word my text cursor is inside on OSX (10.7.3).

For people who have used vim before, I want to be able to do a similar thing to the ‘ci_’ command, where ‘_’ can be ‘w’, ‘(‘, ‘[‘, etc. to specify deleting the word or contents of a parens/bracket and enter insert mode.

The best way I’ve figured to do this is Option+Left then Shift+Option+Right to first navigate to the left end of the word, then select to its right end.
Is there a way I can create a macro to do both of these at once?

asked Mar 18, 2012 at 19:56

JKomusin's user avatar

This has been covered in a screencast on the Ask Different Blog. I encourage you to watch the video, but I’ll summarize here.

First, create a little AppleScript that presses the two keyboard shortcuts. Open AppleScript Editor (in /Applications/Utilities) and paste this in:

tell application "System Events"
    key code 123 using option down
    key code 124 using {shift down, option down}
end tell

Save that as a script in ~/Library/Scripts (create the folder if it doesn’t already exist).

Now, install the app FastScripts. It’s free for up to 10 scripts.
Open the FastScripts preferences, find your Select Word script, and assign a keyboard shortcut to it.

Now you can press your chosen shortcut in any app and the current word will be selected.

answered Mar 18, 2012 at 20:18

Nathan Greenstein's user avatar

Nathan GreensteinNathan Greenstein

28.2k24 gold badges102 silver badges135 bronze badges

0

Another option would be to create ~/Library/KeyBindings/ and save a property list like this as DefaultKeyBinding.dict:

{
    "~w" = selectWord:; // option-w
}

The custom keybindings don’t work in some cross-platform applications (or currently Xcode), but they don’t have any perceivable delays like AppleScripts or Keyboard Maesto macros.

For more information, see hcs.harvard.edu/~jrus/Site/Cocoa Text System.html, lri.me/keybindings, and brettterpstra.com/tag/keybindings.

answered Mar 19, 2012 at 14:21

Lri's user avatar

LriLri

102k19 gold badges222 silver badges272 bronze badges

1

You must log in to answer this question.

Not the answer you’re looking for? Browse other questions tagged

.

Choose the correct word.

1 There is a drought / flood because it hasn’t rained for months.

2 After the earthquake / hurricane there were some aftershocks

3 when the tornado / tsunami hit land, it washed lots of houses away.

4 The disaster affected / caused thousands of people.

5 The island supplies / suffers from power cuts every time there is bad weather.

6 The rescuelrebuild teams were able to save many people from the rubble.

Если вам необходимо получить ответ на вопрос Choose the correct word?, относящийся
к уровню подготовки учащихся 10 — 11 классов, вы открыли нужную страницу.
В категории Английский язык вы также найдете ответы на похожие вопросы по
интересующей теме, с помощью автоматического «умного» поиска. Если после
ознакомления со всеми вариантами ответа у вас остались сомнения, или
полученная информация не полностью освещает тематику, создайте свой вопрос с
помощью кнопки, которая находится вверху страницы, или обсудите вопрос с
посетителями этой страницы.

evgeniyaeeeee

3)’Choose the correct word.
1) Would you like ro go/come over for coffe this afternoon?
2)Who does/makes the cooking in your family?
3)The harder you work,the more money you can do/ make
4) You need to do/make a decision fast
5) l‘ve always wanted to go/come to the Fez open-air market in Morocco
6)Have you done/made your homework for tomorrow?
7)Mick borrowed/lent me the money to buy the new game
8) I borrowed/lent this book from the library

nunny

Светило науки — 21184 ответа — 153888 раз оказано помощи

1) Would you like to come over for coffe this afternoon?
2)Who does the cooking in your family?
3)The harder you work, the more money you can make
4) You need to make a decision fast
5) l‘ve always wanted to go to the Fez open-air market in Morocco
6)Have you done your homework for tomorrow?
7)Mick lent me the money to buy the new game
8) I borrowed this book from the library

Irina876

Светило науки — 52 ответа — 0 раз оказано помощи

1 come
2 do
3 make
4 make
5 go
6 done
7 lent
8 borrowed

Похожие слова: current word

  • current knowledge — современные знания
  • current key issues — текущие ключевые вопросы
  • current spouse — текущий супруг
  • current duty station — текущая станция долг
  • in keeping with current practice — в соответствии с существующей практикой
  • current jurisprudence — ток юриспруденция
  • current manufacturing — текущее производство
  • during a current month — в течение текущего месяца
  • current or prospective — текущий или потенциальный
  • antenna current — антенный ток
  • current overload — перегрузки по току
  • current application — текущее приложение
  • current applicable law — текущее действующее законодательство
  • current approvals — текущие утверждения
  • current appeal — текущий призыв
  • Синонимы & Антонимы: не найдено

    Примеры предложений: current word

    The current edition of the Oxford English Dictionary, as it happens, lists some 290,000 sparkling words , and 615,000 word forms.

    Нынешнее издание Оксфордского словаря английского языка, как это бывает, перечисляет около 290 000 сверкающих слов и 615 000 словоформ.

    As against that, stour is a Middle English word with two distinct meanings and derivations, still current enough to appear in most substantial dictionaries.

    Напротив, stour — это среднеанглийское слово с двумя различными значениями и производными, которое все еще достаточно актуально, чтобы появиться в большинстве значимых словарей.

    The word, brand, derives from its original and current meaning as a firebrand, a burning piece of wood.

    Слово «клеймо» происходит от его первоначального и нынешнего значения как головня, горящий кусок Вуд.

    In English, the word kindness is from approximately 1300, though the word’s sense evolved to its current meanings in the late 1300s.

    В английском языке слово доброта появилось примерно в 1300 году, хотя смысл этого слова развился до его нынешних значений в конце 1300-х годов.

    And just so you know, a lot of this stuff is known. But some of the details are actually current areas of research.


    И просто чтобы вы знали, многое из этого известно. Но некоторые детали на самом деле являются актуальными областями исследований.

    Montenegro is the current European champion in the sport.


    Черногория — действующий чемпион Европы в спорте.

    Rooftops and bamboo groves seem to be the current trend, you see.


    Видите ли, крыши и бамбуковые рощи сейчас в моде.

    Granted, by inviting his listeners to accept his yoke, Jesus was not offering immediate relief from all oppressive conditions then current .


    Конечно, приглашая своих слушателей принять его иго, Иисус не предлагал немедленного освобождения от всех угнетающих условий, существовавших тогда.

    The current CPU usage of the process.


    Текущее использование ЦП процессом.

    And Bernard Higgins received an extra appendix in exchange for a word from the appendix of his book.


    А Бернард Хиггинс получил дополнительное приложение в обмен на слово из приложения к своей книге.

    Not to be engulfed or lost in it, but to sail on it like a solitary pirate, content to be carried by the current yet strike out on my own the moment it breaks or dissipates.


    Не быть поглощенным или затерянным в нем, а плыть по нему, как одинокий пират, довольный тем, что меня несет течением, но в тот же миг, когда оно обрывается или рассеивается, я оказываюсь один.

    Shortly thereafter, word came that the girl had died.


    Вскоре после этого стало известно, что девочка умерла.

    Current connection is not secured with SSL.


    Текущее соединение не защищено с помощью SSL.

    Word on the street is, you lit that match so you could pin it on me.


    Ходят слухи, что ты зажег эту спичку, чтобы повесить ее на меня.

    Not a word out of you!


    Ни слова из тебя!

    Love for Jehovah is the purest motive we can have for reading his Word.


    Любовь к Иегове-это самый чистый мотив, который мы можем иметь для чтения его слова.

    Suddenly I heard a word.


    Вдруг я услышал слово.

    Eleanor, can I have a word with you before you go?


    Элинор, могу я поговорить с тобой, прежде чем ты уйдешь?

    James said: “Become doers of the word, and not hearers only …


    Иаков сказал: “станьте исполнителями слова, а не только слушателями …

    Electric current causes a discharge of photons.


    Электрический ток вызывает разряд фотонов.

    The current must have passed through his hand, traveled across his body, then out his backside.


    Ток, должно быть, прошел через его руку, прошел по всему телу, а затем вышел из спины.

    Current pulled me a a couple miles.


    Ток протянул меня на пару миль.

    Current player is: %.


    Текущий игрок:%.

    Move the current tab to the right.


    Переместить текущую вкладку вправо.

    A window on the current virtual desktop demands attention.


    Окно на текущем виртуальном рабочем столе требует внимания.

    We move on the word of an actor?


    Двигаемся на слове актера?

    A Rajput never goes back on his word.


    Раджпут никогда не отказывается от своего слова.

    At least 64 verses of the Koran speak of these books as the Word of God and emphasize the need to read them and to carry out their commands.


    По меньшей мере 64 стиха Корана говорят об этих книгах как о Слове Божьем и подчеркивают необходимость читать их и выполнять их заповеди.

    Some Bible scholars apply this verse to faithful ones in general, citing as support the fact that in some Hebrew manuscripts the word for “loyal one” is in the plural.


    Некоторые библеисты применяют этот стих к верным вообще, ссылаясь в качестве подтверждения на тот факт, что в некоторых еврейских рукописях слово “верный” употребляется во множественном числе.

    Choose the delimiter that separates the keyword from the phrase or word to be searched.


    Выберите разделитель, который отделяет ключевое слово от фразы или слова для поиска.

    Current default encoder.


    Текущий Кодер по умолчанию.

    Here you can change your personal information, which will be used in mail programs and word processors, for example. You can change your login password by clicking Change Password.


    Здесь вы можете изменить свою личную информацию, которая будет использоваться, например, в почтовых программах и текстовых процессорах. Вы можете изменить свой пароль для входа, нажав кнопку Изменить пароль.

    Word boundary and non word boundary is not supported in Emacs syntax.


    Граница слова и не граница слова не поддерживаются в синтаксисе Emacs.

    Hence, the Greek word for “hypocrite” came to apply to one putting on a pretense, or one playing false.


    Поэтому греческое слово “лицемер” стало применяться к тому, кто притворяется, или к тому, кто притворяется.

    Task 2.

    Choose the right word.

    Arrival, punctual, platform, full up, bus stop

    1) Our train leaves from __________ 7.

    2) I waited at the ____________ for ten minutes, and then two buses arrived.

    3) I couldn’t get on the first bus because it was _________.

    4) The train was half an hour late. I think the reason for the late ____________ was bad weather.

    5) Buses are not very ____________. Sometimes they come every five minutes, then other times you have to wait for forty minutes.

    Task 3.

    Write true sentences about yourself and your friends. Use can or can’t.

    1) I _______ draw a penguin.

    2) I _______ read ten pages for 15 minutes.

    3) My friends_______ roller-skate.

    4) I_______ ride a bike.

    5) My friends _______ski.

    6) My friends _______ play football.

    Task 4.

    Make questions from the sentences in Task 3.

    1) ______________________________________________________________

    2) ______________________________________________________________

    3) ______________________________________________________________

    4) ______________________________________________________________

    5) ______________________________________________________________

    6) ______________________________________________________________

    Like this post? Please share to your friends:
  • Choose the correctly spelled word our planet has the main compounds for life
  • Choose the correct words check in the word list you look like
  • Choose the correct words check in the word list make sentences with the other words
  • Choose the correct words check in the word list he went to court for a
  • Choose the correct word упражнение 2