blob: 5fc1dd82d5656ce416d813d7b59fea7f971c70a9 [file] [log] [blame]
Bram Moolenaar0dc065e2005-07-04 22:49:24 +00001*spell.txt* For Vim version 7.0aa. Last change: 2005 Jul 04
Bram Moolenaar217ad922005-03-20 22:37:15 +00002
3
4 VIM REFERENCE MANUAL by Bram Moolenaar
5
6
7Spell checking *spell*
8
91. Quick start |spell-quickstart|
Bram Moolenaard042c562005-06-30 22:04:15 +0000102. Remarks on spell checking |spell-remarks|
113. Generating a spell file |spell-mkspell|
124. Spell file format |spell-file-format|
Bram Moolenaar217ad922005-03-20 22:37:15 +000013
14{Vi does not have any of these commands}
15
16Spell checking is not available when the |+syntax| feature has been disabled
17at compile time.
18
19==============================================================================
201. Quick start *spell-quickstart*
21
22This command switches on spell checking: >
23
24 :setlocal spell spelllang=en_us
25
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +000026This switches on the 'spell' option and specifies to check for US English.
Bram Moolenaar217ad922005-03-20 22:37:15 +000027
28The words that are not recognized are highlighted with one of these:
Bram Moolenaar520470a2005-06-16 21:59:56 +000029 SpellBad word not recognized |hl-SpellBad|
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +000030 SpellCap word not capitalised |hl-SpellCap|
Bram Moolenaar520470a2005-06-16 21:59:56 +000031 SpellRare rare word |hl-SpellRare|
32 SpellLocal wrong spelling for selected region |hl-SpellLocal|
Bram Moolenaar217ad922005-03-20 22:37:15 +000033
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +000034Vim only checks words for spelling, there is no grammar check.
35
36To search for the next misspelled word:
37
38 *]s* *E756*
39]s Move to next misspelled word after the cursor.
Bram Moolenaar9d0ec2e2005-04-20 19:45:58 +000040 A count before the command can be used to repeat.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +000041
42 *[s*
Bram Moolenaar9d0ec2e2005-04-20 19:45:58 +000043[s Like "]s" but search backwards, find the misspelled
Bram Moolenaar30abd282005-06-22 22:35:10 +000044 word before the cursor. Doesn't recognize words
45 split over two lines, thus may stop at words that are
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000046 not highlighted as bad. Does not stop at word with
47 missing capital at the start of a line.
Bram Moolenaar9d0ec2e2005-04-20 19:45:58 +000048
49 *]S*
50]S Like "]s" but only stop at bad words, not at rare
51 words or words for another region.
52
53 *[S*
54[S Like "]S" but search backwards.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +000055
Bram Moolenaar217ad922005-03-20 22:37:15 +000056
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +000057To add words to your own word list: *E764*
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000058
59 *zg*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000060zg Add word under the cursor as a good word to the first
61 name in 'spellfile'. In Visual mode the selected
62 characters are added as a word (including white
63 space!). If the word is explicitly marked as bad word
64 in another spell file the result is unpredictable.
65 A count may precede the command to indicate the entry
66 in 'spellfile' to be used. A count of two uses the
67 second entry.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000068
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000069 *zG*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000070zG Like "zg" but add the word to the internal word list
71 |internal-wordlist|.
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000072
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000073 *zw*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000074zw Like "zg" but mark the word as a wrong (bad) word.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000075
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000076 *zW*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000077zW Like "zw" but add the word to the internal word list
78 |internal-wordlist|.
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000079
Bram Moolenaar520470a2005-06-16 21:59:56 +000080 *:spe* *:spellgood*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000081:[count]spe[llgood] {word}
82 Add [word} as a good word to 'spellfile', like with
83 "zg". Without count the first name is used, with a
84 count of two the second entry, etc.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000085
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000086:spe[llgood]! {word} Add [word} as a good word to the internal word list,
87 like with "zG".
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000088
Bram Moolenaar520470a2005-06-16 21:59:56 +000089 *:spellw* *:spellwrong*
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +000090:[count]spellw[rong] {word}
91 Add [word} as a wrong (bad) word to 'spellfile', as
92 with "zw". Without count the first name is used, with
93 a count of two the second entry, etc.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +000094
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +000095:spellw[rong]! {word} Add [word} as a wrong (bad) word to the internal word
96 list.
97
Bram Moolenaarf461c8e2005-06-25 23:04:51 +000098After adding a word to 'spellfile' with the above commands its associated
Bram Moolenaard042c562005-06-30 22:04:15 +000099".spl" file will automatically be updated and reloaded. If you change
100'spellfile' manually you need to use the |:mkspell| command. This sequence of
101commands mostly works well: >
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +0000102 :edit <file in 'spellfile'>
Bram Moolenaarf461c8e2005-06-25 23:04:51 +0000103< (make changes to the spell file) >
104 :mkspell! %
105
106More details about the 'spellfile' format below |spell-wordlist-format|.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000107
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +0000108 *internal-wordlist*
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +0000109The internal word list is used for all buffers where 'spell' is set. It is
110not stored, it is lost when you exit Vim. It is also cleared when 'encoding'
111is set.
112
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000113
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000114Finding suggestions for bad words:
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000115 *z?*
Bram Moolenaar30abd282005-06-22 22:35:10 +0000116z? For the word under/after the cursor suggest correctly
Bram Moolenaard042c562005-06-30 22:04:15 +0000117 spelled words. This also works to find alternatives
118 for a word that is not highlighted as a bad word,
119 e.g., when the word after it is bad.
Bram Moolenaar30abd282005-06-22 22:35:10 +0000120 The results are sorted on similarity to the word
121 under/after the cursor.
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000122 This may take a long time. Hit CTRL-C when you are
123 bored.
Bram Moolenaar24bbcfe2005-06-28 23:32:02 +0000124 This does not work when there is a line break halfway
125 a bad word (e.g., "the the").
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000126 You can enter the number of your choice or press
Bram Moolenaar24bbcfe2005-06-28 23:32:02 +0000127 <Enter> if you don't want to replace. You can also
128 use the mouse to click on your choice (only works if
129 the mouse can be used in Normal mode and when there
Bram Moolenaard042c562005-06-30 22:04:15 +0000130 are no line wraps). Click on the first (header) line
Bram Moolenaar24bbcfe2005-06-28 23:32:02 +0000131 to cancel.
Bram Moolenaarf3bd51a2005-06-14 22:11:18 +0000132 If 'verbose' is non-zero a score will be displayed to
133 indicate the likeliness to the badly spelled word (the
134 higher the score the more different).
Bram Moolenaard857f0e2005-06-21 22:37:39 +0000135 When a word was replaced the redo command "." will
136 repeat the word replacement. This works like "ciw",
137 the good word and <Esc>.
138
Bram Moolenaar24bbcfe2005-06-28 23:32:02 +0000139 *:spellr* *:spellrepall* *E752* *E753*
140:spellr[epall] Repeat the replacement done by |z?| for all matches
141 with the replaced word in the current window.
142
Bram Moolenaard857f0e2005-06-21 22:37:39 +0000143The 'spellsuggest' option influences how the list of suggestions is generated
144and sorted. See |'spellsuggest'|.
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000145
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +0000146The 'spellcapcheck' option is used to check the first word of a sentence
147starts with a capital. This doesn't work for the first word in the file.
148When there is a line break right after a sentence the highlighting of the next
149line may be postponed. Use |CTRL-L| when needed.
150
Bram Moolenaard042c562005-06-30 22:04:15 +0000151==============================================================================
1522. Remarks on spell checking *spell-remarks*
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000153
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000154PERFORMANCE
155
Bram Moolenaard042c562005-06-30 22:04:15 +0000156Vim does on-the-fly spell checking. To make this work fast the word list is
157loaded in memory. Thus this uses a lot of memory (1 Mbyte or more). There
158might also be a noticeable delay when the word list is loaded, which happens
159when 'spell' is set and when 'spelllang' is set while 'spell' was already set.
160To minimize the delay each word list is only loaded once, it is not deleted
161when 'spelllang' is made empty or 'spell' is reset. When 'encoding' is set
162all the word lists are reloaded, thus you may notice a delay then too.
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000163
164
Bram Moolenaar217ad922005-03-20 22:37:15 +0000165REGIONS
166
167A word may be spelled differently in various regions. For example, English
168comes in (at least) these variants:
169
170 en all regions
Bram Moolenaar5c5474b2005-04-19 21:40:26 +0000171 en_au Australia
Bram Moolenaar217ad922005-03-20 22:37:15 +0000172 en_ca Canada
Bram Moolenaar5c5474b2005-04-19 21:40:26 +0000173 en_gb Great Britain
174 en_nz New Zealand
175 en_us USA
Bram Moolenaar217ad922005-03-20 22:37:15 +0000176
177Words that are not used in one region but are used in another region are
Bram Moolenaar520470a2005-06-16 21:59:56 +0000178highlighted with SpellLocal |hl-SpellLocal|.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000179
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000180Always use lowercase letters for the language and region names.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000181
Bram Moolenaar3638c682005-06-08 22:05:14 +0000182When adding a word with |zg| or another command it's always added for all
183regions. You can change that by manually editing the 'spellfile'. See
Bram Moolenaar0dc065e2005-07-04 22:49:24 +0000184|spell-wordlist-format|. Note that the regions as specified in the files in
185'spellfile' are only used when all entries in "spelllang" specify the same
186region (not counting files specified by their .spl name).
Bram Moolenaar3638c682005-06-08 22:05:14 +0000187
Bram Moolenaar217ad922005-03-20 22:37:15 +0000188
Bram Moolenaar3b506942005-06-23 22:36:45 +0000189SPELL FILES *spell-load*
Bram Moolenaar217ad922005-03-20 22:37:15 +0000190
191Vim searches for spell files in the "spell" subdirectory of the directories in
Bram Moolenaar3638c682005-06-08 22:05:14 +0000192'runtimepath'. The name is: LL.EEE.spl, where:
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000193 LL the language name
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000194 EEE the value of 'encoding'
Bram Moolenaar217ad922005-03-20 22:37:15 +0000195
Bram Moolenaar3b506942005-06-23 22:36:45 +0000196The value for "LL" comes from 'spelllang', but excludes the region name.
197Examples:
198 'spelllang' LL ~
199 en_us en
200 en-rare en-rare
201 medical_ca medical
202
Bram Moolenaar3638c682005-06-08 22:05:14 +0000203Only the first file is loaded, the one that is first in 'runtimepath'. If
204this succeeds then additionally files with the name LL.EEE.add.spl are loaded.
205All the ones that are found are used.
206
Bram Moolenaar0d9c26d2005-07-02 23:19:16 +0000207Additionally, the files related to the names in 'spellfile' are loaded. These
208are the files that |zg| and |zw| add good and wrong words to.
Bram Moolenaar3b506942005-06-23 22:36:45 +0000209
Bram Moolenaar0e21a3f2005-04-17 20:28:32 +0000210Exceptions:
211- Vim uses "latin1" when 'encoding' is "iso-8859-15". The euro sign doesn't
212 matter for spelling.
213- When no spell file for 'encoding' is found "ascii" is tried. This only
214 works for languages where nearly all words are ASCII, such as English. It
215 helps when 'encoding' is not "latin1", such as iso-8859-2, and English text
Bram Moolenaar3638c682005-06-08 22:05:14 +0000216 is being edited. For the ".add" files the same name as the found main
217 spell file is used.
218
219For example, with these values:
220 'runtimepath' is "~/.vim,/usr/share/vim70,~/.vim/after"
221 'encoding' is "iso-8859-2"
222 'spelllang' is "pl"
223
224Vim will look for:
2251. ~/.vim/spell/pl.iso-8859-2.spl
2262. /usr/share/vim70/spell/pl.iso-8859-2.spl
2273. ~/.vim/spell/pl.iso-8859-2.add.spl
2284. /usr/share/vim70/spell/pl.iso-8859-2.add.spl
2295. ~/.vim/after/spell/pl.iso-8859-2.add.spl
230
231This assumes 1. is not found and 2. is found.
232
233If 'encoding' is "latin1" Vim will look for:
2341. ~/.vim/spell/pl.latin1.spl
2352. /usr/share/vim70/spell/pl.latin1.spl
2363. ~/.vim/after/spell/pl.latin1.spl
2374. ~/.vim/spell/pl.ascii.spl
2385. /usr/share/vim70/spell/pl.ascii.spl
2396. ~/.vim/after/spell/pl.ascii.spl
240
241This assumes none of them are found (Polish doesn't make sense when leaving
242out the non-ASCII characters).
Bram Moolenaar217ad922005-03-20 22:37:15 +0000243
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000244Spelling for EBCDIC is currently not supported.
245
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000246A spell file might not be available in the current 'encoding'. See
247|spell-mkspell| about how to create a spell file. Converting a spell file
Bram Moolenaar0e21a3f2005-04-17 20:28:32 +0000248with "iconv" will NOT work!
Bram Moolenaar217ad922005-03-20 22:37:15 +0000249
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000250 *E758* *E759*
251When loading a spell file Vim checks that it is properly formatted. If you
Bram Moolenaar0e21a3f2005-04-17 20:28:32 +0000252get an error the file may be truncated, modified or intended for another Vim
253version.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000254
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000255
256WORDS
257
258Vim uses a fixed method to recognize a word. This is independent of
259'iskeyword', so that it also works in help files and for languages that
260include characters like '-' in 'iskeyword'. The word characters do depend on
261'encoding'.
262
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000263The table with word characters is stored in the main .spl file. Therefore it
264matters what the current locale is when generating it! A .add.spl file does
Bram Moolenaarf461c8e2005-06-25 23:04:51 +0000265not contain a word table though.
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000266
Bram Moolenaar3638c682005-06-08 22:05:14 +0000267A word that starts with a digit is always ignored. That includes hex numbers
268in the form 0xff and 0XFF.
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000269
270
Bram Moolenaar30abd282005-06-22 22:35:10 +0000271WORD COMBINATIONS
272
273It is possible to spell-check words that include a space. This is used to
274recognize words that are invalid when used by themselves, e.g. for "et al.".
275It can also be used to recognize "the the" and highlight it.
276
277The number of spaces is irrelevant. In most cases a line break may also
278appear. However, this makes it difficult to find out where to start checking
279for spelling mistakes. When you make a change to one line and only that line
280is redrawn Vim won't look in the previous line, thus when "et" is at the end
281of the previous line "al." will be flagged as an error. And when you type
282"the<CR>the" the highlighting doesn't appear until the first line is redrawn.
283Use |CTRL-L| to redraw right away. "[s" will also stop at a word combination
284with a line break.
285
286When encountering a line break Vim skips characters such as '*', '>' and '"',
287so that comments in C, shell and Vim code can be spell checked.
288
289
Bram Moolenaar9d0ec2e2005-04-20 19:45:58 +0000290SYNTAX HIGHLIGHTING *spell-syntax*
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000291
292Files that use syntax highlighting can specify where spell checking should be
293done:
294
Bram Moolenaar3638c682005-06-08 22:05:14 +00002951. everywhere default
2962. in specific items use "contains=@Spell"
2973. everywhere but specific items use "contains=@NoSpell"
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000298
Bram Moolenaar3638c682005-06-08 22:05:14 +0000299For the second method adding the @NoSpell cluster will disable spell checking
300again. This can be used, for example, to add @Spell to the comments of a
301program, and add @NoSpell for items that shouldn't be checked.
Bram Moolenaar6bb68362005-03-22 23:03:44 +0000302
Bram Moolenaar30abd282005-06-22 22:35:10 +0000303
304VIM SCRIPTS
305
306If you want to write a Vim script that does something with spelling, you may
307find these functions useful:
308
309 spellbadword() find badly spelled word at the cursor
310 spellsuggest() get list of spelling suggestions
Bram Moolenaard042c562005-06-30 22:04:15 +0000311 soundfold() get the sound-a-like version of a word
Bram Moolenaar30abd282005-06-22 22:35:10 +0000312
Bram Moolenaar217ad922005-03-20 22:37:15 +0000313==============================================================================
Bram Moolenaard042c562005-06-30 22:04:15 +00003143. Generating a spell file *spell-mkspell*
Bram Moolenaar217ad922005-03-20 22:37:15 +0000315
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000316Vim uses a binary file format for spelling. This greatly speeds up loading
317the word list and keeps it small.
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000318 *.aff* *.dic* *Myspell*
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000319You can create a Vim spell file from the .aff and .dic files that Myspell
320uses. Myspell is used by OpenOffice.org and Mozilla. You should be able to
321find them here:
322 http://lingucomponent.openoffice.org/spell_dic.html
Bram Moolenaar30abd282005-06-22 22:35:10 +0000323You can also use a plain word list. The results are the same, the choice
Bram Moolenaard042c562005-06-30 22:04:15 +0000324depends on what word lists you can find.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000325
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +0000326If you install Aap (from www.a-a-p.org) you can use the recipes in the
327runtime/spell/??/ directories. Aap will take care of downloading the files,
328apply patches needed for Vim and build the .spl file.
329
Bram Moolenaare13305e2005-06-19 22:54:15 +0000330Make sure your current locale is set properly, otherwise Vim doesn't know what
331characters are upper/lower case letters. If the locale isn't available (e.g.,
332when using an MS-Windows codepage on Unix) add tables to the .aff file
Bram Moolenaar3b506942005-06-23 22:36:45 +0000333|spell-affix-chars|. If the .aff file doesn't define a table then the word
334table of the currently active spelling is used. If spelling is not active
335then Vim will try to guess.
Bram Moolenaare13305e2005-06-19 22:54:15 +0000336
Bram Moolenaar3b506942005-06-23 22:36:45 +0000337 *:mksp* *:mkspell*
338:mksp[ell][!] [-ascii] {outname} {inname} ...
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000339 Generate a Vim spell file word lists. Example: >
Bram Moolenaard042c562005-06-30 22:04:15 +0000340 :mkspell /tmp/nl nl_NL.words
Bram Moolenaar3b506942005-06-23 22:36:45 +0000341< *E751*
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000342 When {outname} ends in ".spl" it is used as the output
343 file name. Otherwise it should be a language name,
Bram Moolenaar3b506942005-06-23 22:36:45 +0000344 such as "en", without the region name. The file
345 written will be "{outname}.{encoding}.spl", where
346 {encoding} is the value of the 'encoding' option.
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000347
Bram Moolenaard042c562005-06-30 22:04:15 +0000348 When the output file already exists [!] must be used
Bram Moolenaar520470a2005-06-16 21:59:56 +0000349 to overwrite it.
350
Bram Moolenaar0e21a3f2005-04-17 20:28:32 +0000351 When the [-ascii] argument is present, words with
352 non-ascii characters are skipped. The resulting file
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000353 ends in "ascii.spl".
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000354
355 The input can be the Myspell format files {inname}.aff
356 and {inname}.dic. If {inname}.aff does not exist then
357 {inname} is used as the file name of a plain word
358 list.
359
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000360 Multiple {inname} arguments can be given to combine
361 regions into one Vim spell file. Example: >
362 :mkspell ~/.vim/spell/en /tmp/en_US /tmp/en_CA /tmp/en_AU
363< This combines the English word lists for US, CA and AU
364 into one en.spl file.
365 Up to eight regions can be combined. *E754* *755*
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000366 The REP and SAL items of the first .aff file where
367 they appear are used. |spell-affix-REP|
368 |spell-affix-SAL|
Bram Moolenaar217ad922005-03-20 22:37:15 +0000369
Bram Moolenaar30abd282005-06-22 22:35:10 +0000370 This command uses a lot of memory, required to find
371 the optimal word tree (Polish requires a few hundred
372 Mbyte). The final result will be much smaller.
373
Bram Moolenaard042c562005-06-30 22:04:15 +0000374 After the spell file was written and it was being used
375 in a buffer it will be reloaded automatically.
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000376
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000377:mksp[ell] [-ascii] {name}.{enc}.add
378 Like ":mkspell" above, using {name}.{enc}.add as the
Bram Moolenaard042c562005-06-30 22:04:15 +0000379 input file and producing an output file in the same
380 directory that has ".spl" appended.
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000381
382:mksp[ell] [-ascii] {name}
383 Like ":mkspell" above, using {name} as the input file
Bram Moolenaard042c562005-06-30 22:04:15 +0000384 and producing an output file in the same directory
385 that has ".{enc}.spl" appended.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000386
387Since you might want to change a Myspell word list for use with Vim the
388following procedure is recommended:
Bram Moolenaar217ad922005-03-20 22:37:15 +0000389
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +00003901. Obtain the xx_YY.aff and xx_YY.dic files from Myspell.
3912. Make a copy of these files to xx_YY.orig.aff and xx_YY.orig.dic.
3923. Change the xx_YY.aff and xx_YY.dic files to remove bad words, add missing
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000393 words, define word characters with FOL/LOW/UPP, etc. The distributed
394 "src/spell/*.diff" files can be used.
Bram Moolenaard042c562005-06-30 22:04:15 +00003954. Start Vim with the right locale and use |:mkspell| to generate the Vim
396 spell file.
3975. Try out the spell file with ":set spell spelllang=xx" if you wrote it in
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +0000398 a spell directory in 'runtimepath', or ":set spelllang=xx.enc.spl" if you
Bram Moolenaard042c562005-06-30 22:04:15 +0000399 wrote it somewhere else.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000400
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000401When the Myspell files are updated you can merge the differences:
Bram Moolenaar0cb032e2005-04-23 20:52:00 +00004021. Obtain the new Myspell files as xx_YY.new.aff and xx_UU.new.dic.
4032. Use Vimdiff to see what changed: >
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000404 vimdiff xx_YY.orig.dic xx_YY.new.dic
Bram Moolenaar0cb032e2005-04-23 20:52:00 +00004053. Take over the changes you like in xx_YY.dic.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000406 You may also need to change xx_YY.aff.
Bram Moolenaar0cb032e2005-04-23 20:52:00 +00004074. Rename xx_YY.new.dic to xx_YY.orig.dic and xx_YY.new.aff to xx_YY.new.aff.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000408
Bram Moolenaar3b506942005-06-23 22:36:45 +0000409
410SPELL FILE DUMP
411
412If for some reason you want to check what words are supported by the currently
413used spelling files, use this command:
414
415 *:spelldump* *:spelld*
416:spelld[ump] Open a new window and fill it with all currently valid
417 words.
Bram Moolenaard042c562005-06-30 22:04:15 +0000418 Note: For some languages the result may be enormous,
419 causing Vim to run out of memory.
Bram Moolenaar3b506942005-06-23 22:36:45 +0000420
421The format of the word list is used |spell-wordlist-format|. You should be
422able to read it with ":mkspell" to generate one .spl file that includes all
423the words.
424
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +0000425When all entries to 'spelllang' use the same regions or no regions at all then
426the region information is included in the dumped words. Otherwise only words
427for the current region are included and no "/regions" line is generated.
Bram Moolenaar3b506942005-06-23 22:36:45 +0000428
Bram Moolenaard042c562005-06-30 22:04:15 +0000429Comment lines with the name of the .spl file are used as a header above the
430words that were generated from that .spl file.
Bram Moolenaar3b506942005-06-23 22:36:45 +0000431
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000432==============================================================================
Bram Moolenaard042c562005-06-30 22:04:15 +00004334. Spell file format *spell-file-format*
Bram Moolenaar217ad922005-03-20 22:37:15 +0000434
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000435This is the format of the files that are used by the person who creates and
436maintains a word list.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000437
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000438Note that we avoid the word "dictionary" here. That is because the goal of
439spell checking differs from writing a dictionary (as in the book). For
Bram Moolenaard042c562005-06-30 22:04:15 +0000440spelling we need a list of words that are OK, thus should not to be
441highlighted. Person and company names will not appear in a dictionary, but do
442appear in a word list. And some old words are rarely used while they are
443common misspellings. These do appear in a dictionary but not in a word list.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000444
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +0000445There are two formats: A straight list of words and a list using affix
Bram Moolenaard042c562005-06-30 22:04:15 +0000446compression. The files with affix compression are used by Myspell (Mozilla
447and OpenOffice.org). This requires two files, one with .aff and one with .dic
448extension.
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000449
450
Bram Moolenaard042c562005-06-30 22:04:15 +0000451FORMAT OF STRAIGHT WORD LIST *spell-wordlist-format*
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000452
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000453The words must appear one per line. That is all that is required.
Bram Moolenaard042c562005-06-30 22:04:15 +0000454
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000455Additionally the following items are recognized:
Bram Moolenaard042c562005-06-30 22:04:15 +0000456
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000457- Empty and blank lines are ignored.
Bram Moolenaard042c562005-06-30 22:04:15 +0000458
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000459- Lines starting with a # are ignored (comment lines).
Bram Moolenaard042c562005-06-30 22:04:15 +0000460
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000461- A line starting with "/encoding=", before any word, specifies the encoding
462 of the file. After the second '=' comes an encoding name. This tells Vim
Bram Moolenaard042c562005-06-30 22:04:15 +0000463 to setup conversion from the specified encoding to 'encoding'. Thus you can
464 use one word list for several target encodings.
465
Bram Moolenaar3638c682005-06-08 22:05:14 +0000466- A line starting with "/regions=" specifies the region names that are
467 supported. Each region name must be two ASCII letters. The first one is
468 region 1. Thus "/regions=usca" has region 1 "us" and region 2 "ca".
Bram Moolenaard042c562005-06-30 22:04:15 +0000469 In an addition word list the region names should be equal to the main word
470 list!
471
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000472- Other lines starting with '/' are reserved for future use. The ones that
473 are not recognized are ignored (but you do get a warning message).
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000474
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +0000475- A "/" may follow the word with the following items:
476 = Case must match exactly.
477 ? Rare word.
478 ! Bad (wrong) word.
479 digit A region in which the word is valid. If no regions are
480 specified the word is valid in all regions.
481
Bram Moolenaar3638c682005-06-08 22:05:14 +0000482Example:
483
484 # This is an example word list comment
485 /encoding=latin1 encoding of the file
486 /regions=uscagb regions "us", "ca" and "gb"
487 example word for all regions
Bram Moolenaar1f8a5f02005-07-01 22:41:52 +0000488 blah/12 word for regions "us" and "ca"
489 vim/! bad word
490 Campbell/?3 rare word in region 3 "gb"
491 's mornings/= keep-case word
Bram Moolenaar3638c682005-06-08 22:05:14 +0000492
Bram Moolenaar0dc065e2005-07-04 22:49:24 +0000493Note that when "/=" is used the same word with all upper-case letters is not
494accepted. This is different from a word with mixed case that is automatically
495marked as keep-case, those words may appear in all upper-case letters.
496
Bram Moolenaar75c50c42005-06-04 22:06:24 +0000497
498FORMAT WITH AFFIX COMPRESSION
499
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000500There are two files: the basic word list and an affix file. The affixes are
501used to modify the basic words to get the full word list. This significantly
502reduces the number of words, especially for a language like Polish. This is
503called affix compression.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000504
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000505The format for the affix and word list files is mostly identical to what
506Myspell uses (the spell checker of Mozilla and OpenOffice.org). A description
507can be found here:
508 http://lingucomponent.openoffice.org/affix.readme ~
509Note that affixes are case sensitive, this isn't obvious from the description.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000510
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000511Vim supports a few extras. Hopefully Myspell will support these too some day.
512See |spell-affix-vim|.
Bram Moolenaar217ad922005-03-20 22:37:15 +0000513
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000514The basic word list and the affix file are combined and turned into a binary
515spell file. All the preprocessing has been done, thus this file loads fast.
516The binary spell file format is described in the source code (src/spell.c).
517But only developers need to know about it.
518
519The preprocessing also allows us to take the Myspell language files and modify
520them before the Vim word list is made. The tools for this can be found in the
521"src/spell" directory.
522
523
Bram Moolenaar3638c682005-06-08 22:05:14 +0000524WORD LIST FORMAT *spell-dic-format*
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000525
526A very short example, with line numbers:
527
528 1 1234
529 2 aan
530 3 Als
531 4 Etten-Leur
532 5 et al.
533 6 's-Gravenhage
534 7 's-Gravenhaags
535 8 bedel/P
536 9 kado/1
537 10 cadeau/2
538
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000539The first line contains the number of words. Vim ignores it, but you do get
540an error message if it's not there. *E760*
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000541
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000542What follows is one word per line. There should be no white space before or
543after the word.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000544
545When the word only has lower-case letters it will also match with the word
546starting with an upper-case letter.
547
548When the word includes an upper-case letter, this means the upper-case letter
549is required at this position. The same word with a lower-case letter at this
550position will not match. When some of the other letters are upper-case it will
551not match either.
552
Bram Moolenaard042c562005-06-30 22:04:15 +0000553The word with all upper-case characters will always be OK.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000554
555 word list matches does not match ~
556 als als Als ALS ALs AlS aLs aLS
557 Als Als ALS als ALs AlS aLs aLS
558 ALS ALS als Als ALs AlS aLs aLS
559 AlS AlS ALS als Als ALs aLs aLS
560
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000561The KEP affix ID can be used to specifically match a word with identical case
Bram Moolenaare7566042005-06-17 22:00:15 +0000562only, see below |spell-affix-KEP|.
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000563
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000564Note in line 5 to 7 that non-word characters are used. You can include
565any character in a word. When checking the text a word still only matches
566when it appears with a non-word character before and after it. For Myspell a
567word starting with a non-word character probably won't work.
568
569After the word there is an optional slash and flags. Most of these flags are
Bram Moolenaard042c562005-06-30 22:04:15 +0000570letters that indicate the affixes that can be used with this word. These are
571specified with SFX and PFX lines in the .aff file. See the Myspell
572documentation.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000573
574 *spell-affix-vim*
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000575A flag that Vim adds and is not in Myspell is the flag defined with KEP in the
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000576affix file. This has the meaning that case matters. This can be used if the
577word does not have the first letter in upper case at the start of a sentence.
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000578Example (assuming that = was used for KEP):
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000579
Bram Moolenaar0dc065e2005-07-04 22:49:24 +0000580 word list matches does not match ~
581 's morgens/= 's morgens 'S morgens 's Morgens 'S MORGENS
582 's Morgens 's Morgens 'S MORGENS 'S morgens 's morgens
583
584The flag can also be used to avoid that the word matches when it is in all
585upper-case letters.
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000586
587 *spell-affix-mbyte*
588The basic word list is normally in an 8-bit encoding, which is mentioned in
589the affix file. The affix file must always be in the same encoding as the
590word list. This is compatible with Myspell. For Vim the encoding may also be
591something else, any encoding that "iconv" supports. The "SET" line must
592specify the name of the encoding. When using a multi-byte encoding it's
Bram Moolenaard042c562005-06-30 22:04:15 +0000593possible to use more different affixes (but Myspell doesn't support that, thus
594you may not want to use it anyway).
Bram Moolenaar13fcaaf2005-04-15 21:13:42 +0000595
Bram Moolenaare13305e2005-06-19 22:54:15 +0000596
597CHARACTER TABLES
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000598 *spell-affix-chars*
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000599When using an 8-bit encoding the affix file should define what characters are
600word characters (as specified with ENC). This is because the system where
601":mkspell" is used may not support a locale with this encoding and isalpha()
602won't work. For example when using "cp1250" on Unix.
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000603
Bram Moolenaare7566042005-06-17 22:00:15 +0000604 *E761* *E762* *spell-affix-FOL*
605 *spell-affix-LOW* *spell-affix-UPP*
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000606Three lines in the affix file are needed. Simplistic example:
607
Bram Moolenaare13305e2005-06-19 22:54:15 +0000608 FOL áëñ ~
609 LOW áëñ ~
610 UPP ÁËÑ ~
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000611
612All three lines must have exactly the same number of characters.
613
614The "FOL" line specifies the case-folded characters. These are used to
615compare words while ignoring case. For most encodings this is identical to
616the lower case line.
617
618The "LOW" line specifies the characters in lower-case. Mostly it's equal to
619the "FOL" line.
620
621The "UPP" line specifies the characters with upper-case. That is, a character
622is upper-case where it's different from the character at the same position in
623"FOL".
624
625ASCII characters should be omitted, Vim always handles these in the same way.
626When the encoding is UTF-8 no word characters need to be specified.
627
628 *E763*
Bram Moolenaar3b506942005-06-23 22:36:45 +0000629Vim allows you to use spell checking for several languages in the same file.
630You can list them in the 'spelllang' option. As a consequence all spell files
631for the same encoding must use the same word characters, otherwise they can't
632be combined without errors. If you get a warning that the word tables differ
633you may need to generate the .spl file again with |:mkspell|. Check the FOL,
634LOW and UPP lines in the used .aff file.
635
636The XX.ascii.spl spell file generated with the "-ascii" argument will not
637contain the table with characters, so that it can be combine with spell files
638for any encoding. The .add.spl files also do not contain the table.
Bram Moolenaar0cb032e2005-04-23 20:52:00 +0000639
Bram Moolenaare7566042005-06-17 22:00:15 +0000640
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000641MID-WORD CHARACTERS
642 *spell-midword*
643Some characters are only to be considered word characters if they are used in
644between two ordinary word characters. An example is the single quote: It is
645often used to put text in quotes, thus it can't be recognized as a word
646character, but when it appears in between word characters it must be part of
647the word. This is needed to detect a spelling error such as they'are. That
648should be they're, but since "they" and "are" are words themselves that would
649go unnoticed.
650
651These characters are defined with MIDWORD in the .aff file:
652
653 MIDWORD '- ~
654
655
Bram Moolenaare13305e2005-06-19 22:54:15 +0000656AFFIXES
657 *spell-affix-PFX* *spell-affix-SFX*
658The usual PFX (prefix) and SFX (suffix) lines are supported (see the Myspell
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000659documentation or the Aspell manual:
660http://aspell.net/man-html/Affix-Compression.html).
Bram Moolenaare13305e2005-06-19 22:54:15 +0000661
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000662Note that Myspell ignores any extra text after the relevant info. Vim
663requires this text to start with a "#" so that mistakes don't go unnoticed.
664Example:
665
666 SFX F 0 in [^i]n # Spion > Spionin ~
667 SFX F 0 nen in # Bauerin > Bauerinnen ~
668
669An extra item for Vim is the "rare" flag. It must come after the other
670fields, before a comment. When used then all words that use the affix will be
671marked as rare words. Example:
672
673 PFX F 0 nene . rare ~
674 SFX F 0 oin n rare # hardly ever used ~
675
676However, if the word also appears as a good word in another way it won't be
677marked as rare.
Bram Moolenaare13305e2005-06-19 22:54:15 +0000678
679 *spell-affix-PFXPOSTPONE*
680When an affix file has very many prefixes that apply to many words it's not
681possible to build the whole word list in memory. This applies to Hebrew (a
682list with all words is over a Gbyte). In that case applying prefixes must be
683postponed. This makes spell checking slower. It is indicated by this keyword
684in the .aff file:
685
686 PFXPOSTPONE ~
687
688Only prefixes without a chop string can be postponed, prefixes with a chop
689string will still be included in the word list.
690
691
692KEEP-CASE WORDS
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000693 *spell-affix-KEP*
694In the affix file a KEP line can be used to define the affix name used for
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000695keep-case words. Example:
696
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000697 KEP = ~
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000698
699See above for an example |spell-affix-vim|.
700
Bram Moolenaare13305e2005-06-19 22:54:15 +0000701
702RARE WORDS
Bram Moolenaar82cf9b62005-06-07 21:09:25 +0000703 *spell-affix-RAR*
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000704In the affix file a RAR line can be used to define the affix name used for
705rare words. Example:
706
707 RAR ? ~
708
709Rare words are highlighted differently from bad words. This is to be used for
710words that are correct for the language, but are hardly ever used and could be
Bram Moolenaar30abd282005-06-22 22:35:10 +0000711a typing mistake anyway. When the same word is found as good it won't be
712highlighted as rare.
713
714
715BAD WORDS
716 *spell-affix-BAD*
717In the affix file a BAD line can be used to define the affix name used for
718bad words. Example:
719
720 BAD ! ~
721
722This can be used to exclude words that would otherwise be good. For example
Bram Moolenaar9a50b1b2005-06-27 22:48:21 +0000723"the the" in the .dic file:
724
725 the the/! ~
726
727Once a word has been marked as bad it won't be undone by encountering the same
728word as good.
Bram Moolenaar45eeb132005-06-06 21:59:07 +0000729
730
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000731REPLACEMENTS *spell-affix-REP*
732
733In the affix file REP items can be used to define common mistakes. This is
734used to make spelling suggestions. The items define the "from" text and the
735"to" replacement. Example:
736
737 REP 4 ~
738 REP f ph ~
739 REP ph f ~
740 REP k ch ~
741 REP ch k ~
742
743The first line specifies the number of REP lines following. Vim ignores it.
Bram Moolenaard042c562005-06-30 22:04:15 +0000744Don't include simple one-character replacements or swaps. Vim will try these
745anyway. You can include whole words if you want to, but you might want to use
746the "file:" item in 'spellsuggest' instead.
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000747
748
749SIMILAR CHARACTERS *spell-affix-MAP*
750
Bram Moolenaard042c562005-06-30 22:04:15 +0000751In the affix file MAP items can be used to define letters that are very much
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000752alike. This is mostly used for a letter with different accents. This is used
753to prefer suggestions with these letters substituted. Example:
754
755 MAP 2 ~
756 MAP eéëêè ~
757 MAP uüùúû ~
758
759The first line specifies the number of MAP lines following. Vim ignores it.
760
Bram Moolenaard042c562005-06-30 22:04:15 +0000761Each letter must appear in only one of the MAP items. It's a bit more
762efficient if the first letter is ASCII or at least one without accents.
Bram Moolenaare7566042005-06-17 22:00:15 +0000763
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000764
Bram Moolenaard042c562005-06-30 22:04:15 +0000765SOUND-A-LIKE *spell-affix-SAL*
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000766
767In the affix file SAL items can be used to define the sounds-a-like mechanism
768to be used. The main items define the "from" text and the "to" replacement.
Bram Moolenaard042c562005-06-30 22:04:15 +0000769Simplistic example:
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000770
771 SAL CIA X ~
772 SAL CH X ~
773 SAL C K ~
774 SAL K K ~
775
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +0000776There are a few rules and this can become quite complicated. An explanation
Bram Moolenaard042c562005-06-30 22:04:15 +0000777how it works can be found in the Aspell manual:
Bram Moolenaar42eeac32005-06-29 22:40:58 +0000778http://aspell.net/man-html/Phonetic-Code.html.
Bram Moolenaar9ba0eb82005-06-13 22:28:56 +0000779
780There are a few special items:
781
782 SAL followup true ~
783 SAL collapse_result true ~
784 SAL remove_accents true ~
785
786"1" has the same meaning as "true". Any other value means "false".
787
Bram Moolenaar42eeac32005-06-29 22:40:58 +0000788
789SIMPLE SOUNDFOLDING *spell-affix-SOFOFROM* *spell-affix-SOFOTO*
790
791The SAL mechanism is complex and slow. A simpler mechanism is mapping all
792characters to another character, mapping similar sounding characters to the
793same character. At the same time this does case folding. You can not have
Bram Moolenaard042c562005-06-30 22:04:15 +0000794both SAL items and simple soundfolding.
Bram Moolenaar42eeac32005-06-29 22:40:58 +0000795
Bram Moolenaar7d1f5db2005-07-03 21:39:27 +0000796There are two items required: one to specify the characters that are mapped
Bram Moolenaar42eeac32005-06-29 22:40:58 +0000797and one that specifies the characters they are mapped to. They must have
798exactly the same number of characters. Example:
799
800 SOFOFROM abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ ~
801 SOFOTO ebctefghejklnnepkrstevvkesebctefghejklnnepkrstevvkes ~
802
803In the example all vowels are mapped to the same character 'e'. Another
Bram Moolenaard042c562005-06-30 22:04:15 +0000804method would be to leave out all vowels. Some characters that sound nearly
805the same and are often mixed up, such as 'm' and 'n', are mapped to the same
806character. Don't do this too much, all words will start looking alike.
Bram Moolenaar42eeac32005-06-29 22:40:58 +0000807
808Characters that do not appear in SOFOFROM will be left out, except that all
809white space is replaced by one space. Sequences of the same character in
810SOFOFROM are replaced by one.
811
812You can use the |soundfold()| function to try out the results. Or set the
813'verbose' option to see the score in the output of the |z?| command.
814
815
Bram Moolenaar217ad922005-03-20 22:37:15 +0000816 vim:tw=78:sw=4:ts=8:ft=help:norl: