blob: 70a130d2872e9f50da55db0a466588cc6190739a [file] [log] [blame]
Bram Moolenaar071d4272004-06-13 20:20:40 +00001" Vim filetype plugin file
2" Language: aspvbs
Bram Moolenaar1588bc82022-03-08 21:35:07 +00003"
4" This runtime file is looking for a new maintainer.
5"
6" Former maintainer: Dan Sharp
Bram Moolenaar5c736222010-01-06 20:54:52 +01007" Last Changed: 20 Jan 2009
Bram Moolenaar071d4272004-06-13 20:20:40 +00008
9if exists("b:did_ftplugin") | finish | endif
10
11" Make sure the continuation lines below do not cause problems in
12" compatibility mode.
13let s:save_cpo = &cpo
14set cpo-=C
15
16" Define some defaults in case the included ftplugins don't set them.
17let s:undo_ftplugin = ""
18let s:browsefilter = "HTML Files (*.html, *.htm)\t*.htm*\n" .
19 \ "All Files (*.*)\t*.*\n"
20let s:match_words = ""
21
22runtime! ftplugin/html.vim ftplugin/html_*.vim ftplugin/html/*.vim
23let b:did_ftplugin = 1
24
25" Override our defaults if these were set by an included ftplugin.
26if exists("b:undo_ftplugin")
27 let s:undo_ftplugin = b:undo_ftplugin
28endif
29if exists("b:browsefilter")
30 let s:browsefilter = b:browsefilter
31endif
32if exists("b:match_words")
33 let s:match_words = b:match_words
34endif
35
36" ASP: Active Server Pages (with Visual Basic Script)
37" thanks to Gontran BAERTS
38if exists("loaded_matchit")
39 let s:notend = '\%(\<end\s\+\)\@<!'
Bram Moolenaar843ee412004-06-30 16:16:41 +000040 let b:match_ignorecase = 1
Bram Moolenaar071d4272004-06-13 20:20:40 +000041 let b:match_words =
Bram Moolenaar843ee412004-06-30 16:16:41 +000042 \ s:notend . '\<if\>\%(.\{-}then\s\+\w\)\@!:\<elseif\>:^\s*\<else\>:\<end\s\+\<if\>,' .
43 \ s:notend . '\<select\s\+case\>:\<case\>:\<case\s\+else\>:\<end\s\+select\>,' .
44 \ '^\s*\<sub\>:\<end\s\+sub\>,' .
45 \ '^\s*\<function\>:\<end\s\+function\>,' .
46 \ '\<class\>:\<end\s\+class\>,' .
47 \ '^\s*\<do\>:\<loop\>,' .
48 \ '^\s*\<for\>:\<next\>,' .
49 \ '\<while\>:\<wend\>,' .
Bram Moolenaar071d4272004-06-13 20:20:40 +000050 \ s:match_words
51endif
52
53" Change the :browse e filter to primarily show ASP-related files.
54if has("gui_win32")
55 let b:browsefilter="ASP Files (*.asp)\t*.asp\n" . s:browsefilter
56endif
57
Bram Moolenaar843ee412004-06-30 16:16:41 +000058let b:undo_ftplugin = "unlet! b:match_words b:match_ignorecase b:browsefilter | " . s:undo_ftplugin
Bram Moolenaar071d4272004-06-13 20:20:40 +000059
60" Restore the saved compatibility options.
61let &cpo = s:save_cpo
Bram Moolenaar84f72352012-03-11 15:57:40 +010062unlet s:save_cpo