annotate runtime/ftplugin/cs.vim @ 31289:4f1e70a709bb v9.0.0978

patch 9.0.0978: build errors without the +channel feature Commit: https://github.com/vim/vim/commit/3b8c7083b265c35861a7f96b01c079471ff45152 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Nov 30 20:20:56 2022 +0000 patch 9.0.0978: build errors without the +channel feature Problem: Build errors without the +channel feature. (John Marriott) Solution: Adjust #ifdefs.
author Bram Moolenaar <Bram@vim.org>
date Wed, 30 Nov 2022 21:30:03 +0100
parents c58baa6d6dda
children 15c80d8bc515
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim filetype plugin file
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
2 " Language: C#
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
3 " Maintainer: Nick Jensen <nickspoon@gmail.com>
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
4 " Former Maintainer: Johannes Zellner <johannes@zellner.org>
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
5 " Last Change: 2021-12-07
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
6 " License: Vim (see :h license)
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
7 " Repository: https://github.com/nickspoons/vim-cs
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
9 if exists('b:did_ftplugin')
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 endif
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
12 let b:did_ftplugin = 1
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
14 let s:save_cpo = &cpoptions
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
15 set cpoptions&vim
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 " Set 'formatoptions' to break comment lines but not other lines,
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 " and insert the comment leader when hitting <CR> or using "o".
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
19 setlocal formatoptions-=t formatoptions+=croql
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 " Set 'comments' to format dashed lists in comments.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,:///,://
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
24 let b:undo_ftplugin = 'setl com< fo<'
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
25
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
26 if exists('loaded_matchit') && !exists('b:match_words')
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
27 " #if/#endif support included by default
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
28 let b:match_words = '\%(^\s*\)\@<=#\s*region\>:\%(^\s*\)\@<=#\s*endregion\>,'
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
29 let b:undo_ftplugin .= ' | unlet! b:match_words'
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 endif
3526
dd6c2497c997 Fix more 'cpo' issues in runtime files.
Bram Moolenaar <bram@vim.org>
parents: 233
diff changeset
31
29104
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
32 if (has('gui_win32') || has('gui_gtk')) && !exists('b:browsefilter')
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
33 let b:browsefilter = "C# Source Files (*.cs *.csx)\t*.cs;*.csx\n" .
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
34 \ "C# Project Files (*.csproj)\t*.csproj\n" .
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
35 \ "Visual Studio Solution Files (*.sln)\t*.sln\n" .
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
36 \ "All Files (*.*)\t*.*\n"
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
37 let b:undo_ftplugin .= ' | unlet! b:browsefilter'
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
38 endif
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
39
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
40 let &cpoptions = s:save_cpo
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
41 unlet s:save_cpo
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
42
c58baa6d6dda Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3526
diff changeset
43 " vim:et:sw=2:sts=2