comparison runtime/doc/syntax.txt @ 819:23f82b5d2814 v7.0c10

updated for version 7.0c10
author vimboss
date Wed, 05 Apr 2006 20:41:53 +0000
parents 4a79d6d376f0
children 9ab23f1e137f
comparison
equal deleted inserted replaced
818:1f929f3ca806 819:23f82b5d2814
1 *syntax.txt* For Vim version 7.0c. Last change: 2006 Mar 28 1 *syntax.txt* For Vim version 7.0c. Last change: 2006 Apr 04
2 2
3 3
4 VIM REFERENCE MANUAL by Bram Moolenaar 4 VIM REFERENCE MANUAL by Bram Moolenaar
5 5
6 6
79 file for your system. Although on MS-DOS and Windows the right format is 79 file for your system. Although on MS-DOS and Windows the right format is
80 automatically selected if the 'fileformats' option is not empty. 80 automatically selected if the 'fileformats' option is not empty.
81 81
82 NOTE: When using reverse video ("gvim -fg white -bg black"), the default value 82 NOTE: When using reverse video ("gvim -fg white -bg black"), the default value
83 of 'background' will not be set until the GUI window is opened, which is after 83 of 'background' will not be set until the GUI window is opened, which is after
84 reading the .gvimrc. This will cause the wrong default highlighting to be 84 reading the |gvimrc|. This will cause the wrong default highlighting to be
85 used. To set the default value of 'background' before switching on 85 used. To set the default value of 'background' before switching on
86 highlighting, include the ":gui" command in the .gvimrc: > 86 highlighting, include the ":gui" command in the |gvimrc|: >
87 87
88 :gui " open window and set default for 'background' 88 :gui " open window and set default for 'background'
89 :syntax on " start highlighting, use 'background' to set colors 89 :syntax on " start highlighting, use 'background' to set colors
90 90
91 NOTE: Using ":gui" in the .gvimrc means that "gvim -f" won't start in the 91 NOTE: Using ":gui" in the |gvimrc| means that "gvim -f" won't start in the
92 foreground! Use ":gui -f" then. 92 foreground! Use ":gui -f" then.
93 93
94 94
95 You can toggle the syntax on/off with this command > 95 You can toggle the syntax on/off with this command >
96 :if exists("syntax_on") | syntax off | else | syntax enable | endif 96 :if exists("syntax_on") | syntax off | else | syntax enable | endif
1011 When you edit an existing fortran file, the syntax script will assume free 1011 When you edit an existing fortran file, the syntax script will assume free
1012 source form if the fortran_free_source variable has been set, and assumes 1012 source form if the fortran_free_source variable has been set, and assumes
1013 fixed source form if the fortran_fixed_source variable has been set. If 1013 fixed source form if the fortran_fixed_source variable has been set. If
1014 neither of these variables have been set, the syntax script attempts to 1014 neither of these variables have been set, the syntax script attempts to
1015 determine which source form has been used by examining the first five columns 1015 determine which source form has been used by examining the first five columns
1016 of the first 25 lines of your file. If no signs of free source form are 1016 of the first 250 lines of your file. If no signs of free source form are
1017 detected, then the file is assumed to be in fixed source form. The algorithm 1017 detected, then the file is assumed to be in fixed source form. The algorithm
1018 should work in the vast majority of cases. In some cases, such as a file that 1018 should work in the vast majority of cases. In some cases, such as a file that
1019 begins with 25 or more full-line comments, the script may incorrectly decide 1019 begins with 250 or more full-line comments, the script may incorrectly decide
1020 that the fortran code is in fixed form. If that happens, just add a 1020 that the fortran code is in fixed form. If that happens, just add a
1021 non-comment statement beginning anywhere in the first five columns of the 1021 non-comment statement beginning anywhere in the first five columns of the
1022 first twenty five lines, save (:w) and then reload (:e!) the file. 1022 first twenty five lines, save (:w) and then reload (:e!) the file.
1023 1023
1024 Tabs in fortran files ~ 1024 Tabs in fortran files ~
2302 (Adapted from the html.vim help text by Claudio Fleiner <claudio@fleiner.com>) 2302 (Adapted from the html.vim help text by Claudio Fleiner <claudio@fleiner.com>)
2303 2303
2304 2304
2305 SH *sh.vim* *ft-sh-syntax* *ft-bash-syntax* *ft-ksh-syntax* 2305 SH *sh.vim* *ft-sh-syntax* *ft-bash-syntax* *ft-ksh-syntax*
2306 2306
2307 This covers the "normal" Unix (Bourne) sh, bash and the Korn shell. 2307 This covers the "normal" Unix (Borne) sh, bash and the Korn shell.
2308 2308
2309 Vim attempts to determine which shell type is in use by specifying that 2309 Vim attempts to determine which shell type is in use by specifying that
2310 various filenames are of specific types: > 2310 various filenames are of specific types: >
2311 2311
2312 ksh : .kshrc* *.ksh 2312 ksh : .kshrc* *.ksh
2325 let is_kornshell = 1 2325 let is_kornshell = 1
2326 < bash: > 2326 < bash: >
2327 let is_bash = 1 2327 let is_bash = 1
2328 < sh: > 2328 < sh: >
2329 let is_sh = 1 2329 let is_sh = 1
2330
2331 If there's no "#! ..." line, and the user hasn't availed himself/herself of a
2332 default sh.vim syntax setting as just shown, then syntax/sh.vim will assume
2333 the Borne shell syntax. No need to quote RFCs or market penetration
2334 statistics in error reports, please.
2330 2335
2331 If, in your <.vimrc>, you set > 2336 If, in your <.vimrc>, you set >
2332 let g:sh_fold_enabled= 1 2337 let g:sh_fold_enabled= 1
2333 > 2338 >
2334 then various syntax items (HereDocuments and function bodies) become 2339 then various syntax items (HereDocuments and function bodies) become
3758 3763
3759 Note that "bold" can be used here and by using a bold font. They 3764 Note that "bold" can be used here and by using a bold font. They
3760 have the same effect. 3765 have the same effect.
3761 "undercurl" is a curly underline. When "undercurl" is not possible 3766 "undercurl" is a curly underline. When "undercurl" is not possible
3762 then "underline" is used. In general "undercurl" is only available in 3767 then "underline" is used. In general "undercurl" is only available in
3763 the GUI. 3768 the GUI. The color is set with |highlight-guisp|.
3764 3769
3765 start={term-list} *highlight-start* *E422* 3770 start={term-list} *highlight-start* *E422*
3766 stop={term-list} *term-list* *highlight-stop* 3771 stop={term-list} *term-list* *highlight-stop*
3767 These lists of terminal codes can be used to get 3772 These lists of terminal codes can be used to get
3768 non-standard attributes on a terminal. 3773 non-standard attributes on a terminal.