annotate runtime/lang/README.txt @ 11418:162bcd0debd7 v8.0.0593

patch 8.0.0593: duplication of code for adding a list or dict return value commit https://github.com/vim/vim/commit/45cf6e910c6d162775ca9d470fac4b6db844001f Author: Bram Moolenaar <Bram@vim.org> Date: Sun Apr 30 20:25:19 2017 +0200 patch 8.0.0593: duplication of code for adding a list or dict return value Problem: Duplication of code for adding a list or dict return value. Solution: Add rettv_dict_set() and rettv_list_set(). (Yegappan Lakshmanan)
author Christian Brabandt <cb@256bit.org>
date Sun, 30 Apr 2017 20:30:04 +0200
parents 3fc0f57ecb91
children 2a4a2dc35c55
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 Language files for Vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 Translated menus
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 ----------------
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 The contents of each menu file is a sequence of lines with "menutrans"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 commands. Read one of the existing files to get an idea of how this works.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 More information in the on-line help:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 :help multilang-menus
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 :help :menutrans
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 :help 'langmenu'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 :help :language
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 The "$VIMRUNTIME/menu.vim" file will search for a menu translation file. This
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 depends on the value of the "v:lang" variable.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 "menu_" . v:lang . ".vim"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 When the 'menutrans' option is set, its value will be used instead of v:lang.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 The file name is always lower case. It is the full name as the ":language"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 command shows (the LC_MESSAGES value).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 For example, to use the Big5 (Taiwan) menus on MS-Windows the $LANG will be
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 Chinese(Taiwan)_Taiwan.950
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 and use the menu translation file:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 $VIMRUNTIME/lang/menu_chinese(taiwan)_taiwan.950.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 On Unix you should set $LANG, depending on your shell:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 csh/tcsh: setenv LANG "zh_TW.Big5"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 sh/bash/ksh: export LANG="zh_TW.Big5"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 and the menu translation file is:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 $VIMRUNTIME/lang/menu_zh_tw.big5.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 The menu translation file should set the "did_menu_trans" variable so that Vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 will not load another file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 AUTOMATIC CONVERSION
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 When Vim was compiled with multi-byte support, conversion between latin1 and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 UTF-8 will always be possible. Other conversions depend on the iconv
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 library, which is not always available.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 For UTF-8 menu files which only use latin1 characters, you can rely on Vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 doing the conversion. Let the UTF-8 menu file source the latin1 menu file,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 and put "scriptencoding latin1" in that one.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 Other conversions may not always be available (e.g., between iso-8859-# and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 MS-Windows codepages), thus the converted menu file must be available.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 Translated messages
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 -------------------
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 This requires doing "make install" in the "src" directory. It will compile
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 the portable files "src/po/*.po" into binary ".mo" files and place them in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64 right directory.