||10 months ago|
|plugin||10 months ago|
|syntax||10 months ago|
|COPYING||3 years ago|
|CoC.md||3 years ago|
|README.md||10 months ago|
|look-up.png||7 years ago|
look-up - vim-plugin for sdcv
Copyright (C) 2009-2015, Maksim Likhachev, <firstname.lastname@example.org> This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public Licence as published by the Free Software Foundation, either version 3 of the Licence, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public Licence for more details. You should have received a copy of the GNU General Public Licence along with this program. If not, see <http://www.gnu.org/licenses/>.
This script looks up a word under cursor in a dictionary using custom utility such as sdcv (console version of StarDict program) and store the word into text file with extension ".dict" in current directory (optionally).
Put this file into your $HOME/.vim/plugin directory (our use Pathogen/Vundle/etc) and configure your own keymaps.
> nmap fw :call Dict(expand("<cword>"))<CR> > vnoremap fw :call Dict(@*)<CR>
The next two option set sdcv's command line and enables saving the words into file:
> let g:sdcv_cmd = "sdcv -n " > let g:sdcv_save = 1