在Ubuntu(Gnome桌面)设置StarDict词典的开启快捷键

因为没找到 StarDict 的快捷打开/隐藏键,每次都要用鼠标点,觉得很不爽,于是找了一下,发现有个命令行版本,使用 StarDict 的词库。

1
2
3
4
5
6
7
8
9
10
11
12
13
sudo apt install sdcv

$ sdcv -h
sdcv - console version of StarDict.
Usage: sdcv [OPTIONS] words
-h, --help display this help and exit
-v, --version display version information and exit
-l, --list-dicts display list of available dictionaries and exit
-u, --use-dict bookname for search use only dictionary with this bookname
-n, --non-interactive for use in scripts
--utf8-output output must be in utf8
--utf8-input input of sdcv in utf8
--data-dir path/to/dir use this directory as path to stardict data directory

然后在Ubuntu设置中找到 键盘 -> 快捷键 -> 自定义快捷键 ,添加一个快捷键命令: gnome-terminal --command sdcv ,即可通过快捷键启动一个终端查词了

词典界面如下:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
请输入单词或短语:苹果
Found 1 items, similar to 苹果.
-->朗道汉英字典5.0
-->苹果

apple
【医】 apple
相关词组:
苹果饼
苹果布丁
苹果酱
苹果酒
苹果渣
苹果汁
酸苹果
野生苹果

请输入单词或短语:Apple
Found 2 items, similar to Apple.
-->牛津现代英汉双解词典
-->apple

/ˈæpl; `æpl/ n 1 (a) round fruit with firm juicy flesh and green, red or yellow skin when ripe 苹果: [attrib 作定语] an apple pie 苹果馅饼 * apple sauce 苹果酱. =>illus at fruit 见fruit之插图. (b) (also `apple tree) tree bearing this fruit 苹果树. 2 (idm 习语) an/the ,apple of `discord (fml 文) cause of an argument or a quarrel 争端; 祸根. the ,apple of sb's `eye person or thing that is loved more than any other 心爱的人或物; 掌上明珠: She is the apple of her father's eye. 她是父亲的掌上明珠. in ,apple-pie `order very neatly arranged 井然有序.

-->朗道英汉字典5.0
-->apple

*['æpl]
n. 苹果, 家伙
【医】 苹果

请输入单词或短语

参考:http://liunian.info/tag/stardict(小居)

Author

calvinche

Posted on

2017-04-20

Licensed under

CC BY-NC-SA 4.0

Your browser is out-of-date!

Update your browser to view this website correctly.&npsb;Update my browser now

×