# 首选项

- StarDict Manual V3.0.2

To configure StarDict, click the Preferences button at the right-bottom corner of the Main window or click the Main menu button and choose Preferences.

- 4.1.词典
- 4.2.Network
- 4.3.主窗口
- 4.4.通知栏图标
- 4.5.浮动窗口

## 4.1.词典

- 4.1.1.选中区取词
- 4.1.2.字体
- 4.1.3.Cache
- 4.1.4.Export
- 4.1.5.音效
- 4.1.6.Video
- 4.1.7.Article rendering

### 4.1.1.选中区取词

Only scan while modifier key is being pressed.

  Only do scanning while the modifier key being pressed. The modifier key is set by the Scan modifier key option.

  默认：否。

Hide floating window when modifier key released.

  When this option is set, the Floating window is hidden when user releases the modifier key. Note: the window is hidden only if the pointer has the same position it had when the window was shown. In addition to hiding the window, the last selected text is forgotten, which allow you to lookup the same text again simply pressing the modifier key. When this option is not set, releasing the modifier key has no effect on the Floating window.

  This option has effect only if Only scan while modifier key is being pressed. is checked.

  默认：是。

Scan modifier key

  This option allows to choose a modifier keys or a key combination that enables scanning.

  This option has effect only if Only scan while modifier key is being pressed. is checked.

  Default key: Win (depends on StarDict edition).

Scan clipboard.

  Enables Clipboard scanning. If enabled, when new text is copied into the clipboard, StarDict lookup the text into the Floating window.

  This option is only available in Windows edition of StarDict.

  默认：否。

Scan mode shortcut

  The Scan mode shortcut enables or disables the Scan mode. Check the Use scan hotkey checkbox to enable this shortcut. You may change the shortcut in the field to the right of the label. Click inside the field and press the key combination you want to assign to this action.

  Default: TRUE

  Default shortcut: Ctrl+Alt+x.

### 4.1.2.字体

使用自定义的字体。

  Allows you to override the system's default for StarDict. If this option is turned on, the font selelected in the Dictionary font option will be used instead of the system font.

  Font settings apply immediately.

  默认：否。

### 4.1.3.Cache

Create cache files to speed up loading.

  Opening a dictionary the first time, StarDict does some calculations to access dictionary contents speedily. StarDict may save the results in special cache files that will be used the next time StarDict starts. With cache files StarDict starts quicker, since it does not need to do the same calculations again. It's highly recommended to enable caching. In the first place, StarDict tries to save a cache file along with the dictionary. If it fails, for example, because the directory is write-protected, StarDict creates a file under the user home directory, in StarDict's directory.

  默认：是。

Sort word list by collation function.

  Normally, StarDict uses an index of words to look up a word in a dictionary. When the word is present in the index, the corresponding article is shown. Otherwise adjacent words will be checked and may be used as result. StarDict uses heuristic algorithms to decide whether the particular word may be suggested as result of the search or not. The order of words in an index is very important and it would be handy if index items were sorted by alphabet or according to other rules. Collation functions allows you to specify a number of predefined sorting orders, that may be helpful when working with particular languages.

  To use a collation function check the Sort word list by collation function checkbox and select the desired function from the Collation function list. The collation function will be applied as soon as you close the Preferences dialog. It may take a considerable amount of time to apply the new collation function, please, be patient.

  It's highly recommended to enable the Create cache files to speed up loading. option, otherwise StarDict will do sorting each time the application starts.

  默认：否。

Clean all cache files

  Remove all StarDict cache files.

### 4.1.4.Export

StarDict may export search results into a file. You have two options: export only the found word or export the entire search result, the contents of the Definition area.

Only export words.

  When this option is set, StarDict exports only the found word, otherwise exports the complete article.

  默认：是。

File name

  Name of the file where to export data.

### 4.1.5.音效

There are a number of cases when StarDict needs to play sound files. StarDict may accompany GUI actions with sounds. StarDict may pronounce the words you search in the dictionary. Some articles may contain linked sound files you can play.

To play sound files StarDict may harness platform-specific services or use commands you specify on this page.

This page allows to configure some aspects of the TTS subsystem. The TTS subsystem is used to pronounce words by computer.

开启音效事件。

  Whether to enable sound events. StarDict will play sound event when button is active, released, and when a menu pops up.

  默认：是。

Command for playing sound files:

  Specifies a command for playing sound files. You may specify a program name (with or without full path) accompaned with any options required. The file name to play will be appended to this command at run time.

Always use sound play command

  On some platforms StarDict use platform-specific services to play sound files first, then retreats to the custom command provided by the user if the service is unable to play the file. You may specify to always use the custom command selecting this option.

  默认：否。

RealPeopleTTS search path:

  Allows to specify locations of RealPeopleTTS bundles. RealPeopleTTS bundle is a collection of sound files containing speech samples performed by real people. Normally, one file contains one recoded word, the file is named after that word. Sound files are organized into a number of directories. In the text field you must specify a path to the top level directory of the bundle. The order of paths in the text field is important. StarDict checks directories from top to bottom, the first found file will be used.

  Default:
  In Windows edition of StarDict

    C:\Program Files\WyabdcRealPeopleTTS, C:\Program Files\OtdRealPeopleTTS, WyabdcRealPeopleTTS, OtdRealPeopleTTS

  In other editions of StarDict

    /usr/share/WyabdcRealPeopleTTS, /usr/share/OtdRealPeopleTTS

Enable TTS program.

  Allows to use the command below to read words. You need to restart StarDict for changes to take effect.

  默认：否。

TTS Command line:

  This field allows to specify a command to use to pronounce words. You need to provide a print-like string, with "%s" specifing the place where the word (or phrase) to pronounce will be inserted. You need to restart StarDict for changes to take effect. Do not forget to check the checkbox above if you want to use this command.

  Default: nothing.

### 4.1.6.Video

Command for playing video files:

  Specifies a command for playing video files. You may specify a program name (with or without full path) accompaned with any options required. The file name to play will be appended to this command at run time. Video files may be linked with dictionary articles.

### 4.1.7.Article rendering

Highlight search term

  Whether to highlight the search term in the Definition area. A search term is a word that was found in dictionaries, a head word of an article.

  默认：否。

## 4.2.Network

- 4.2.1.Net Dict
- 4.2.2.Web browser

### 4.2.1.Net Dict

StarDict may look up words in network dictionaries using a custom StarDict network protocol. This configuration page allows you to register an account, select a server to use, and specify other related parameters.

Enable network dictionaries

  Enables to use network dictionaries. You need to specify the dictionaries to use in the Manage Dictionaries dialog if you enable this option.

  默认：是。

### 4.2.2.Web browser

StarDict may need to open a web link to start Internet search, show StarDict project website, show a web page to download new dictionaries, new version of the application and for other reasons. This configuration page allows to specify how a web link should be opened.

Command for opening URLs

  This option allows you to specify a command to use for opening URLs. Some editions of StarDict use platform-specific services for opening URLs by default. To use the custom command you need to check the checkbox below. For other editions of StarDict the custom command is the only way to open a web link.

  You may specify a program name (with or without full path) accompaned with any options required. The URL to open will be appended to this command at run time.

  Default: firefox (depends on edition).

Always use this command for opening URLs.

  This option is only available in editions of StarDict that can use other ways to open a web link.

  Check this option to use the custom command to open web links instead of platform-specific services.

  默认：否。

## 4.3.主窗口

- 4.3.1.Input
- 4.3.2.选项
- 4.3.3.Search website

### 4.3.1.Input

Search while typing

  When this option is checked, StarDict search for the word you are typing in the search field automatically. StarDict monitors key-press events, it starts searching the word entered as soon as there is no activity for more than a specified amount of time. The time span can be changed in the field below.

  When this option is not checked, you need to press Enter in order for StarDict to start searching the word.

  Default: TRUE

Word change timeout

  A word change timeout in milliseconds. See the option above for details.

  Default: 300 ms

Show the first word when not found.

  When StarDict is unable to find the exact word requested, the application may propose another word that is close to the original. When this option is checked, the closest word will be shown in the Definition area, otherwise, StarDict tells that the original word is not found. Note, that this option applies to simple queries only, that is the queries that do not use regular expressions, patterns, fuzzy matchs and so on.

  Default: TRUE

### 4.3.2.选项

Skin

  Allows to customize graphical appearance of the application. Select the Default item to restore the original appearance of StarDict, no skins applied. You need to restart the application in order for changes to take effect. For instructions on how to prepare a custom skin see the doc/Skins file in StarDict sources.

  Default: Default.

启动星际译王时隐藏主窗口。

  Controls whether the Main window appears when you first start the program. If you select this option, you will only see the Notification area icon after starting StarDict. You may still get to the Main window by clicking on this icon.

  默认：否。

Use open main window hotkey

  This option enable the hotkey that opens the Main window, and allows to change that hotkey. When enabled, when user presses the hotkey, the Main window is presented to the user.

  默认：是。

  Default hotkey: Ctrl+Alt+z

Transparency

  Allows to make the Main window transparent. Moving the slider you may change transparency degree. Transparency is measured in percents, it can range from 0 to 80, where 0 ‒ fully opaque, 80 ‒ almost fully transparent. Moving the slider has an immediate effect on the window.

  On X11 this has any effect only on X screens with a compositing manager running. On Windows it should work always.

  Default: 0 ‒ fully opaque.

### 4.3.3.Search website

StarDict may use Web search engines, Web dictionaries, databases providing web-based interface and other web sites providing information by request. The text to search is incorporated into URL. Normally, the text is assigned to a GET request parameter. For example, to search for word stardict in Google search engine you may use the following URL http://www.google.com/search?q=stardict. You can search websites in StarDict right-clicking the Internet search button in the Main window.

StarDict does not handle the web request itself, it only composes a URL and invokes an external program like a web browser or use platform-specific services to open the URL.

On this page you may see a list of websites. Use Add and Remove buttons to add new sites and remove existing records. Use Up and Down arrow buttons to reorder records in the list. Each record consists of three items:

Website record

Website name

  This is a label you see in menu. Use a meaningful name.

Website link

  Link to the main page of the website. This link is opened when there is nothing to search for, the Search field is empty.

Website search link

  Link to perform request. %s identifies the place where to insert the search text. For example, http://www.google.com/search?q=%s.

## 4.4.通知栏图标

- 4.4.1.选项

### 4.4.1.选项

When middle mouse button is clicked:

  Specifies an action to perform when user clicks the middle mouse button on the Notification area icon. There are the following choices:

  - Query selection in floating window
  - Query selection in main window
  - Do nothing

  In the Do nothing case StarDict simply ignores middle button clicks, otherwise StarDict get text of the current selection, search for it and displays the results either in the Floating window or in the Main window.

  In case there are a number of windows on desktop having text selected, there might be a confusion what text will be used. StarDict works with the X Primary selection. Only one application can own a selection at a time, so when you select something in an application that application becomes the selection owner, the previous owner loses selection ownership. Now back to the question. StarDict will use the text that was selected last.

  Default: Query selection in floating window.

## 4.5.浮动窗口

- 4.5.1.选项
- 4.5.2.Settings

### 4.5.1.选项

Pronounce the word when it pops up.

  When set, pronounce the word when the Floating window shows translation.

  默认：否。

Show floating window if word not found.

  This option allows to configure what to do if the word to be shown in the Floating window is not found. You have two choices: 1) do not show the Floating window at all ‒ this option is unset, 2) show the Floating window with text indicating that the word was not found ‒ this option is set.

  默认：是。

### 4.5.2.Settings

最大窗口宽度。

  Sets the Floating window's max width.

  默认：320。

最大窗口高度。

  Sets the Floating window's max height.

  默认：240。

Use custom background color:

  Enables to use custom color for background in the Floating window and select that color.

  默认：否。

Transparency

  Allows to make the Floating window transparent. Moving the slider you may change transparency degree. Transparency is measured in percents, it can range from 0 to 80, where 0 ‒ fully opaque, 80 ‒ almost fully transparent. Moving the slider has an immediate effect on the window.

  On X11 this has any effect only on X screens with a compositing manager running. On Windows it should work always.

  Default: 0 ‒ fully opaque.