annotate runtime/doc/mbyte.txt @ 23843:d97258eca25d v8.2.2463

patch 8.2.2463: using :arglocal in an autocommand may use freed memory Commit: https://github.com/vim/vim/commit/6bcb877ec19a647443195a54eeac60cb693fd827 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Feb 3 21:23:29 2021 +0100 patch 8.2.2463: using :arglocal in an autocommand may use freed memory Problem: Using :arglocal in an autocommand may use freed memory. (houyunsong) Solution: Check if the arglist is locked.
author Bram Moolenaar <Bram@vim.org>
date Wed, 03 Feb 2021 21:30:04 +0100
parents bbca88cd13d5
children 5c98ea5f5d6e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
1 *mbyte.txt* For Vim version 8.2. Last change: 2020 Aug 15
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 VIM REFERENCE MANUAL by Bram Moolenaar et al.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 Multi-byte support *multibyte* *multi-byte*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 *Chinese* *Japanese* *Korean*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 This is about editing text in languages which have many characters that can
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 not be represented using one byte (one octet). Examples are Chinese, Japanese
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 and Korean. Unicode is also covered here.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 For an introduction to the most common features, see |usr_45.txt| in the user
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 manual.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 For changing the language of messages and menus see |mlang.txt|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 1. Getting started |mbyte-first|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 2. Locale |mbyte-locale|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 3. Encoding |mbyte-encoding|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 4. Using a terminal |mbyte-terminal|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 5. Fonts on X11 |mbyte-fonts-X11|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 6. Fonts on MS-Windows |mbyte-fonts-MSwin|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 7. Input on X11 |mbyte-XIM|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 8. Input on MS-Windows |mbyte-IME|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 9. Input with a keymap |mbyte-keymap|
12920
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
26 10. Input with imactivatefunc() |mbyte-func|
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
27 11. Using UTF-8 |mbyte-utf8|
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
28 12. Overview of options |mbyte-options|
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 NOTE: This file contains UTF-8 characters. These may show up as strange
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 characters or boxes when using another encoding.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 1. Getting started *mbyte-first*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 This is a summary of the multibyte features in Vim. If you are lucky it works
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 as described and you can start using Vim without much trouble. If something
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 doesn't work you will have to read the rest. Don't be surprised if it takes
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
39 quite a bit of work and experimenting to make Vim use all the multibyte
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 features. Unfortunately, every system has its own way to deal with multibyte
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 languages and it is quite complicated.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 LOCALE
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 First of all, you must make sure your current locale is set correctly. If
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 your system has been installed to use the language, it probably works right
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 away. If not, you can often make it work by setting the $LANG environment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 variable in your shell: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 setenv LANG ja_JP.EUC
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 Unfortunately, the name of the locale depends on your system. Japanese might
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 also be called "ja_JP.EUCjp" or just "ja". To see what is currently used: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 :language
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 To change the locale inside Vim use: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 :language ja_JP.EUC
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 Vim will give an error message if this doesn't work. This is a good way to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 experiment and find the locale name you want to use. But it's always better
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64 to set the locale in the shell, so that it is used right from the start.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 See |mbyte-locale| for details.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69 ENCODING
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71 If your locale works properly, Vim will try to set the 'encoding' option
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72 accordingly. If this doesn't work you can overrule its value: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74 :set encoding=utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 See |encoding-values| for a list of acceptable values.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78 The result is that all the text that is used inside Vim will be in this
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 encoding. Not only the text in the buffers, but also in registers, variables,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80 etc. This also means that changing the value of 'encoding' makes the existing
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 text invalid! The text doesn't change, but it will be displayed wrong.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83 You can edit files in another encoding than what 'encoding' is set to. Vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84 will convert the file when you read it and convert it back when you write it.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
85 See 'fileencoding', 'fileencodings' and |++enc|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
86
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
87
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
88 DISPLAY AND FONTS
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
89
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 If you are working in a terminal (emulator) you must make sure it accepts the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91 same encoding as which Vim is working with. If this is not the case, you can
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92 use the 'termencoding' option to make Vim convert text automatically.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94 For the GUI you must select fonts that work with the current 'encoding'. This
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95 is the difficult part. It depends on the system you are using, the locale and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
96 a few other things. See the chapters on fonts: |mbyte-fonts-X11| for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
97 X-Windows and |mbyte-fonts-MSwin| for MS-Windows.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
98
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99 For GTK+ 2, you can skip most of this section. The option 'guifontset' does
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 no longer exist. You only need to set 'guifont' and everything should "just
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 work". If your system comes with Xft2 and fontconfig and the current font
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102 does not contain a certain glyph, a different font will be used automatically
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 if available. The 'guifontwide' option is still supported but usually you do
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 not need to set it. It is only necessary if the automatic font selection does
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 not suit your needs.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107 For X11 you can set the 'guifontset' option to a list of fonts that together
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108 cover the characters that are used. Example for Korean: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 :set guifontset=k12,r12
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
111
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
112 Alternatively, you can set 'guifont' and 'guifontwide'. 'guifont' is used for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113 the single-width characters, 'guifontwide' for the double-width characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
114 Thus the 'guifontwide' font must be exactly twice as wide as 'guifont'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
115 Example for UTF-8: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
116
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
117 :set guifont=-misc-fixed-medium-r-normal-*-18-120-100-100-c-90-iso10646-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
118 :set guifontwide=-misc-fixed-medium-r-normal-*-18-120-100-100-c-180-iso10646-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
119
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
120 You can also set 'guifont' alone, Vim will try to find a matching
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
121 'guifontwide' for you.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
122
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
123
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
124 INPUT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
125
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
126 There are several ways to enter multibyte characters:
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
127 - For X11 XIM can be used. See |XIM|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
128 - For MS-Windows IME can be used. See |IME|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
129 - For all systems keymaps can be used. See |mbyte-keymap|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
130
21499
3a1ed539ae2a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 18879
diff changeset
131 The options 'iminsert', 'imsearch' and 'imcmdline' can be used to choose
9
4102fb4ea781 updated for version 7.0002
vimboss
parents: 7
diff changeset
132 the different input methods or disable them temporarily.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
133
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
134 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
135 2. Locale *mbyte-locale*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
136
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
137 The easiest setup is when your whole system uses the locale you want to work
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
138 in. But it's also possible to set the locale for one shell you are working
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
139 in, or just use a certain locale inside Vim.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
140
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
141
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
142 WHAT IS A LOCALE? *locale*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
143
21499
3a1ed539ae2a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 18879
diff changeset
144 There are many languages in the world. And there are different cultures and
3a1ed539ae2a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 18879
diff changeset
145 environments at least as many as the number of languages. A linguistic
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
146 environment corresponding to an area is called "locale". This includes
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
147 information about the used language, the charset, collating order for sorting,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
148 date format, currency format and so on. For Vim only the language and charset
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
149 really matter.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
150
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
151 You can only use a locale if your system has support for it. Some systems
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
152 have only a few locales, especially in the USA. The language which you want
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
153 to use may not be on your system. In that case you might be able to install
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
154 it as an extra package. Check your system documentation for how to do that.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
155
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
156 The location in which the locales are installed varies from system to system.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
157 For example, "/usr/share/locale" or "/usr/lib/locale". See your system's
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
158 setlocale() man page.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
159
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
160 Looking in these directories will show you the exact name of each locale.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
161 Mostly upper/lowercase matters, thus "ja_JP.EUC" and "ja_jp.euc" are
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
162 different. Some systems have a locale.alias file, which allows translation
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
163 from a short name like "nl" to the full name "nl_NL.ISO_8859-1".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
164
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
165 Note that X-windows has its own locale stuff. And unfortunately uses locale
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
166 names different from what is used elsewhere. This is confusing! For Vim it
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
167 matters what the setlocale() function uses, which is generally NOT the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
168 X-windows stuff. You might have to do some experiments to find out what
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
169 really works.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
170
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
171 *locale-name*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
172 The (simplified) format of |locale| name is:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
173
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
174 language
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
175 or language_territory
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
176 or language_territory.codeset
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
177
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
178 Territory means the country (or part of it), codeset means the |charset|. For
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
179 example, the locale name "ja_JP.eucJP" means:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
180 ja the language is Japanese
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
181 JP the country is Japan
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
182 eucJP the codeset is EUC-JP
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
183 But it also could be "ja", "ja_JP.EUC", "ja_JP.ujis", etc. And unfortunately,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
184 the locale name for a specific language, territory and codeset is not unified
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
185 and depends on your system.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
186
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
187 Examples of locale name:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
188 charset language locale name ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
189 GB2312 Chinese (simplified) zh_CN.EUC, zh_CN.GB2312
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
190 Big5 Chinese (traditional) zh_TW.BIG5, zh_TW.Big5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
191 CNS-11643 Chinese (traditional) zh_TW
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
192 EUC-JP Japanese ja, ja_JP.EUC, ja_JP.ujis, ja_JP.eucJP
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
193 Shift_JIS Japanese ja_JP.SJIS, ja_JP.Shift_JIS
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
194 EUC-KR Korean ko, ko_KR.EUC
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
195
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
196
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
197 USING A LOCALE
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
198
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
199 To start using a locale for the whole system, see the documentation of your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
200 system. Mostly you need to set it in a configuration file in "/etc".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
201
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
202 To use a locale in a shell, set the $LANG environment value. When you want to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
203 use Korean and the |locale| name is "ko", do this:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
204
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
205 sh: export LANG=ko
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
206 csh: setenv LANG ko
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
207
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
208 You can put this in your ~/.profile or ~/.cshrc file to always use it.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
209
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
210 To use a locale in Vim only, use the |:language| command: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
211
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
212 :language ko
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
213
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
214 Put this in your ~/.vimrc file to use it always.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
215
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
216 Or specify $LANG when starting Vim:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
217
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
218 sh: LANG=ko vim {vim-arguments}
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
219 csh: env LANG=ko vim {vim-arguments}
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
220
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
221 You could make a small shell script for this.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
222
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
223 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
224 3. Encoding *mbyte-encoding*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
225
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
226 Vim uses the 'encoding' option to specify how characters are identified and
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
227 encoded when they are used inside Vim. This applies to all the places where
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
228 text is used, including buffers (files loaded into memory), registers and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
229 variables.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
230
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
231 *charset* *codeset*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
232 Charset is another name for encoding. There are subtle differences, but these
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
233 don't matter when using Vim. "codeset" is another similar name.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
234
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
235 Each character is encoded as one or more bytes. When all characters are
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
236 encoded with one byte, we call this a single-byte encoding. The most often
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
237 used one is called "latin1". This limits the number of characters to 256.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
238 Some of these are control characters, thus even fewer can be used for text.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
239
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
240 When some characters use two or more bytes, we call this a multibyte
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
241 encoding. This allows using much more than 256 characters, which is required
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
242 for most East Asian languages.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
243
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
244 Most multibyte encodings use one byte for the first 127 characters. These
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
245 are equal to ASCII, which makes it easy to exchange plain-ASCII text, no
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
246 matter what language is used. Thus you might see the right text even when the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
247 encoding was set wrong.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
248
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
249 *encoding-names*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
250 Vim can use many different character encodings. There are three major groups:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
251
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
252 1 8bit Single-byte encodings, 256 different characters. Mostly used
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
253 in USA and Europe. Example: ISO-8859-1 (Latin1). All
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
254 characters occupy one screen cell only.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
255
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
256 2 2byte Double-byte encodings, over 10000 different characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
257 Mostly used in Asian countries. Example: euc-kr (Korean)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
258 The number of screen cells is equal to the number of bytes
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
259 (except for euc-jp when the first byte is 0x8e).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
260
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
261 u Unicode Universal encoding, can replace all others. ISO 10646.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
262 Millions of different characters. Example: UTF-8. The
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
263 relation between bytes and screen cells is complex.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
264
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
265 Other encodings cannot be used by Vim internally. But files in other
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
266 encodings can be edited by using conversion, see 'fileencoding'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
267 Note that all encodings must use ASCII for the characters up to 128 (except
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
268 when compiled for EBCDIC).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
269
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
270 Supported 'encoding' values are: *encoding-values*
2698
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
271 1 latin1 8-bit characters (ISO 8859-1, also used for cp1252)
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
272 1 iso-8859-n ISO_8859 variant (n = 2 to 15)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
273 1 koi8-r Russian
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
274 1 koi8-u Ukrainian
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
275 1 macroman MacRoman (Macintosh encoding)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
276 1 8bit-{name} any 8-bit encoding (Vim specific name)
407
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
277 1 cp437 similar to iso-8859-1
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
278 1 cp737 similar to iso-8859-7
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
279 1 cp775 Baltic
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
280 1 cp850 similar to iso-8859-4
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
281 1 cp852 similar to iso-8859-1
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
282 1 cp855 similar to iso-8859-2
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
283 1 cp857 similar to iso-8859-5
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
284 1 cp860 similar to iso-8859-9
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
285 1 cp861 similar to iso-8859-1
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
286 1 cp862 similar to iso-8859-1
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
287 1 cp863 similar to iso-8859-8
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
288 1 cp865 similar to iso-8859-1
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
289 1 cp866 similar to iso-8859-5
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
290 1 cp869 similar to iso-8859-7
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
291 1 cp874 Thai
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
292 1 cp1250 Czech, Polish, etc.
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
293 1 cp1251 Cyrillic
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
294 1 cp1253 Greek
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
295 1 cp1254 Turkish
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
296 1 cp1255 Hebrew
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
297 1 cp1256 Arabic
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
298 1 cp1257 Baltic
0f6afaf1b8d1 updated for version 7.0106
vimboss
parents: 236
diff changeset
299 1 cp1258 Vietnamese
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
300 1 cp{number} MS-Windows: any installed single-byte codepage
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
301 2 cp932 Japanese (Windows only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
302 2 euc-jp Japanese (Unix only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
303 2 sjis Japanese (Unix only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
304 2 cp949 Korean (Unix and Windows)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
305 2 euc-kr Korean (Unix only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
306 2 cp936 simplified Chinese (Windows only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
307 2 euc-cn simplified Chinese (Unix only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
308 2 cp950 traditional Chinese (on Unix alias for big5)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
309 2 big5 traditional Chinese (on Windows alias for cp950)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
310 2 euc-tw traditional Chinese (Unix only)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
311 2 2byte-{name} Unix: any double-byte encoding (Vim specific name)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
312 2 cp{number} MS-Windows: any installed double-byte codepage
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
313 u utf-8 32 bit UTF-8 encoded Unicode (ISO/IEC 10646-1)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
314 u ucs-2 16 bit UCS-2 encoded Unicode (ISO/IEC 10646-1)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
315 u ucs-2le like ucs-2, little endian
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
316 u utf-16 ucs-2 extended with double-words for more characters
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
317 u utf-16le like utf-16, little endian
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
318 u ucs-4 32 bit UCS-4 encoded Unicode (ISO/IEC 10646-1)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
319 u ucs-4le like ucs-4, little endian
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
320
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
321 The {name} can be any encoding name that your system supports. It is passed
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
322 to iconv() to convert between the encoding of the file and the current locale.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
323 For MS-Windows "cp{number}" means using codepage {number}.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
324 Examples: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
325 :set encoding=8bit-cp1252
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
326 :set encoding=2byte-cp932
2698
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
327
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
328 The MS-Windows codepage 1252 is very similar to latin1. For practical reasons
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
329 the same encoding is used and it's called latin1. 'isprint' can be used to
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
330 display the characters 0x80 - 0xA0 or not.
b6471224d2af Updated runtime files and translations.
Bram Moolenaar <bram@vim.org>
parents: 2577
diff changeset
331
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
332 Several aliases can be used, they are translated to one of the names above.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
333 An incomplete list:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
334
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
335 1 ansi same as latin1 (obsolete, for backward compatibility)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
336 2 japan Japanese: on Unix "euc-jp", on MS-Windows cp932
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
337 2 korea Korean: on Unix "euc-kr", on MS-Windows cp949
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
338 2 prc simplified Chinese: on Unix "euc-cn", on MS-Windows cp936
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
339 2 chinese same as "prc"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
340 2 taiwan traditional Chinese: on Unix "euc-tw", on MS-Windows cp950
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
341 u utf8 same as utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
342 u unicode same as ucs-2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
343 u ucs2be same as ucs-2 (big endian)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
344 u ucs-2be same as ucs-2 (big endian)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
345 u ucs-4be same as ucs-4 (big endian)
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
346 u utf-32 same as ucs-4
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
347 u utf-32le same as ucs-4le
39
410fa1a31baf updated for version 7.0023
vimboss
parents: 15
diff changeset
348 default stands for the default value of 'encoding', depends on the
856
8cd729851562 updated for version 7.0g
vimboss
parents: 842
diff changeset
349 environment
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
350
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
351 For the UCS codes the byte order matters. This is tricky, use UTF-8 whenever
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
352 you can. The default is to use big-endian (most significant byte comes
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
353 first):
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
354 name bytes char ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
355 ucs-2 11 22 1122
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
356 ucs-2le 22 11 1122
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
357 ucs-4 11 22 33 44 11223344
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
358 ucs-4le 44 33 22 11 11223344
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
359
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
360 On MS-Windows systems you often want to use "ucs-2le", because it uses little
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
361 endian UCS-2.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
362
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
363 There are a few encodings which are similar, but not exactly the same. Vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
364 treats them as if they were different encodings, so that conversion will be
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
365 done when needed. You might want to use the similar name to avoid conversion
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
366 or when conversion is not possible:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
367
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
368 cp932, shift-jis, sjis
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
369 cp936, euc-cn
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
370
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
371 *encoding-table*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
372 Normally 'encoding' is equal to your current locale and 'termencoding' is
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
373 empty. This means that your keyboard and display work with characters encoded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
374 in your current locale, and Vim uses the same characters internally.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
375
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
376 You can make Vim use characters in a different encoding by setting the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
377 'encoding' option to a different value. Since the keyboard and display still
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
378 use the current locale, conversion needs to be done. The 'termencoding' then
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
379 takes over the value of the current locale, so Vim converts between 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
380 and 'termencoding'. Example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
381 :let &termencoding = &encoding
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
382 :set encoding=utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
383
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
384 However, not all combinations of values are possible. The table below tells
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
385 you how each of the nine combinations works. This is further restricted by
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
386 not all conversions being possible, iconv() being present, etc. Since this
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
387 depends on the system used, no detailed list can be given.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
388
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
389 ('tenc' is the short name for 'termencoding' and 'enc' short for 'encoding')
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
390
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
391 'tenc' 'enc' remark ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
392
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
393 8bit 8bit Works. When 'termencoding' is different from
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
394 'encoding' typing and displaying may be wrong for some
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
395 characters, Vim does NOT perform conversion (set
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
396 'encoding' to "utf-8" to get this).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
397 8bit 2byte MS-Windows: works for all codepages installed on your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
398 system; you can only type 8bit characters;
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
399 Other systems: does NOT work.
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 874
diff changeset
400 8bit Unicode Works, but only 8bit characters can be typed directly
e63691e7c504 updated for version 7.1a
vimboss
parents: 874
diff changeset
401 (others through digraphs, keymaps, etc.); in a
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
402 terminal you can only see 8bit characters; the GUI can
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
403 show all characters that the 'guifont' supports.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
404
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
405 2byte 8bit Works, but typing non-ASCII characters might
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
406 be a problem.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
407 2byte 2byte MS-Windows: works for all codepages installed on your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
408 system; typing characters might be a problem when
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
409 locale is different from 'encoding'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
410 Other systems: Only works when 'termencoding' is equal
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
411 to 'encoding', you might as well leave it empty.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
412 2byte Unicode works, Vim will translate typed characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
413
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
414 Unicode 8bit works (unusual)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
415 Unicode 2byte does NOT work
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
416 Unicode Unicode works very well (leaving 'termencoding' empty works
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
417 the same way, because all Unicode is handled
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
418 internally as UTF-8)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
419
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
420 CONVERSION *charset-conversion*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
421
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
422 Vim will automatically convert from one to another encoding in several places:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
423 - When reading a file and 'fileencoding' is different from 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
424 - When writing a file and 'fileencoding' is different from 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
425 - When displaying characters and 'termencoding' is different from 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
426 - When reading input and 'termencoding' is different from 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
427 - When displaying messages and the encoding used for LC_MESSAGES differs from
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
428 'encoding' (requires a gettext version that supports this).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
429 - When reading a Vim script where |:scriptencoding| is different from
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
430 'encoding'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
431 - When reading or writing a |viminfo| file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
432 Most of these require the |+iconv| feature. Conversion for reading and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
433 writing files may also be specified with the 'charconvert' option.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
434
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
435 Useful utilities for converting the charset:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
436 All: iconv
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
437 GNU iconv can convert most encodings. Unicode is used as the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
438 intermediate encoding, which allows conversion from and to all other
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
439 encodings. See http://www.gnu.org/directory/libiconv.html.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
440
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
441 Japanese: nkf
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
442 Nkf is "Network Kanji code conversion Filter". One of the most unique
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
443 facility of nkf is the guess of the input Kanji code. So, you don't
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
444 need to know what the inputting file's |charset| is. When convert to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
445 EUC-JP from ISO-2022-JP or Shift_JIS, simply do the following command
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
446 in Vim:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
447 :%!nkf -e
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
448 Nkf can be found at:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
449 http://www.sfc.wide.ad.jp/~max/FreeBSD/ports/distfiles/nkf-1.62.tar.gz
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
450
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
451 Chinese: hc
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
452 Hc is "Hanzi Converter". Hc convert a GB file to a Big5 file, or Big5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
453 file to GB file. Hc can be found at:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
454 ftp://ftp.cuhk.hk/pub/chinese/ifcss/software/unix/convert/hc-30.tar.gz
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
455
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
456 Korean: hmconv
236
4707450c2b33 updated for version 7.0066
vimboss
parents: 167
diff changeset
457 Hmconv is Korean code conversion utility especially for E-mail. It can
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
458 convert between EUC-KR and ISO-2022-KR. Hmconv can be found at:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
459 ftp://ftp.kaist.ac.kr/pub/hangul/code/hmconv/
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
460
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
461 Multilingual: lv
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
462 Lv is a Powerful Multilingual File Viewer. And it can be worked as
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
463 |charset| converter. Supported |charset|: ISO-2022-CN, ISO-2022-JP,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
464 ISO-2022-KR, EUC-CN, EUC-JP, EUC-KR, EUC-TW, UTF-7, UTF-8, ISO-8859
236
4707450c2b33 updated for version 7.0066
vimboss
parents: 167
diff changeset
465 series, Shift_JIS, Big5 and HZ. Lv can be found at:
3682
11d40fc82f11 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3410
diff changeset
466 http://www.ff.iij4u.or.jp/~nrt/lv/index.html
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
467
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
468
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
469 *mbyte-conversion*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
470 When reading and writing files in an encoding different from 'encoding',
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
471 conversion needs to be done. These conversions are supported:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
472 - All conversions between Latin-1 (ISO-8859-1), UTF-8, UCS-2 and UCS-4 are
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
473 handled internally.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
474 - For MS-Windows, when 'encoding' is a Unicode encoding, conversion from and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
475 to any codepage should work.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
476 - Conversion specified with 'charconvert'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
477 - Conversion with the iconv library, if it is available.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
478 Old versions of GNU iconv() may cause the conversion to fail (they
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
479 request a very large buffer, more than Vim is willing to provide).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
480 Try getting another iconv() implementation.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
481
557
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
482 *iconv-dynamic*
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
483 On MS-Windows Vim can be compiled with the |+iconv/dyn| feature. This means
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
484 Vim will search for the "iconv.dll" and "libiconv.dll" libraries. When
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
485 neither of them can be found Vim will still work but some conversions won't be
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
486 possible.
862863033fdd updated for version 7.0158
vimboss
parents: 407
diff changeset
487
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
488 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
489 4. Using a terminal *mbyte-terminal*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
490
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
491 The GUI fully supports multibyte characters. It is also possible in a
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
492 terminal, if the terminal supports the same encoding that Vim uses. Thus this
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
493 is less flexible.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
494
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
495 For example, you can run Vim in a xterm with added multibyte support and/or
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
496 |XIM|. Examples are kterm (Kanji term) and hanterm (for Korean), Eterm
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
497 (Enlightened terminal) and rxvt.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
498
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
499 If your terminal does not support the right encoding, you can set the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
500 'termencoding' option. Vim will then convert the typed characters from
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
501 'termencoding' to 'encoding'. And displayed text will be converted from
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
502 'encoding' to 'termencoding'. If the encoding supported by the terminal
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
503 doesn't include all the characters that Vim uses, this leads to lost
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
504 characters. This may mess up the display. If you use a terminal that
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
505 supports Unicode, such as the xterm mentioned below, it should work just fine,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
506 since nearly every character set can be converted to Unicode without loss of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
507 information.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
509
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
510 UTF-8 IN XFREE86 XTERM *UTF8-xterm*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
511
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
512 This is a short explanation of how to use UTF-8 character encoding in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
513 xterm that comes with XFree86 by Thomas Dickey (text by Markus Kuhn).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
514
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
515 Get the latest xterm version which has now UTF-8 support:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
516
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
517 http://invisible-island.net/xterm/xterm.html
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
518
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
519 Compile it with "./configure --enable-wide-chars ; make"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
520
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
521 Also get the ISO 10646-1 version of various fonts, which is available on
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
522
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
523 http://www.cl.cam.ac.uk/~mgk25/download/ucs-fonts.tar.gz
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
524
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
525 and install the font as described in the README file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
526
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
527 Now start xterm with >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
528
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
529 xterm -u8 -fn -misc-fixed-medium-r-semicondensed--13-120-75-75-c-60-iso10646-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
530 or, for bigger character: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
531 xterm -u8 -fn -misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
532
236
4707450c2b33 updated for version 7.0066
vimboss
parents: 167
diff changeset
533 and you will have a working UTF-8 terminal emulator. Try both >
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
534
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
535 cat utf-8-demo.txt
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
536 vim utf-8-demo.txt
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
537
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
538 with the demo text that comes with ucs-fonts.tar.gz in order to see
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
539 whether there are any problems with UTF-8 in your xterm.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
540
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
541 For Vim you may need to set 'encoding' to "utf-8".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
542
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
543 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
544 5. Fonts on X11 *mbyte-fonts-X11*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
545
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
546 Unfortunately, using fonts in X11 is complicated. The name of a single-byte
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
547 font is a long string. For multibyte fonts we need several of these...
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
548
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
549 Note: Most of this is no longer relevant for GTK+ 2. Selecting a font via
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
550 its XLFD is not supported; see 'guifont' for an example of how to
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
551 set the font. Do yourself a favor and ignore the |XLFD| and |xfontset|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
552 sections below.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
553
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
554 First of all, Vim only accepts fixed-width fonts for displaying text. You
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
555 cannot use proportionally spaced fonts. This excludes many of the available
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
556 (and nicer looking) fonts. However, for menus and tooltips any font can be
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
557 used.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
558
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
559 Note that Display and Input are independent. It is possible to see your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
560 language even though you have no input method for it.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
561
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
562 You should get a default font for menus and tooltips that works, but it might
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
563 be ugly. Read the following to find out how to select a better font.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
564
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
565
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
566 X LOGICAL FONT DESCRIPTION (XLFD)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
567 *XLFD*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
568 XLFD is the X font name and contains the information about the font size,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
569 charset, etc. The name is in this format:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
570
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
571 FOUNDRY-FAMILY-WEIGHT-SLANT-WIDTH-STYLE-PIXEL-POINT-X-Y-SPACE-AVE-CR-CE
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
572
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
573 Each field means:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
574
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
575 - FOUNDRY: FOUNDRY field. The company that created the font.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
576 - FAMILY: FAMILY_NAME field. Basic font family name. (helvetica, gothic,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
577 times, etc)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
578 - WEIGHT: WEIGHT_NAME field. How thick the letters are. (light, medium,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
579 bold, etc)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
580 - SLANT: SLANT field.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
581 r: Roman (no slant)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
582 i: Italic
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
583 o: Oblique
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
584 ri: Reverse Italic
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
585 ro: Reverse Oblique
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
586 ot: Other
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
587 number: Scaled font
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
588 - WIDTH: SETWIDTH_NAME field. Width of characters. (normal, condensed,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
589 narrow, double wide)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
590 - STYLE: ADD_STYLE_NAME field. Extra info to describe font. (Serif, Sans
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
591 Serif, Informal, Decorated, etc)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
592 - PIXEL: PIXEL_SIZE field. Height, in pixels, of characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
593 - POINT: POINT_SIZE field. Ten times height of characters in points.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
594 - X: RESOLUTION_X field. X resolution (dots per inch).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
595 - Y: RESOLUTION_Y field. Y resolution (dots per inch).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
596 - SPACE: SPACING field.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
597 p: Proportional
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
598 m: Monospaced
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
599 c: CharCell
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
600 - AVE: AVERAGE_WIDTH field. Ten times average width in pixels.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
601 - CR: CHARSET_REGISTRY field. The name of the charset group.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
602 - CE: CHARSET_ENCODING field. The rest of the charset name. For some
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
603 charsets, such as JIS X 0208, if this field is 0, code points has
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
604 the same value as GL, and GR if 1.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
605
3682
11d40fc82f11 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3410
diff changeset
606 For example, in case of a 16 dots font corresponding to JIS X 0208, it is
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
607 written like:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
608 -misc-fixed-medium-r-normal--16-110-100-100-c-160-jisx0208.1990-0
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
609
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
610
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
611 X FONTSET
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
612 *fontset* *xfontset*
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
613 A single-byte charset is typically associated with one font. For multibyte
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
614 charsets a combination of fonts is often used. This means that one group of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
615 characters are used from one font and another group from another font (which
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
616 might be double wide). This collection of fonts is called a fontset.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
617
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
618 Which fonts are required in a fontset depends on the current locale. X
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
619 windows maintains a table of which groups of characters are required for a
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
620 locale. You have to specify all the fonts that a locale requires in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
621 'guifontset' option.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
622
16439
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
623 Setting the 'guifontset' option also means that all font names will be handled
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
624 as a fontset name. Also the ones used for the "font" argument of the
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
625 |:highlight| command.
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
626
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
627 Note the difference between 'guifont' and 'guifontset': In 'guifont'
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
628 the comma-separated names are alternative names, one of which will be
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
629 used. In 'guifontset' the whole string is one fontset name,
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
630 including the commas. It is not possible to specify alternative
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
631 fontset names.
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
632 This example works on many X11 systems: >
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
633 :set guifontset=-*-*-medium-r-normal--16-*-*-*-c-*-*-*
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
634 <
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
635 The fonts must match with the current locale. If fonts for the character sets
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
636 that the current locale uses are not included, setting 'guifontset' will fail.
9d20e26dc13c patch 8.1.1224: MS-Windows: cannot specify font weight
Bram Moolenaar <Bram@vim.org>
parents: 15878
diff changeset
637
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
638 NOTE: The fontset always uses the current locale, even though 'encoding' may
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
639 be set to use a different charset. In that situation you might want to use
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
640 'guifont' and 'guifontwide' instead of 'guifontset'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
641
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
642 Example:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
643 |charset| language "groups of characters" ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
644 GB2312 Chinese (simplified) ISO-8859-1 and GB 2312
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
645 Big5 Chinese (traditional) ISO-8859-1 and Big5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
646 CNS-11643 Chinese (traditional) ISO-8859-1, CNS 11643-1 and CNS 11643-2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
647 EUC-JP Japanese JIS X 0201 and JIS X 0208
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
648 EUC-KR Korean ISO-8859-1 and KS C 5601 (KS X 1001)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
649
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
650 You can search for fonts using the xlsfonts command. For example, when you're
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
651 searching for a font for KS C 5601: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
652 xlsfonts | grep ksc5601
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
653
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
654 This is complicated and confusing. You might want to consult the X-Windows
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
655 documentation if there is something you don't understand.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
656
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
657 *base_font_name_list*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
658 When you have found the names of the fonts you want to use, you need to set
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
659 the 'guifontset' option. You specify the list by concatenating the font names
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
660 and putting a comma in between them.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
661
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
662 For example, when you use the ja_JP.eucJP locale, this requires JIS X 0201
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
663 and JIS X 0208. You could supply a list of fonts that explicitly specifies
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
664 the charsets, like: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
665
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
666 :set guifontset=-misc-fixed-medium-r-normal--14-130-75-75-c-140-jisx0208.1983-0,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
667 \-misc-fixed-medium-r-normal--14-130-75-75-c-70-jisx0201.1976-0
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
668
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
669 Alternatively, you can supply a base font name list that omits the charset
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
670 name, letting X-Windows select font characters required for the locale. For
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
671 example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
672
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
673 :set guifontset=-misc-fixed-medium-r-normal--14-130-75-75-c-140,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
674 \-misc-fixed-medium-r-normal--14-130-75-75-c-70
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
675
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
676 Alternatively, you can supply a single base font name that allows X-Windows to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
677 select from all available fonts. For example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
678
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
679 :set guifontset=-misc-fixed-medium-r-normal--14-*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
680
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
681 Alternatively, you can specify alias names. See the fonts.alias file in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
682 fonts directory (e.g., /usr/X11R6/lib/X11/fonts/). For example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
683
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
684 :set guifontset=k14,r14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
685 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
686 *E253*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
687 Note that in East Asian fonts, the standard character cell is square. When
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
688 mixing a Latin font and an East Asian font, the East Asian font width should
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
689 be twice the Latin font width.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
690
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
691 If 'guifontset' is not empty, the "font" argument of the |:highlight| command
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
692 is also interpreted as a fontset. For example, you should use for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
693 highlighting: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
694 :hi Comment font=english_font,your_font
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
695 If you use a wrong "font" argument you will get an error message.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
696 Also make sure that you set 'guifontset' before setting fonts for highlight
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
697 groups.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
698
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
699
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
700 USING RESOURCE FILES
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
701
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
702 Instead of specifying 'guifontset', you can set X11 resources and Vim will
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
703 pick them up. This is only for people who know how X resource files work.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
704
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
705 For Motif and Athena insert these three lines in your $HOME/.Xdefaults file:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
706
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
707 Vim.font: |base_font_name_list|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
708 Vim*fontSet: |base_font_name_list|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
709 Vim*fontList: your_language_font
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
710
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
711 Note: Vim.font is for text area.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
712 Vim*fontSet is for menu.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
713 Vim*fontList is for menu (for Motif GUI)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
714
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
715 For example, when you are using Japanese and a 14 dots font, >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
716
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
717 Vim.font: -misc-fixed-medium-r-normal--14-*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
718 Vim*fontSet: -misc-fixed-medium-r-normal--14-*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
719 Vim*fontList: -misc-fixed-medium-r-normal--14-*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
720 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
721 or: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
722
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
723 Vim*font: k14,r14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
724 Vim*fontSet: k14,r14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
725 Vim*fontList: k14,r14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
726 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
727 To have them take effect immediately you will have to do >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
728
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
729 xrdb -merge ~/.Xdefaults
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
730
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
731 Otherwise you will have to stop and restart the X server before the changes
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
732 take effect.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
733
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
734
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
735 The GTK+ version of GUI Vim does not use .Xdefaults, use ~/.gtkrc instead.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
736 The default mostly works OK. But for the menus you might have to change
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
737 it. Example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
738
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
739 style "default"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
740 {
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
741 fontset="-*-*-medium-r-normal--14-*-*-*-c-*-*-*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
742 }
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
743 widget_class "*" style "default"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
744
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
745 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
746 6. Fonts on MS-Windows *mbyte-fonts-MSwin*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
747
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
748 The simplest is to use the font dialog to select fonts and try them out. You
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
749 can find this at the "Edit/Select Font..." menu. Once you find a font name
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
750 that works well you can use this command to see its name: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
751
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
752 :set guifont
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
753
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
754 Then add a command to your |gvimrc| file to set 'guifont': >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
755
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
756 :set guifont=courier_new:h12
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
757
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
758 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
759 7. Input on X11 *mbyte-XIM*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
760
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
761 X INPUT METHOD (XIM) BACKGROUND *XIM* *xim* *x-input-method*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
762
2207
b17bbfa96fa0 Add the settabvar() and gettabvar() functions.
Bram Moolenaar <bram@vim.org>
parents: 2154
diff changeset
763 XIM is an international input module for X. There are two kinds of structures,
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
764 Xlib unit type and |IM-server| (Input-Method server) type. |IM-server| type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
765 is suitable for complex input, such as CJK.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
766
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
767 - IM-server
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
768 *IM-server*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
769 In |IM-server| type input structures, the input event is handled by either
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
770 of the two ways: FrontEnd system and BackEnd system. In the FrontEnd
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
771 system, input events are snatched by the |IM-server| first, then |IM-server|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
772 give the application the result of input. On the other hand, the BackEnd
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
773 system works reverse order. MS Windows adopt BackEnd system. In X, most of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
774 |IM-server|s adopt FrontEnd system. The demerit of BackEnd system is the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
775 large overhead in communication, but it provides safe synchronization with
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
776 no restrictions on applications.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
777
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
778 For example, there are xwnmo and kinput2 Japanese |IM-server|, both are
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
779 FrontEnd system. Xwnmo is distributed with Wnn (see below), kinput2 can be
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
780 found at: ftp://ftp.sra.co.jp/pub/x11/kinput2/
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
781
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
782 For Chinese, there's a great XIM server named "xcin", you can input both
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
783 Traditional and Simplified Chinese characters. And it can accept other
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
784 locale if you make a correct input table. Xcin can be found at:
2236
dc2e5ec0500d Added the undofile() function. Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2207
diff changeset
785 http://cle.linux.org.tw/xcin/
15
631143ac4a01 updated for version 7.0007
vimboss
parents: 12
diff changeset
786 Others are scim: http://scim.freedesktop.org/ and fcitx:
856
8cd729851562 updated for version 7.0g
vimboss
parents: 842
diff changeset
787 http://www.fcitx.org/
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
788
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
789 - Conversion Server
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
790 *conversion-server*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
791 Some system needs additional server: conversion server. Most of Japanese
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
792 |IM-server|s need it, Kana-Kanji conversion server. For Chinese inputting,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
793 it depends on the method of inputting, in some methods, PinYin or ZhuYin to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
794 HanZi conversion server is needed. For Korean inputting, if you want to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
795 input Hanja, Hangul-Hanja conversion server is needed.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
796
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
797 For example, the Japanese inputting process is divided into 2 steps. First
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
798 we pre-input Hira-gana, second Kana-Kanji conversion. There are so many
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
799 Kanji characters (6349 Kanji characters are defined in JIS X 0208) and the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
800 number of Hira-gana characters are 76. So, first, we pre-input text as
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
801 pronounced in Hira-gana, second, we convert Hira-gana to Kanji or Kata-Kana,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
802 if needed. There are some Kana-Kanji conversion server: jserver
3153
37ecb8ff4560 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2965
diff changeset
803 (distributed with Wnn, see below) and canna. Canna can be found at:
37ecb8ff4560 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2965
diff changeset
804 http://canna.sourceforge.jp/
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
805
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
806 There is a good input system: Wnn4.2. Wnn 4.2 contains,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
807 xwnmo (|IM-server|)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
808 jserver (Japanese Kana-Kanji conversion server)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
809 cserver (Chinese PinYin or ZhuYin to simplified HanZi conversion server)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
810 tserver (Chinese PinYin or ZhuYin to traditional HanZi conversion server)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
811 kserver (Hangul-Hanja conversion server)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
812 Wnn 4.2 for several systems can be found at various places on the internet.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
813 Use the RPM or port for your system.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
814
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
815
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
816 - Input Style
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
817 *xim-input-style*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
818 When inputting CJK, there are four areas:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
819 1. The area to display of the input while it is being composed
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
820 2. The area to display the currently active input mode.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
821 3. The area to display the next candidate for the selection.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
822 4. The area to display other tools.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
823
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
824 The third area is needed when converting. For example, in Japanese
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
825 inputting, multiple Kanji characters could have the same pronunciation, so
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
826 a sequence of Hira-gana characters could map to a distinct sequence of Kanji
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
827 characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
828
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
829 The first and second areas are defined in international input of X with the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
830 names of "Preedit Area", "Status Area" respectively. The third and fourth
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
831 areas are not defined and are left to be managed by the |IM-server|. In the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
832 international input, four input styles have been defined using combinations
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
833 of Preedit Area and Status Area: |OnTheSpot|, |OffTheSpot|, |OverTheSpot|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
834 and |Root|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
835
2207
b17bbfa96fa0 Add the settabvar() and gettabvar() functions.
Bram Moolenaar <bram@vim.org>
parents: 2154
diff changeset
836 Currently, GUI Vim supports three styles, |OverTheSpot|, |OffTheSpot| and
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
837 |Root|.
12293
1ff5e5dfa9b0 patch 8.0.1026: GTK on-the-spot input has problems
Christian Brabandt <cb@256bit.org>
parents: 10198
diff changeset
838 When compiled with |+GUI_GTK| feature, GUI Vim supports two styles,
1ff5e5dfa9b0 patch 8.0.1026: GTK on-the-spot input has problems
Christian Brabandt <cb@256bit.org>
parents: 10198
diff changeset
839 |OnTheSpot| and |OverTheSpot|. You can select the style with the 'imstyle'
1ff5e5dfa9b0 patch 8.0.1026: GTK on-the-spot input has problems
Christian Brabandt <cb@256bit.org>
parents: 10198
diff changeset
840 option.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
841
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
842 *. on-the-spot *OnTheSpot*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
843 Preedit Area and Status Area are performed by the client application in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
844 the area of application. The client application is directed by the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
845 |IM-server| to display all pre-edit data at the location of text
236
4707450c2b33 updated for version 7.0066
vimboss
parents: 167
diff changeset
846 insertion. The client registers callbacks invoked by the input method
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
847 during pre-editing.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
848 *. over-the-spot *OverTheSpot*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
849 Status Area is created in a fixed position within the area of application,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
850 in case of Vim, the position is the additional status line. Preedit Area
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
851 is made at present input position of application. The input method
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
852 displays pre-edit data in a window which it brings up directly over the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
853 text insertion position.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
854 *. off-the-spot *OffTheSpot*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
855 Preedit Area and Status Area are performed in the area of application, in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
856 case of Vim, the area is additional status line. The client application
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
857 provides display windows for the pre-edit data to the input method which
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
858 displays into them directly.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
859 *. root-window *Root*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
860 Preedit Area and Status Area are outside of the application. The input
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
861 method displays all pre-edit data in a separate area of the screen in a
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
862 window specific to the input method.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
863
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
864
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
865 USING XIM *multibyte-input* *E284* *E286* *E287* *E288*
3410
94601b379f38 Updated runtime files. Add Dutch translations.
Bram Moolenaar <bram@vim.org>
parents: 3153
diff changeset
866 *E285* *E289*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
867
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
868 Note that Display and Input are independent. It is possible to see your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
869 language even though you have no input method for it. But when your Display
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
870 method doesn't match your Input method, the text will be displayed wrong.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
871
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
872 Note: You can not use IM unless you specify 'guifontset'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
873 Therefore, Latin users, you have to also use 'guifontset'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
874 if you use IM.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
875
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
876 To input your language you should run the |IM-server| which supports your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
877 language and |conversion-server| if needed.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
878
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
879 The next 3 lines should be put in your ~/.Xdefaults file. They are common for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
880 all X applications which uses |XIM|. If you already use |XIM|, you can skip
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
881 this. >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
882
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
883 *international: True
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
884 *.inputMethod: your_input_server_name
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
885 *.preeditType: your_input_style
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
886 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
887 input_server_name is your |IM-server| name (check your |IM-server|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
888 manual).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
889 your_input_style is one of |OverTheSpot|, |OffTheSpot|, |Root|. See
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
890 also |xim-input-style|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
891
21499
3a1ed539ae2a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 18879
diff changeset
892 *international may not be necessary if you use X11R6.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
893 *.inputMethod and *.preeditType are optional if you use X11R6.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
894
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
895 For example, when you are using kinput2 as |IM-server|, >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
896
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
897 *international: True
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
898 *.inputMethod: kinput2
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
899 *.preeditType: OverTheSpot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
900 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
901 When using |OverTheSpot|, GUI Vim always connects to the IM Server even in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
902 Normal mode, so you can input your language with commands like "f" and "r".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
903 But when using one of the other two methods, GUI Vim connects to the IM Server
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
904 only if it is not in Normal mode.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
905
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
906 If your IM Server does not support |OverTheSpot|, and if you want to use your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
907 language with some Normal mode command like "f" or "r", then you should use a
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
908 localized xterm or an xterm which supports |XIM|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
909
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
910 If needed, you can set the XMODIFIERS environment variable:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
911
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
912 sh: export XMODIFIERS="@im=input_server_name"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
913 csh: setenv XMODIFIERS "@im=input_server_name"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
914
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
915 For example, when you are using kinput2 as |IM-server| and sh, >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
916
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
917 export XMODIFIERS="@im=kinput2"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
918 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
919
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
920 FULLY CONTROLLED XIM
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
921
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
922 You can fully control XIM, like with IME of MS-Windows (see |multibyte-ime|).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
923 This is currently only available for the GTK GUI.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
924
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
925 Before using fully controlled XIM, one setting is required. Set the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
926 'imactivatekey' option to the key that is used for the activation of the input
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
927 method. For example, when you are using kinput2 + canna as IM Server, the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
928 activation key is probably Shift+Space: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
929
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
930 :set imactivatekey=S-space
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
931
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
932 See 'imactivatekey' for the format.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
933
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
934 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
935 8. Input on MS-Windows *mbyte-IME*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
936
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
937 (Windows IME support) *multibyte-ime* *IME*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
938
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
939 {only works Windows GUI and compiled with the |+multi_byte_ime| feature}
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
940
2415
8f017e31750f Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2413
diff changeset
941 To input multibyte characters on Windows, you can use an Input Method Editor
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
942 (IME). In process of your editing text, you must switch status (on/off) of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
943 IME many many many times. Because IME with status on is hooking all of your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
944 key inputs, you cannot input 'j', 'k', or almost all of keys to Vim directly.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
945
17372
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
946 The |+multi_byte_ime| feature helps for this. It reduces the number of times
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
947 the IME status has to be switched manually. In Normal mode, there is almost
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
948 no need to use IME, even when editing multibyte text. So when exiting Insert
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
949 mode, Vim memorizes the last status of IME and turns off IME. When
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
950 re-entering Insert mode, Vim sets the IME status to that memorized status
b9bc47742df6 Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 16553
diff changeset
951 automatically.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
952
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
953 This works on not only insert-normal mode, but also search-command input and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
954 replace mode.
21499
3a1ed539ae2a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 18879
diff changeset
955 The options 'iminsert', 'imsearch' and 'imcmdline' can be used to choose
9
4102fb4ea781 updated for version 7.0002
vimboss
parents: 7
diff changeset
956 the different input methods or disable them temporarily.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
957
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
958 WHAT IS IME
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
959 IME is a part of East asian version Windows. That helps you to input
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
960 multibyte character. English and other language version Windows does not
2355
84c7eeeb09e2 Fix typos in documentation. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents: 2345
diff changeset
961 have any IME. (Also there is no need usually.) But there is one that
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
962 called Microsoft Global IME. Global IME is a part of Internet Explorer
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
963 4.0 or above. You can get more information about Global IME, at below
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
964 URL.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
965
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
966 WHAT IS GLOBAL IME *global-ime*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
967 Global IME makes capability to input Chinese, Japanese, and Korean text
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
968 into Vim buffer on any language version of Windows 98, Windows 95, and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
969 Windows NT 4.0.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
970 On Windows 2000 and XP it should work as well (without downloading). On
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
971 Windows 2000 Professional, Global IME is built in, and the Input Locales
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
972 can be added through Control Panel/Regional Options/Input Locales.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
973 Please see below URL for detail of Global IME. You can also find various
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
974 language version of Global IME at same place.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
975
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
976 - Global IME detailed information.
2236
dc2e5ec0500d Added the undofile() function. Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2207
diff changeset
977 http://search.microsoft.com/results.aspx?q=global+ime
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
978
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
979 - Active Input Method Manager (Global IME)
2236
dc2e5ec0500d Added the undofile() function. Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2207
diff changeset
980 http://msdn.microsoft.com/en-us/library/aa741221(v=VS.85).aspx
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
981
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
982 Support for Global IME is an experimental feature.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
983
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
984 NOTE: For IME to work you must make sure the input locales of your language
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
985 are added to your system. The exact location of this depends on the version
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
986 of Windows you use. For example, on my Windows 2000 box:
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
987 1. Control Panel
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
988 2. Regional Options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
989 3. Input Locales Tab
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
990 4. Add Installed input locales -> Chinese(PRC)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
991 The default is still English (United Stated)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
992
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
993
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
994 Cursor color when IME or XIM is on *CursorIM*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
995 There is a little cute feature for IME. Cursor can indicate status of IME
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
996 by changing its color. Usually status of IME was indicated by little icon
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
997 at a corner of desktop (or taskbar). It is not easy to verify status of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
998 IME. But this feature help this.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
999 This works in the same way when using XIM.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1000
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1001 You can select cursor color when status is on by using highlight group
819
23f82b5d2814 updated for version 7.0c10
vimboss
parents: 818
diff changeset
1002 CursorIM. For example, add these lines to your |gvimrc|: >
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1003
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1004 if has('multi_byte_ime')
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1005 highlight Cursor guifg=NONE guibg=Green
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1006 highlight CursorIM guifg=NONE guibg=Purple
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1007 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1008 <
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1009 Cursor color with off IME is green. And purple cursor indicates that
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1010 status is on.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1011
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1012 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1013 9. Input with a keymap *mbyte-keymap*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1014
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1015 When the keyboard doesn't produce the characters you want to enter in your
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1016 text, you can use the 'keymap' option. This will translate one or more
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1017 (English) characters to another (non-English) character. This only happens
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1018 when typing text, not when typing Vim commands. This avoids having to switch
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1019 between two keyboard settings.
9644
9f7bcc2c3b97 commit https://github.com/vim/vim/commit/6f1d9a096bf22d50c727dca73abbfb8e3ff55176
Christian Brabandt <cb@256bit.org>
parents: 5294
diff changeset
1020 {only available when compiled with the |+keymap| feature}
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1021
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1022 The value of the 'keymap' option specifies a keymap file to use. The name of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1023 this file is one of these two:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1024
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1025 keymap/{keymap}_{encoding}.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1026 keymap/{keymap}.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1027
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1028 Here {keymap} is the value of the 'keymap' option and {encoding} of the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1029 'encoding' option. The file name with the {encoding} included is tried first.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1030
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1031 'runtimepath' is used to find these files. To see an overview of all
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1032 available keymap files, use this: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1033 :echo globpath(&rtp, "keymap/*.vim")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1034
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1035 In Insert and Command-line mode you can use CTRL-^ to toggle between using the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1036 keyboard map or not. |i_CTRL-^| |c_CTRL-^|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1037 This flag is remembered for Insert mode with the 'iminsert' option. When
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1038 leaving and entering Insert mode the previous value is used. The same value
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1039 is also used for commands that take a single character argument, like |f| and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1040 |r|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1041 For Command-line mode the flag is NOT remembered. You are expected to type an
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1042 Ex command first, which is ASCII.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1043 For typing search patterns the 'imsearch' option is used. It can be set to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1044 use the same value as for 'iminsert'.
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1045 *lCursor*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1046 It is possible to give the GUI cursor another color when the language mappings
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1047 are being used. This is disabled by default, to avoid that the cursor becomes
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1048 invisible when you use a non-standard background color. Here is an example to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1049 use a brightly colored cursor: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1050 :highlight Cursor guifg=NONE guibg=Green
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1051 :highlight lCursor guifg=NONE guibg=Cyan
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1052 <
839
1f3b1021f002 updated for version 7.0e05
vimboss
parents: 834
diff changeset
1053 *keymap-file-format* *:loadk* *:loadkeymap* *E105* *E791*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1054 The keymap file looks something like this: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1055
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1056 " Maintainer: name <email@address>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1057 " Last Changed: 2001 Jan 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1058
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1059 let b:keymap_name = "short"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1060
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1061 loadkeymap
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1062 a A
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1063 b B comment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1064
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1065 The lines starting with a " are comments and will be ignored. Blank lines are
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1066 also ignored. The lines with the mappings may have a comment after the useful
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1067 text.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1068
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1069 The "b:keymap_name" can be set to a short name, which will be shown in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1070 status line. The idea is that this takes less room than the value of
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1071 'keymap', which might be long to distinguish between different languages,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1072 keyboards and encodings.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1073
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1074 The actual mappings are in the lines below "loadkeymap". In the example "a"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1075 is mapped to "A" and "b" to "B". Thus the first item is mapped to the second
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1076 item. This is done for each line, until the end of the file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1077 These items are exactly the same as what can be used in a |:lnoremap| command,
4186
7ffc704cb7c1 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3893
diff changeset
1078 using "<buffer>" to make the mappings local to the buffer.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1079 You can check the result with this command: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1080 :lmap
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1081 The two items must be separated by white space. You cannot include white
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1082 space inside an item, use the special names "<Tab>" and "<Space>" instead.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1083 The length of the two items together must not exceed 200 bytes.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1084
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1085 It's possible to have more than one character in the first column. This works
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1086 like a dead key. Example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1087 'a á
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1088 Since Vim doesn't know if the next character after a quote is really an "a",
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1089 it will wait for the next character. To be able to insert a single quote,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1090 also add this line: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1091 '' '
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1092 Since the mapping is defined with |:lnoremap| the resulting quote will not be
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1093 used for the start of another character.
818
1f929f3ca806 updated for version 7.0c03
vimboss
parents: 810
diff changeset
1094 The "accents" keymap uses this. *keymap-accents*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1095
3893
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1096 The first column can also be in |<>| form:
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1097 <C-c> Ctrl-C
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1098 <A-c> Alt-c
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1099 <A-C> Alt-C
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1100 Note that the Alt mappings may not work, depending on your keyboard and
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1101 terminal.
c3036f1dca68 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 3682
diff changeset
1102
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1103 Although it's possible to have more than one character in the second column,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1104 this is unusual. But you can use various ways to specify the character: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1105 A a literal character
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1106 A <char-97> decimal value
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1107 A <char-0x61> hexadecimal value
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1108 A <char-0141> octal value
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1109 x <Space> special key name
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1110
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1111 The characters are assumed to be encoded for the current value of 'encoding'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1112 It's possible to use ":scriptencoding" when all characters are given
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1113 literally. That doesn't work when using the <char-> construct, because the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1114 conversion is done on the keymap file, not on the resulting character.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1115
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1116 The lines after "loadkeymap" are interpreted with 'cpoptions' set to "C".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1117 This means that continuation lines are not used and a backslash has a special
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1118 meaning in the mappings. Examples: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1119
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1120 " a comment line
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1121 \" x maps " to x
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1122 \\ y maps \ to y
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1123
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1124 If you write a keymap file that will be useful for others, consider submitting
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1125 it to the Vim maintainer for inclusion in the distribution:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1126 <maintainer@vim.org>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1127
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1128
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1129 HEBREW KEYMAP *keymap-hebrew*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1130
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1131 This file explains what characters are available in UTF-8 and CP1255 encodings,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1132 and what the keymaps are to get those characters:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1133
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1134 glyph encoding keymap ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1135 Char utf-8 cp1255 hebrew hebrewp name ~
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1136 א 0x5d0 0xe0 t a 'alef
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1137 ב 0x5d1 0xe1 c b bet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1138 ג 0x5d2 0xe2 d g gimel
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1139 ד 0x5d3 0xe3 s d dalet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1140 ה 0x5d4 0xe4 v h he
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1141 ו 0x5d5 0xe5 u v vav
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1142 ז 0x5d6 0xe6 z z zayin
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1143 ח 0x5d7 0xe7 j j het
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1144 ט 0x5d8 0xe8 y T tet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1145 י 0x5d9 0xe9 h y yod
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1146 ך 0x5da 0xea l K kaf sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1147 כ 0x5db 0xeb f k kaf
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1148 ל 0x5dc 0xec k l lamed
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1149 ם 0x5dd 0xed o M mem sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1150 מ 0x5de 0xee n m mem
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1151 ן 0x5df 0xef i N nun sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1152 נ 0x5e0 0xf0 b n nun
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1153 ס 0x5e1 0xf1 x s samech
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1154 ע 0x5e2 0xf2 g u `ayin
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1155 ף 0x5e3 0xf3 ; P pe sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1156 פ 0x5e4 0xf4 p p pe
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1157 ץ 0x5e5 0xf5 . X tsadi sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1158 צ 0x5e6 0xf6 m x tsadi
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1159 ק 0x5e7 0xf7 e q qof
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1160 ר 0x5e8 0xf8 r r resh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1161 ש 0x5e9 0xf9 a w shin
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1162 ת 0x5ea 0xfa , t tav
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1163
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1164 Vowel marks and special punctuation:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1165 הְ 0x5b0 0xc0 A: A: sheva
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1166 הֱ 0x5b1 0xc1 HE HE hataf segol
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1167 הֲ 0x5b2 0xc2 HA HA hataf patah
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1168 הֳ 0x5b3 0xc3 HO HO hataf qamats
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1169 הִ 0x5b4 0xc4 I I hiriq
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1170 הֵ 0x5b5 0xc5 AY AY tsere
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1171 הֶ 0x5b6 0xc6 E E segol
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1172 הַ 0x5b7 0xc7 AA AA patah
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1173 הָ 0x5b8 0xc8 AO AO qamats
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1174 הֹ 0x5b9 0xc9 O O holam
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1175 הֻ 0x5bb 0xcb U U qubuts
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1176 כּ 0x5bc 0xcc D D dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1177 הֽ 0x5bd 0xcd ]T ]T meteg
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1178 ה־ 0x5be 0xce ]Q ]Q maqaf
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1179 בֿ 0x5bf 0xcf ]R ]R rafe
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1180 ב׀ 0x5c0 0xd0 ]p ]p paseq
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1181 שׁ 0x5c1 0xd1 SR SR shin-dot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1182 שׂ 0x5c2 0xd2 SL SL sin-dot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1183 ׃ 0x5c3 0xd3 ]P ]P sof-pasuq
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1184 װ 0x5f0 0xd4 VV VV double-vav
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1185 ױ 0x5f1 0xd5 VY VY vav-yod
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1186 ײ 0x5f2 0xd6 YY YY yod-yod
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1187
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1188 The following are only available in utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1189
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1190 Cantillation marks:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1191 glyph
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1192 Char utf-8 hebrew name
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1193 ב֑ 0x591 C: etnahta
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1194 ב֒ 0x592 Cs segol
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1195 ב֓ 0x593 CS shalshelet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1196 ב֔ 0x594 Cz zaqef qatan
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1197 ב֕ 0x595 CZ zaqef gadol
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1198 ב֖ 0x596 Ct tipeha
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1199 ב֗ 0x597 Cr revia
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1200 ב֘ 0x598 Cq zarqa
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1201 ב֙ 0x599 Cp pashta
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1202 ב֚ 0x59a C! yetiv
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1203 ב֛ 0x59b Cv tevir
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1204 ב֜ 0x59c Cg geresh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1205 ב֝ 0x59d C* geresh qadim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1206 ב֞ 0x59e CG gershayim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1207 ב֟ 0x59f CP qarnei-parah
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1208 ב֪ 0x5aa Cy yerach-ben-yomo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1209 ב֫ 0x5ab Co ole
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1210 ב֬ 0x5ac Ci iluy
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1211 ב֭ 0x5ad Cd dehi
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1212 ב֮ 0x5ae Cn zinor
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1213 ב֯ 0x5af CC masora circle
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1214
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1215 Combining forms:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1216 ﬠ 0xfb20 X` Alternative `ayin
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1217 ﬡ 0xfb21 X' Alternative 'alef
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1218 ﬢ 0xfb22 X-d Alternative dalet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1219 ﬣ 0xfb23 X-h Alternative he
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1220 ﬤ 0xfb24 X-k Alternative kaf
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1221 ﬥ 0xfb25 X-l Alternative lamed
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1222 ﬦ 0xfb26 X-m Alternative mem-sofit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1223 ﬧ 0xfb27 X-r Alternative resh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1224 ﬨ 0xfb28 X-t Alternative tav
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1225 ﬩ 0xfb29 X-+ Alternative plus
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1226 שׁ 0xfb2a XW shin+shin-dot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1227 שׂ 0xfb2b Xw shin+sin-dot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1228 שּׁ 0xfb2c X..W shin+shin-dot+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1229 שּׂ 0xfb2d X..w shin+sin-dot+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1230 אַ 0xfb2e XA alef+patah
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1231 אָ 0xfb2f XO alef+qamats
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1232 אּ 0xfb30 XI alef+hiriq (mapiq)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1233 בּ 0xfb31 X.b bet+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1234 גּ 0xfb32 X.g gimel+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1235 דּ 0xfb33 X.d dalet+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1236 הּ 0xfb34 X.h he+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1237 וּ 0xfb35 Xu vav+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1238 זּ 0xfb36 X.z zayin+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1239 טּ 0xfb38 X.T tet+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1240 יּ 0xfb39 X.y yud+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1241 ךּ 0xfb3a X.K kaf sofit+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1242 כּ 0xfb3b X.k kaf+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1243 לּ 0xfb3c X.l lamed+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1244 מּ 0xfb3e X.m mem+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1245 נּ 0xfb40 X.n nun+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1246 סּ 0xfb41 X.s samech+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1247 ףּ 0xfb43 X.P pe sofit+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1248 פּ 0xfb44 X.p pe+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1249 צּ 0xfb46 X.x tsadi+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1250 קּ 0xfb47 X.q qof+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1251 רּ 0xfb48 X.r resh+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1252 שּ 0xfb49 X.w shin+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1253 תּ 0xfb4a X.t tav+dagesh
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1254 וֹ 0xfb4b Xo vav+holam
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1255 בֿ 0xfb4c XRb bet+rafe
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1256 כֿ 0xfb4d XRk kaf+rafe
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1257 פֿ 0xfb4e XRp pe+rafe
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1258 ﭏ 0xfb4f Xal alef-lamed
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1259
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1260 ==============================================================================
12920
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1261 10. Input with imactivatefunc() *mbyte-func*
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1262
12968
45987b1b77dc Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 12920
diff changeset
1263 Vim has the 'imactivatefunc' and 'imstatusfunc' options. These are useful to
13125
371ceeebbdaa Update runtime files.
Christian Brabandt <cb@256bit.org>
parents: 12968
diff changeset
1264 activate/deactivate the input method from Vim in any way, also with an external
12920
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1265 command. For example, fcitx provide fcitx-remote command: >
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1266
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1267 set iminsert=2
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1268 set imsearch=2
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1269 set imcmdline
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1270
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1271 set imactivatefunc=ImActivate
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1272 function! ImActivate(active)
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1273 if a:active
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1274 call system('fcitx-remote -o')
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1275 else
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1276 call system('fcitx-remote -c')
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1277 endif
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1278 endfunction
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1279
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1280 set imstatusfunc=ImStatus
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1281 function! ImStatus()
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1282 return system('fcitx-remote')[0] is# '2'
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1283 endfunction
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1284
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1285 Using this script, you can activate/deactivate XIM via Vim even when it is not
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1286 compiled with |+xim|.
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1287
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1288 ==============================================================================
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1289 11. Using UTF-8 *mbyte-utf8* *UTF-8* *utf-8* *utf8*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1290 *Unicode* *unicode*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1291 The Unicode character set was designed to include all characters from other
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1292 character sets. Therefore it is possible to write text in any language using
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1293 Unicode (with a few rarely used languages excluded). And it's mostly possible
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1294 to mix these languages in one file, which is impossible with other encodings.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1295
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1296 Unicode can be encoded in several ways. The most popular one is UTF-8, which
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1297 uses one or more bytes for each character and is backwards compatible with
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1298 ASCII. On MS-Windows UTF-16 is also used (previously UCS-2), which uses
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1299 16-bit words. Vim can support all of these encodings, but always uses UTF-8
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1300 internally.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1301
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1302 Vim has comprehensive UTF-8 support. It works well in:
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1303 - xterm with utf-8 support enabled
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1304 - Athena, Motif and GTK GUI
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1305 - MS-Windows GUI
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1306 - several other platforms
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1307
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1308 Double-width characters are supported. This works best with 'guifontwide' or
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1309 'guifontset'. When using only 'guifont' the wide characters are drawn in the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1310 normal width and a space to fill the gap. Note that the 'guifontset' option
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1311 is no longer relevant in the GTK+ 2 GUI.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1312
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1313 *bom-bytes*
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1314 When reading a file a BOM (Byte Order Mark) can be used to recognize the
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1315 Unicode encoding:
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1316 EF BB BF utf-8
2290
22529abcd646 Fixed ":s" message. Docs updates.
Bram Moolenaar <bram@vim.org>
parents: 2236
diff changeset
1317 FE FF utf-16 big endian
22529abcd646 Fixed ":s" message. Docs updates.
Bram Moolenaar <bram@vim.org>
parents: 2236
diff changeset
1318 FF FE utf-16 little endian
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1319 00 00 FE FF utf-32 big endian
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1320 FF FE 00 00 utf-32 little endian
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1321
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1322 Utf-8 is the recommended encoding. Note that it's difficult to tell utf-16
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1323 and utf-32 apart. Utf-16 is often used on MS-Windows, utf-32 is not
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1324 widespread as file format.
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1325
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1326
714
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1327 *mbyte-combining* *mbyte-composing*
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1328 A composing or combining character is used to change the meaning of the
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1329 character before it. The combining characters are drawn on top of the
856
8cd729851562 updated for version 7.0g
vimboss
parents: 842
diff changeset
1330 preceding character.
714
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1331 Up to two combining characters can be used by default. This can be changed
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1332 with the 'maxcombine' option.
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1333 When editing text a composing character is mostly considered part of the
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1334 preceding character. For example "x" will delete a character and its
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1335 following composing characters by default.
0f9f4761ad9c updated for version 7.0216
vimboss
parents: 557
diff changeset
1336 If the 'delcombine' option is on, then pressing 'x' will delete the combining
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1337 characters, one at a time, then the base character. But when inserting, you
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1338 type the first character and the following composing characters separately,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1339 after which they will be joined. The "r" command will not allow you to type a
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1340 combining character, because it doesn't know one is coming. Use "R" instead.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1341
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1342 Bytes which are not part of a valid UTF-8 byte sequence are handled like a
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1343 single character and displayed as <xx>, where "xx" is the hex value of the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1344 byte.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1345
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1346 Overlong sequences are not handled specially and displayed like a valid
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1347 character. However, search patterns may not match on an overlong sequence.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1348 (an overlong sequence is where more bytes are used than required for the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1349 character.) An exception is NUL (zero) which is displayed as "<00>".
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1350
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1351 In the file and buffer the full range of Unicode characters can be used (31
2965
f2de38a019a2 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2698
diff changeset
1352 bits). However, displaying only works for the characters present in the
f2de38a019a2 Updated runtime files.
Bram Moolenaar <bram@vim.org>
parents: 2698
diff changeset
1353 selected font.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1354
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1355 Useful commands:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1356 - "ga" shows the decimal, hexadecimal and octal value of the character under
236
4707450c2b33 updated for version 7.0066
vimboss
parents: 167
diff changeset
1357 the cursor. If there are composing characters these are shown too. (If the
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1358 message is truncated, use ":messages").
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1359 - "g8" shows the bytes used in a UTF-8 character, also the composing
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1360 characters, as hex numbers.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1361 - ":set encoding=utf-8 fileencodings=" forces using UTF-8 for all files. The
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1362 default is to use the current locale for 'encoding' and set 'fileencodings'
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 1257
diff changeset
1363 to automatically detect the encoding of a file.
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1364
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1365
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1366 STARTING VIM
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1367
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1368 If your current locale is in an utf-8 encoding, Vim will automatically start
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1369 in utf-8 mode.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1370
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1371 If you are using another locale: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1372
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1373 set encoding=utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1374
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1375 You might also want to select the font used for the menus. Unfortunately this
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1376 doesn't always work. See the system specific remarks below, and 'langmenu'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1377
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1378
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1379 USING UTF-8 IN X-Windows *utf-8-in-xwindows*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1380
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1381 Note: This section does not apply to the GTK+ 2 GUI.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1382
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1383 You need to specify a font to be used. For double-wide characters another
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1384 font is required, which is exactly twice as wide. There are three ways to do
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1385 this:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1386
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1387 1. Set 'guifont' and let Vim find a matching 'guifontwide'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1388 2. Set 'guifont' and 'guifontwide'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1389 3. Set 'guifontset'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1390
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1391 See the documentation for each option for details. Example: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1392
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1393 :set guifont=-misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1394
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1395 You might also want to set the font used for the menus. This only works for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1396 Motif. Use the ":hi Menu font={fontname}" command for this. |:highlight|
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1397
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1398
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1399 TYPING UTF-8 *utf-8-typing*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1400
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1401 If you are using X-Windows, you should find an input method that supports
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1402 utf-8.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1403
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1404 If your system does not provide support for typing utf-8, you can use the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1405 'keymap' feature. This allows writing a keymap file, which defines a utf-8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1406 character as a sequence of ASCII characters. See |mbyte-keymap|.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1407
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1408 Another method is to set the current locale to the language you want to use
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1409 and for which you have a XIM available. Then set 'termencoding' to that
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1410 language and Vim will convert the typed characters to 'encoding' for you.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1411
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1412 If everything else fails, you can type any character as four hex bytes: >
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1413
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1414 CTRL-V u 1234
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1415
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1416 "1234" is interpreted as a hex number. You must type four characters, prepend
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1417 a zero if necessary.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1418
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1419
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1420 COMMAND ARGUMENTS *utf-8-char-arg*
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1421
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1422 Commands like |f|, |F|, |t| and |r| take an argument of one character. For
167
c93c9cad9618 updated for version 7.0051
vimboss
parents: 39
diff changeset
1423 UTF-8 this argument may include one or two composing characters. These need
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1424 to be produced together with the base character, Vim doesn't wait for the next
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1425 character to be typed to find out if it is a composing character or not.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1426 Using 'keymap' or |:lmap| is a nice way to type these characters.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1427
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1428 The commands that search for a character in a line handle composing characters
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1429 as follows. When searching for a character without a composing character,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1430 this will find matches in the text with or without composing characters. When
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1431 searching for a character with a composing character, this will only find
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1432 matches with that composing character. It was implemented this way, because
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1433 not everybody is able to type a composing character.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1434
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1435
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1436 ==============================================================================
12920
327e1264b9bf patch 8.0.1336: cannot use imactivatefunc() unless compiled with +xim
Christian Brabandt <cb@256bit.org>
parents: 12293
diff changeset
1437 12. Overview of options *mbyte-options*
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1438
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
1439 These options are relevant for editing multibyte files. Check the help in
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1440 options.txt for detailed information.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1441
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1442 'encoding' Encoding used for the keyboard and display. It is also the
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1443 default encoding for files.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1444
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1445 'fileencoding' Encoding of a file. When it's different from 'encoding'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1446 conversion is done when reading or writing the file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1447
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1448 'fileencodings' List of possible encodings of a file. When opening a file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1449 these will be tried and the first one that doesn't cause an
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1450 error is used for 'fileencoding'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1451
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1452 'charconvert' Expression used to convert files from one encoding to another.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1453
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1454 'formatoptions' The 'm' flag can be included to have formatting break a line
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1455 at a multibyte character of 256 or higher. Thus is useful for
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1456 languages where a sequence of characters can be broken
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1457 anywhere.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1458
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
1459 'guifontset' The list of font names used for a multibyte encoding. When
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1460 this option is not empty, it replaces 'guifont'.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1461
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1462 'keymap' Specify the name of a keyboard mapping.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1463
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1464 ==============================================================================
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1465
21991
bbca88cd13d5 Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 21499
diff changeset
1466 Contributions specifically for the multibyte features by:
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1467 Chi-Deok Hwang <hwang@mizi.co.kr>
2033
de5a43c5eedc Update documentation files.
Bram Moolenaar <bram@zimbu.org>
parents: 1702
diff changeset
1468 SungHyun Nam <goweol@gmail.com>
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1469 K.Nagano <nagano@atese.advantest.co.jp>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1470 Taro Muraoka <koron@tka.att.ne.jp>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1471 Yasuhiro Matsumoto <mattn@mail.goo.ne.jp>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1472
14421
2f7e67dd088c Update runtime files.
Christian Brabandt <cb@256bit.org>
parents: 13963
diff changeset
1473 vim:tw=78:ts=8:noet:ft=help:norl: