1 Star 0 Fork 0

hilarryxu/vimdoc

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
os_dos.html 40.49 KB
一键复制 编辑 原始数据 按行查看 历史
hilarryxu 提交于 2017-08-15 10:58 . Init repo
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>os_dos - Vim Documentation</title>
<meta name="Generator" content="Vim/8.0">
<meta name="plugin-version" content="vim8.0">
<meta name="syntax" content="help">
<meta name="settings" content="no_pre,use_css,expand_tabs">
<link rel="stylesheet" href="style.css" type="text/css" />
<script src="jquery.min.js" type="text/javascript"></script>
<script src="mark-current-page.js" type="text/javascript"></script>
</head>
<body>
<header>
<div class="header">
<a href="http://vim-jp.org/">vim-jp</a>
/ <a href="http://vim-jp.org/vimdoc-en/">vimdoc-en</a>
/ os_dos<br />
<a name="top"></a><h1>os_dos - Vim Documentation</h1>
<a href="index.html">Return to main</a>
<span class="EnglishJapaneseLink">
<span class="CurrentLanguage">English</span>
</span>
</div>
</header>
<nav>
<dl>
<dt>BASIC</dt>
<dd><ul>
<li><a href="quickref.html">quickref</a></li>
<li><a href="sponsor.html">sponsor</a></li>
</ul></dd>
<dt>USER MANUAL</dt>
<dd><ul>
<li><a href="usr_toc.html">usr_toc</a></li>
</ul></dd>
<dt>Getting Started</dt>
<dd><ul>
<li><a href="usr_01.html">usr_01</a></li>
<li><a href="usr_02.html">usr_02</a></li>
<li><a href="usr_03.html">usr_03</a></li>
<li><a href="usr_04.html">usr_04</a></li>
<li><a href="usr_05.html">usr_05</a></li>
<li><a href="usr_06.html">usr_06</a></li>
<li><a href="usr_07.html">usr_07</a></li>
<li><a href="usr_08.html">usr_08</a></li>
<li><a href="usr_09.html">usr_09</a></li>
<li><a href="usr_10.html">usr_10</a></li>
<li><a href="usr_11.html">usr_11</a></li>
<li><a href="usr_12.html">usr_12</a></li>
</ul></dd>
<dt>Editing Effectively</dt>
<dd><ul>
<li><a href="usr_20.html">usr_20</a></li>
<li><a href="usr_21.html">usr_21</a></li>
<li><a href="usr_22.html">usr_22</a></li>
<li><a href="usr_23.html">usr_23</a></li>
<li><a href="usr_24.html">usr_24</a></li>
<li><a href="usr_25.html">usr_25</a></li>
<li><a href="usr_26.html">usr_26</a></li>
<li><a href="usr_27.html">usr_27</a></li>
<li><a href="usr_28.html">usr_28</a></li>
<li><a href="usr_29.html">usr_29</a></li>
<li><a href="usr_30.html">usr_30</a></li>
<li><a href="usr_31.html">usr_31</a></li>
<li><a href="usr_32.html">usr_32</a></li>
</ul></dd>
<dt>Tuning Vim</dt>
<dd><ul>
<li><a href="usr_40.html">usr_40</a></li>
<li><a href="usr_41.html">usr_41</a></li>
<li><a href="usr_42.html">usr_42</a></li>
<li><a href="usr_43.html">usr_43</a></li>
<li><a href="usr_44.html">usr_44</a></li>
<li><a href="usr_45.html">usr_45</a></li>
</ul></dd>
<dt>Making Vim Run</dt>
<dd><ul>
<li><a href="usr_90.html">usr_90</a></li>
</ul></dd>
<dt>General subjects</dt>
<dd><ul>
<li><a href="intro.html">intro</a></li>
<li><a href="index.html">help</a></li>
<li><a href="helphelp.html">helphelp</a></li>
<li><a href="vimindex.html">index</a></li>
<li><a href="tags.html">tags</a></li>
<li><a href="howto.html">howto</a></li>
<li><a href="tips.html">tips</a></li>
<li><a href="message.html">message</a></li>
<li><a href="quotes.html">quotes</a></li>
<li><a href="todo.html">todo</a></li>
<li><a href="debug.html">debug</a></li>
<li><a href="develop.html">develop</a></li>
<li><a href="uganda.html">uganda</a></li>
</ul></dd>
<dt>Basic editing</dt>
<dd><ul>
<li><a href="starting.html">starting</a></li>
<li><a href="editing.html">editing</a></li>
<li><a href="motion.html">motion</a></li>
<li><a href="scroll.html">scroll</a></li>
<li><a href="insert.html">insert</a></li>
<li><a href="change.html">change</a></li>
<li><a href="indent.html">indent</a></li>
<li><a href="undo.html">undo</a></li>
<li><a href="repeat.html">repeat</a></li>
<li><a href="visual.html">visual</a></li>
<li><a href="various.html">various</a></li>
<li><a href="recover.html">recover</a></li>
</ul></dd>
<dt>Advanced editing</dt>
<dd><ul>
<li><a href="cmdline.html">cmdline</a></li>
<li><a href="options.html">options</a></li>
<li><a href="pattern.html">pattern</a></li>
<li><a href="map.html">map</a></li>
<li><a href="tagsrch.html">tagsrch</a></li>
<li><a href="quickfix.html">quickfix</a></li>
<li><a href="windows.html">windows</a></li>
<li><a href="tabpage.html">tabpage</a></li>
<li><a href="syntax.html">syntax</a></li>
<li><a href="spell.html">spell</a></li>
<li><a href="diff.html">diff</a></li>
<li><a href="autocmd.html">autocmd</a></li>
<li><a href="filetype.html">filetype</a></li>
<li><a href="eval.html">eval</a></li>
<li><a href="channel.html">channel</a></li>
<li><a href="fold.html">fold</a></li>
</ul></dd>
<dt>Special issues</dt>
<dd><ul>
<li><a href="print.html">print</a></li>
<li><a href="remote.html">remote</a></li>
<li><a href="term.html">term</a></li>
<li><a href="digraph.html">digraph</a></li>
<li><a href="mbyte.html">mbyte</a></li>
<li><a href="mlang.html">mlang</a></li>
<li><a href="arabic.html">arabic</a></li>
<li><a href="farsi.html">farsi</a></li>
<li><a href="hebrew.html">hebrew</a></li>
<li><a href="russian.html">russian</a></li>
<li><a href="ft_ada.html">ft_ada</a></li>
<li><a href="ft_sql.html">ft_sql</a></li>
<li><a href="hangulin.html">hangulin</a></li>
<li><a href="rileft.html">rileft</a></li>
</ul></dd>
<dt>GUI</dt>
<dd><ul>
<li><a href="gui.html">gui</a></li>
<li><a href="gui_w32.html">gui_w32</a></li>
<li><a href="gui_x11.html">gui_x11</a></li>
</ul></dd>
<dt>Interfaces</dt>
<dd><ul>
<li><a href="if_cscop.html">if_cscop</a></li>
<li><a href="if_lua.html">if_lua</a></li>
<li><a href="if_mzsch.html">if_mzsch</a></li>
<li><a href="if_perl.html">if_perl</a></li>
<li><a href="if_pyth.html">if_pyth</a></li>
<li><a href="if_tcl.html">if_tcl</a></li>
<li><a href="if_ole.html">if_ole</a></li>
<li><a href="if_ruby.html">if_ruby</a></li>
<li><a href="debugger.html">debugger</a></li>
<li><a href="workshop.html">workshop</a></li>
<li><a href="netbeans.html">netbeans</a></li>
<li><a href="sign.html">sign</a></li>
</ul></dd>
<dt>Versions</dt>
<dd><ul>
<li><a href="vi_diff.html">vi_diff</a></li>
<li><a href="version4.html">version4</a></li>
<li><a href="version5.html">version5</a></li>
<li><a href="version6.html">version6</a></li>
<li><a href="version7.html">version7</a></li>
<li><a href="version8.html">version8</a></li>
</ul></dd>
<dt>Remarks about specific systems</dt>
<dd><ul>
<li><a href="os_390.html">os_390</a></li>
<li><a href="os_amiga.html">os_amiga</a></li>
<li><a href="os_beos.html">os_beos</a></li>
<li><a href="os_dos.html">os_dos</a></li>
<li><a href="os_mac.html">os_mac</a></li>
<li><a href="os_mint.html">os_mint</a></li>
<li><a href="os_msdos.html">os_msdos</a></li>
<li><a href="os_os2.html">os_os2</a></li>
<li><a href="os_qnx.html">os_qnx</a></li>
<li><a href="os_risc.html">os_risc</a></li>
<li><a href="os_unix.html">os_unix</a></li>
<li><a href="os_vms.html">os_vms</a></li>
<li><a href="os_win32.html">os_win32</a></li>
</ul></dd>
<dt>Standard plugins</dt>
<dd><ul>
<li><a href="pi_getscript.html">pi_getscript</a></li>
<li><a href="pi_gzip.html">pi_gzip</a></li>
<li><a href="pi_logipat.html">pi_logipat</a></li>
<li><a href="pi_netrw.html">pi_netrw</a></li>
<li><a href="pi_paren.html">pi_paren</a></li>
<li><a href="pi_tar.html">pi_tar</a></li>
<li><a href="pi_vimball.html">pi_vimball</a></li>
<li><a href="pi_zip.html">pi_zip</a></li>
</ul></dd>
<dt>Filetype plugins</dt>
<dd><ul>
<li><a href="pi_spec.html">pi_spec</a></li>
</ul></dd>
<dt>Others</dt>
<dd><ul>
<li><a href="vim_faq.html">vim_faq</a></li>
</ul></dd>
</dl>
</nav>
<article class="Vimdoc VimdocJa">
<div id='vimCodeElement'>
<a class="Constant" href="os_dos.html" name="os_dos.txt">os_dos.txt</a>&nbsp;&nbsp;&nbsp;&nbsp;For&nbsp;<span class="Identifier">Vim version 8.0.</span>&nbsp;&nbsp;Last change: 2006 Mar 30<br>
<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Identifier">VIM REFERENCE MANUAL&nbsp;&nbsp;&nbsp;&nbsp;by Bram Moolenaar</span><br>
<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos" name="dos">dos</a>&nbsp;<a class="Constant" href="os_dos.html#DOS" name="DOS">DOS</a><br>
This file documents the common particularities of the MS-DOS and Win32<br>
versions of Vim.&nbsp;&nbsp;Also see&nbsp;<a class="Identifier" href="os_win32.html">os_win32.txt</a>&nbsp;and&nbsp;<a class="Identifier" href="os_msdos.html">os_msdos.txt</a>.<br>
<br>
1. File locations&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-locations">dos-locations</a><br>
2. Using backslashes&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-backslash">dos-backslash</a><br>
3. Standard mappings&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-standard-mappings">dos-standard-mappings</a><br>
4. Screen output and colors&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-colors">dos-colors</a><br>
5. File formats&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-file-formats">dos-file-formats</a><br>
6. :cd command&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-:cd">dos-:cd</a><br>
7. Interrupting&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-CTRL-Break">dos-CTRL-Break</a><br>
8. Temp files&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-temp-files">dos-temp-files</a><br>
9. Shell option default&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="os_dos.html#dos-shell">dos-shell</a><br>
<br>
<span class="PreProc">==============================================================================</span><br>
1. File locations&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-locations" name="dos-locations">dos-locations</a><br>
<br>
If you keep the Vim executable in the directory that contains the help and<br>
syntax subdirectories, there is no need to do anything special for Vim to<br>
work.&nbsp;&nbsp;No registry entries or environment variables need to be set.&nbsp;&nbsp;Just make<br>
sure that the directory is in your search path, or use a shortcut on the<br>
desktop.<br>
<br>
Your vimrc files (&quot;_vimrc&quot; and &quot;_gvimrc&quot;) are normally located one directory<br>
up from the runtime files.&nbsp;&nbsp;If you want to put them somewhere else, set the<br>
environment variable $VIM to the directory where you keep them.&nbsp;&nbsp;Example:<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set VIM=C:\user\piet</div>
Will find &quot;c:\user\piet\_vimrc&quot;.<br>
<span class="Todo">Note</span>: This would only be needed when the computer is used by several people.<br>
Otherwise it's simpler to keep your _vimrc file in the default place.<br>
<br>
If you move the executable to another location, you also need to set the $VIM<br>
environment variable.&nbsp;&nbsp;The runtime files will be found in &quot;$VIM/vim<span class="Special">{version}</span>&quot;.<br>
Example:<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set VIM=E:\vim</div>
Will find the version 5.4 runtime files in &quot;e:\vim\vim54&quot;.<br>
<span class="Todo">Note</span>: This is _not_ recommended.&nbsp;&nbsp;The preferred way is to keep the executable<br>
in the runtime directory.<br>
<br>
If you move your executable AND want to put your &quot;_vimrc&quot; and &quot;_gvimrc&quot; files<br>
somewhere else, you must set $VIM to where you vimrc files are, and set<br>
$VIMRUNTIME to the runtime files.&nbsp;&nbsp;Example:<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set VIM=C:\usr\piet<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set VIMRUNTIME=E:\vim\vim54</div>
Will find &quot;c:\user\piet\_vimrc&quot; and the runtime files in &quot;e:\vim\vim54&quot;.<br>
<br>
See&nbsp;<a class="Identifier" href="starting.html#$VIM">$VIM</a>&nbsp;and&nbsp;<a class="Identifier" href="starting.html#$VIMRUNTIME">$VIMRUNTIME</a>&nbsp;for more information.<br>
<br>
Under Windows 95, you can set $VIM in your C:\autoexec.bat file.&nbsp;&nbsp;For<br>
example:<br>
<div class="helpExample">&nbsp;&nbsp;set VIM=D:\vim</div>
Under Windows NT, you can set environment variables for each user separately<br>
under &quot;Start/Settings/Control Panel-&gt;System&quot;, or through the properties in the<br>
menu of &quot;My Computer&quot;, under the Environment Tab.<br>
<br>
<span class="PreProc">==============================================================================</span><br>
2. Using backslashes&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-backslash" name="dos-backslash">dos-backslash</a><br>
<br>
Using backslashes in file names can be a problem.&nbsp;&nbsp;Vi halves the number of<br>
backslashes for some commands.&nbsp;&nbsp;Vim is a bit more tolerant and does not remove<br>
backslashes from a file name, so &quot;:e c:\foo\bar&quot; works as expected.&nbsp;&nbsp;But when<br>
a backslash occurs before a special character (space, comma, backslash, etc.),<br>
Vim removes the backslash.&nbsp;&nbsp;Use slashes to avoid problems: &quot;:e c:/foo/bar&quot;<br>
works fine.&nbsp;&nbsp;Vim replaces the slashes with backslashes internally to avoid<br>
problems with some MS-DOS programs and Win32 programs.<br>
<br>
When you prefer to use forward slashes, set the&nbsp;<a class="Type" href="options.html#'shellslash'">'shellslash'</a>&nbsp;option.&nbsp;&nbsp;Vim will<br>
then replace backslashes with forward slashes when expanding file names.&nbsp;&nbsp;This<br>
is especially useful when using a Unix-like&nbsp;<a class="Type" href="options.html#'shell'">'shell'</a>.<br>
<br>
<span class="PreProc">==============================================================================</span><br>
3. Standard mappings&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-standard-mappings" name="dos-standard-mappings">dos-standard-mappings</a><br>
<br>
The mappings for&nbsp;<span class="Special">CTRL-PageUp</span>&nbsp;and&nbsp;<span class="Special">CTRL-PageDown</span>&nbsp;have been removed, they now<br>
jump to the next or previous tab page&nbsp;<a class="Identifier" href="tabpage.html#<C-PageUp>">&lt;C-PageUp&gt;</a>&nbsp;<a class="Identifier" href="tabpage.html#<C-PageDown>">&lt;C-PageDown&gt;</a><br>
<br>
If you want them to move to the first and last screen line you can use these<br>
mappings:<br>
<br>
<span class="PreProc">key&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; key code&nbsp;&nbsp;&nbsp;&nbsp; Normal/Visual mode&nbsp;&nbsp;&nbsp;&nbsp; Insert mode</span><br>
<span class="Special">CTRL-PageUp</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-C-D&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;C-O&gt;</span>H<br>
<span class="Special">CTRL-PageDown</span>&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;</span>v&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;L$&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;C-O&gt;</span>L<span class="Special">&lt;C-O&gt;</span>$<br>
<br>
Additionally, these keys are available for copy/cut/paste.&nbsp;&nbsp;In the Win32<br>
and DJGPP versions, they also use the clipboard.<br>
<br>
Shift-Insert&nbsp;&nbsp;&nbsp;&nbsp;paste text (from clipboard)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#<S-Insert>" name="&lt;S-Insert&gt;">&lt;S-Insert&gt;</a><br>
<span class="Special">CTRL-Insert</span>&nbsp;&nbsp;&nbsp;&nbsp; copy Visual text (to clipboard)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#<C-Insert>" name="&lt;C-Insert&gt;">&lt;C-Insert&gt;</a><br>
<span class="Special">CTRL-Del</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cut Visual text (to clipboard)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#<C-Del>" name="&lt;C-Del&gt;">&lt;C-Del&gt;</a><br>
Shift-Del&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; cut Visual text (to clipboard)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#<S-Del>" name="&lt;S-Del&gt;">&lt;S-Del&gt;</a><br>
<span class="Special">CTRL-X</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cut Visual text (to clipboard)<br>
<br>
These mappings accomplish this (Win32 and DJGPP versions of Vim):<br>
<br>
<span class="PreProc">key&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; key code&nbsp;&nbsp;&nbsp;&nbsp; Normal&nbsp;&nbsp;&nbsp;&nbsp; Visual&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Insert</span><br>
Shift-Insert&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-T&gt;</span>&nbsp;&nbsp; &quot;*P&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;-d&quot;*P&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;C-R&gt;&lt;C-O&gt;</span>*<br>
<span class="Special">CTRL-Insert</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-U&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;*y<br>
Shift-Del&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-W&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;*d<br>
<span class="Special">CTRL-Del</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-X&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;*d<br>
<span class="Special">CTRL-X</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;C-X&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;*d<br>
<br>
Or these mappings (non-Win32 version of Vim):<br>
<br>
<span class="PreProc">key&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; key code&nbsp;&nbsp;&nbsp;&nbsp; Normal&nbsp;&nbsp;&nbsp;&nbsp; Visual&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Insert</span><br>
Shift-Insert&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-T&gt;</span>&nbsp;&nbsp; P&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;-dP&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;C-R&gt;&lt;C-O&gt;</span>&quot;<br>
<span class="Special">CTRL-Insert</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-U&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;y<br>
Shift-Del&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-W&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;d<br>
<span class="Special">CTRL-Del</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;M-N&gt;&lt;M-X&gt;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;d<br>
<br>
When the clipboard is supported, the &quot;* register is used.<br>
<br>
<span class="PreProc">==============================================================================</span><br>
4. Screen output and colors&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-colors" name="dos-colors">dos-colors</a><br>
<br>
The default output method for the screen is to use bios calls.&nbsp;&nbsp;This works<br>
right away on most systems.&nbsp;&nbsp;You do not need ansi.sys.&nbsp;&nbsp;You can use &quot;:mode&quot; to<br>
set the current screen mode.&nbsp;&nbsp;See&nbsp;<a class="Identifier" href="term.html#:mode">:mode</a>.<br>
<br>
To change the screen colors that Vim uses, you can use the&nbsp;<a class="Identifier" href="syntax.html#:highlight">:highlight</a><br>
command.&nbsp;&nbsp;The Normal highlight group specifies the colors Vim uses for normal<br>
text.&nbsp;&nbsp;For example, to get grey text on a blue background:<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:hi Normal ctermbg=Blue ctermfg=grey</div>
See&nbsp;<a class="Identifier" href="syntax.html#highlight-groups">highlight-groups</a>&nbsp;for other groups that are available.<br>
<br>
A DOS console does not support attributes like bold and underlining.&nbsp;&nbsp;You can<br>
set the color used in five modes with nine terminal options.&nbsp;&nbsp;<span class="Todo">Note</span>&nbsp;that this<br>
is not necessary since you can set the color directly with the &quot;:highlight&quot;<br>
command; these options are for backward compatibility with older Vim versions.<br>
The&nbsp;<a class="Identifier" href="options.html#'highlight'">'highlight'</a>&nbsp;option specifies which of the five modes is used for which<br>
action.<br>
<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_mr=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; start of invert mode<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_md=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; start of bold mode<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_me=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; back to normal text</div>
<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_so=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; start of standout mode<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_se=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; back to normal text</div>
<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_us=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; start of underline mode<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_ue=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; back to normal text</div>
<br>
<div class="helpExample">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_ZH=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; start of italics mode<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:set t_ZR=^V^[\|xxm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; back to normal text</div>
<br>
^V is&nbsp;<span class="Special">CTRL-V</span><br>
^[ is&nbsp;<span class="Special">&lt;Esc&gt;</span><br>
You must replace xx with a decimal code, which is the foreground color number<br>
and background color number added together:<br>
<br>
<span class="PreProc">COLOR&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; FOREGROUND&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BACKGROUND</span><br>
Black&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0<br>
DarkBlue&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;16<br>
DarkGreen&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;32<br>
DarkCyan&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;48<br>
DarkRed&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 4&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;64<br>
DarkMagenta&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;80<br>
Brown, DarkYellow&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;96<br>
LightGray&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 7&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 112<br>
DarkGray&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;8&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 128 *<br>
Blue, LightBlue&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 9&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 144 *<br>
Green, LightGreen&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;10&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 160 *<br>
Cyan, LightCyan&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;11&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 176 *<br>
Red, LightRed&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;12&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 192 *<br>
Magenta, LightMagenta&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;13&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 208 *<br>
Yellow, LightYellow&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;14&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 224 *<br>
White&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;15&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 240 *<br>
<br>
* Depending on the display mode, the color codes above 128 may not be<br>
&nbsp;&nbsp;available, and code 128 will make the text blink.<br>
<br>
When you use 0, the color is reset to the one used when you started Vim<br>
(usually 7, lightgray on black, but you can override this.&nbsp;&nbsp;If you have<br>
overridden the default colors in a command prompt, you may need to adjust<br>
some of the highlight colors in your vimrc---see below).<br>
This is the default for t_me.<br>
<br>
The defaults for the various highlight modes are:<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_mr&nbsp;&nbsp;&nbsp;&nbsp;112&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse mode: Black text (0) on LightGray (112)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_md&nbsp;&nbsp;&nbsp;&nbsp; 15&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;bold mode: White text (15) on Black (0)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_me&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;normal mode (revert to default)<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_so&nbsp;&nbsp;&nbsp;&nbsp; 31&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;standout mode: White (15) text on DarkBlue (16)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_se&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;standout mode end (revert to default)<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_czh&nbsp;&nbsp; 225&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;italic mode: DarkBlue text (1) on Yellow (224)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_czr&nbsp;&nbsp;&nbsp;&nbsp; 0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;italic mode end (revert to default)<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_us&nbsp;&nbsp;&nbsp;&nbsp; 67&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;underline mode: DarkCyan text (3) on DarkRed (64)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;t_ue&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;underline mode end (revert to default)<br>
<br>
These colors were chosen because they also look good when using an inverted<br>
display, but you can change them to your liking.<br>
<br>
Example:<br>
<div class="helpExample">&nbsp;&nbsp;:set t_mr=^V^[\|97m&nbsp;&nbsp; &quot; start of invert mode: DarkBlue (1) on Brown (96)<br>
&nbsp;&nbsp;:set t_md=^V^[\|67m&nbsp;&nbsp; &quot; start of bold mode: DarkCyan (3) on DarkRed (64)<br>
&nbsp;&nbsp;:set t_me=^V^[\|112m&nbsp;&nbsp;&quot; back to normal mode: Black (0) on LightGray (112)</div>
<br>
<div class="helpExample">&nbsp;&nbsp;:set t_so=^V^[\|37m&nbsp;&nbsp; &quot; start of standout mode: DarkMagenta (5) on DarkGreen<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(32)<br>
&nbsp;&nbsp;:set t_se=^V^[\|112m&nbsp;&nbsp;&quot; back to normal mode: Black (0) on LightGray (112)</div>
<br>
<span class="PreProc">==============================================================================</span><br>
5. File formats&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-file-formats" name="dos-file-formats">dos-file-formats</a><br>
<br>
If the&nbsp;<a class="Type" href="options.html#'fileformat'">'fileformat'</a>&nbsp;option is set to &quot;dos&quot; (which is the default), Vim accepts<br>
a single&nbsp;<span class="Special">&lt;NL&gt;</span>&nbsp;or a&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>&nbsp;pair for end-of-line (<span class="Special">&lt;EOL&gt;</span>).&nbsp;&nbsp;When writing a<br>
file, Vim uses&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>.&nbsp;&nbsp;Thus, if you edit a file and write it, Vim replaces<br>
<span class="Special">&lt;NL&gt;</span>&nbsp;with&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>.<br>
<br>
If the&nbsp;<a class="Type" href="options.html#'fileformat'">'fileformat'</a>&nbsp;option is set to &quot;unix&quot;, Vim uses a single&nbsp;<span class="Special">&lt;NL&gt;</span>&nbsp;for&nbsp;<span class="Special">&lt;EOL&gt;</span><br>
and shows&nbsp;<span class="Special">&lt;CR&gt;</span>&nbsp;as ^M.<br>
<br>
You can use Vim to replace&nbsp;<span class="Special">&lt;NL&gt;</span>&nbsp;with&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>&nbsp;by reading in any mode and<br>
writing in Dos mode (&quot;:se ff=dos&quot;).<br>
You can use Vim to replace&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>&nbsp;with&nbsp;<span class="Special">&lt;NL&gt;</span>&nbsp;by reading in Dos mode and<br>
writing in Unix mode (&quot;:se ff=unix&quot;).<br>
<br>
Vim sets&nbsp;<a class="Type" href="options.html#'fileformat'">'fileformat'</a>&nbsp;automatically when&nbsp;<a class="Type" href="options.html#'fileformats'">'fileformats'</a>&nbsp;is not empty (which is<br>
the default), so you don't really have to worry about what you are doing.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Identifier" href="options.html#'fileformat'">'fileformat'</a>&nbsp;<a class="Identifier" href="options.html#'fileformats'">'fileformats'</a><br>
<br>
If you want to edit a script file or a binary file, you should set the<br>
<a class="Type" href="options.html#'binary'">'binary'</a>&nbsp;option before loading the file.&nbsp;&nbsp;Script files and binary files may<br>
contain single&nbsp;<span class="Special">&lt;NL&gt;</span>&nbsp;characters which Vim would replace with&nbsp;<span class="Special">&lt;CR&gt;&lt;NL&gt;</span>.&nbsp;&nbsp;You can<br>
set&nbsp;<a class="Type" href="options.html#'binary'">'binary'</a>&nbsp;automatically by starting Vim with the &quot;-b&quot; (binary) option.<br>
<br>
<span class="PreProc">==============================================================================</span><br>
6. :cd command&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-:cd" name="dos-:cd">dos-:cd</a><br>
<br>
The &quot;:cd&quot; command recognizes the drive specifier and changes the current<br>
drive.&nbsp;&nbsp;Use &quot;:cd c:&quot; to make drive C the active drive.&nbsp;&nbsp;Use &quot;:cd d:\foo&quot; to go<br>
to the directory &quot;foo&quot; in the root of drive D.&nbsp;&nbsp;Vim also recognizes UNC names<br>
if the system supports them; e.g., &quot;:cd \\server\share\dir&quot;.&nbsp;&nbsp;<a class="Identifier" href="editing.html#:cd">:cd</a><br>
<br>
<span class="PreProc">==============================================================================</span><br>
7. Interrupting&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-CTRL-Break" name="dos-CTRL-Break">dos-CTRL-Break</a><br>
<br>
Use&nbsp;<span class="Special">CTRL-Break</span>&nbsp;instead of&nbsp;<span class="Special">CTRL-C</span>&nbsp;to interrupt searches.&nbsp;&nbsp;Vim does not detect<br>
the&nbsp;<span class="Special">CTRL-C</span>&nbsp;until it tries to read a key.<br>
<br>
<span class="PreProc">==============================================================================</span><br>
8. Temp files&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-temp-files" name="dos-temp-files">dos-temp-files</a><br>
<br>
Only for the 16 bit and 32 bit DOS version:<br>
Vim puts temporary files (for filtering) in the first of these directories<br>
that exists and in which Vim can create a file:<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$TMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$TEMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;C:\TMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;C:\TEMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current directory<br>
<br>
For the Win32 version (both console and GUI):<br>
Vim uses standard Windows functions to obtain a temporary file name (for<br>
filtering).&nbsp;&nbsp;The first of these directories that exists and in which Vim can<br>
create a file is used:<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$TMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$TEMP<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current directory<br>
<br>
<span class="PreProc">==============================================================================</span><br>
9. Shell option default&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class="Constant" href="os_dos.html#dos-shell" name="dos-shell">dos-shell</a><br>
<br>
The default for the&nbsp;<a class="Type" href="options.html#'sh'">'sh'</a>&nbsp;(<a class="Type" href="options.html#'shell'">'shell'</a>) option is &quot;command.com&quot; on Windows 95 and<br>
&quot;cmd.exe&quot; on Windows NT.&nbsp;&nbsp;If SHELL is defined, Vim uses SHELL instead, and if<br>
SHELL is not defined but COMSPEC is, Vim uses COMSPEC.&nbsp;&nbsp;Vim starts external<br>
commands with &quot;<span class="Special">&lt;shell&gt;</span>&nbsp;/c&nbsp;<span class="Special">&lt;command_name&gt;</span>&quot;.&nbsp;&nbsp;Typing&nbsp;<span class="Special">CTRL-Z</span>&nbsp;starts a new command<br>
subshell.&nbsp;&nbsp;Return to Vim with &quot;exit&quot;.&nbsp;&nbsp;&nbsp;<a class="Identifier" href="options.html#'shell'">'shell'</a>&nbsp;<a class="Identifier" href="starting.html#CTRL-Z">CTRL-Z</a><br>
<br>
If you are running a third-party shell, you may need to set the<br>
<a class="Identifier" href="options.html#'shellcmdflag'">'shellcmdflag'</a>&nbsp;(<a class="Type" href="options.html#'shcf'">'shcf'</a>) and&nbsp;<a class="Identifier" href="options.html#'shellquote'">'shellquote'</a>&nbsp;(<a class="Type" href="options.html#'shq'">'shq'</a>) or&nbsp;<a class="Identifier" href="options.html#'shellxquote'">'shellxquote'</a><br>
(<a class="Type" href="options.html#'sxq'">'sxq'</a>) options.&nbsp;&nbsp;Unfortunately, this also depends on the version of Vim used.<br>
For example, with the MKS Korn shell or with bash, the values of the options<br>
should be:<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="PreProc">DOS 16 bit&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;DOS 32 bit&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Win32&nbsp;</span><br>
<a class="Type" href="options.html#'shellcmdflag'">'shellcmdflag'</a>&nbsp;&nbsp;&nbsp;&nbsp; -c&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -c&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -c<br>
<a class="Type" href="options.html#'shellquote'">'shellquote'</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;<br>
<a class="Type" href="options.html#'shellxquote'">'shellxquote'</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;<br>
<br>
For Dos 16 bit this starts the shell as:<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;shell&gt;</span>&nbsp;-c &quot;command name&quot; &gt;file<br>
For Win32 as:<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="Special">&lt;shell&gt;</span>&nbsp;-c &quot;command name &gt;file&quot;<br>
For DOS 32 bit, DJGPP does this internally somehow.<br>
<br>
When starting up, Vim checks for the presence of &quot;sh&quot; anywhere in the&nbsp;<a class="Type" href="options.html#'shell'">'shell'</a><br>
option.&nbsp;&nbsp;If it is present, Vim sets the&nbsp;<a class="Type" href="options.html#'shellcmdflag'">'shellcmdflag'</a>&nbsp;and&nbsp;<a class="Type" href="options.html#'shellquote'">'shellquote'</a>&nbsp;or<br>
<a class="Type" href="options.html#'shellxquote'">'shellxquote'</a>&nbsp;options will be set as described above.<br>
<br>
&nbsp;vim:tw=78:ts=8:ft=help:norl:<br>
</div>
</article>
<footer>
<a href="#top">Return to the top</a> - <a href="index.html">Return to main</a>
<span class="EnglishJapaneseLink">
<span class="CurrentLanguage">English</span>
</span>
<br />
<div style="text-align:right;">
Hosted by <a href="https://github.com/vim-jp/vimdoc-en">vimdoc-en project</a><br />
If you met any problem, please report it to <a href="https://github.com/vim-jp/vimdoc-en/issues">issue</a>.<br />
</div>
</footer>
<!--<script src="js/check-referrer.js" type="text/javascript"></script>-->
</body>
</html>
<!-- vim:set ts=8 sts=2 sw=2 tw=0 et: -->
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/hilarryxu/vimdoc.git
git@gitee.com:hilarryxu/vimdoc.git
hilarryxu
vimdoc
vimdoc
master

搜索帮助