neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

ishd.vim (1760B)


      1 " Vim filetype plugin file
      2 " Language:		InstallShield (ft=ishd)
      3 " Maintainer:		Doug Kearns <dougkearns@gmail.com>
      4 " Previous Maintainer:	Johannes Zellner <johannes@zellner.org>
      5 " Last Change:		2025 Jun 18
      6 " 2025 Jun 18 by Vim Project: set comments and commentstring option (#17490)
      7 
      8 if exists("b:did_ftplugin") | finish | endif
      9 let b:did_ftplugin = 1
     10 
     11 " Using line continuation here.
     12 let s:cpo_save = &cpo
     13 set cpo-=C
     14 
     15 setlocal foldmethod=syntax
     16 setlocal commentstring=//\ %s
     17 setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,://
     18 
     19 let b:undo_ftplugin = "setl fdm< com< cms"
     20 
     21 " matchit support
     22 if exists("loaded_matchit")
     23    let b:match_ignorecase = 0
     24    let b:match_words =
     25    \ '\%(^\s*\)\@<=\<function\>\s\+[^()]\+\s*(:\%(^\s*\)\@<=\<begin\>\s*$:\%(^\s*\)\@<=\<return\>:\%(^\s*\)\@<=\<end\>\s*;\s*$,' .
     26    \ '\%(^\s*\)\@<=\<repeat\>\s*$:\%(^\s*\)\@<=\<until\>\s\+.\{-}\s*;\s*$,' .
     27    \ '\%(^\s*\)\@<=\<switch\>\s*(.\{-}):\%(^\s*\)\@<=\<\%(case\|default\)\>:\%(^\s*\)\@<=\<endswitch\>\s*;\s*$,' .
     28    \ '\%(^\s*\)\@<=\<while\>\s*(.\{-}):\%(^\s*\)\@<=\<endwhile\>\s*;\s*$,' .
     29    \ '\%(^\s*\)\@<=\<for\>.\{-}\<\%(to\|downto\)\>:\%(^\s*\)\@<=\<endfor\>\s*;\s*$,' .
     30    \ '\%(^\s*\)\@<=\<if\>\s*(.\{-})\s*then:\%(^\s*\)\@<=\<else\s*if\>\s*([^)]*)\s*then:\%(^\s*\)\@<=\<else\>:\%(^\s*\)\@<=\<endif\>\s*;\s*$'
     31    let b:undo_ftplugin .= " | unlet! b:match_ignorecase b:match_words"
     32 endif
     33 
     34 if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
     35    let b:browsefilter = "InstallShield Files (*.rul)\t*.rul\n"
     36    if has("win32")
     37 let b:browsefilter .= "All Files (*.*)\t*\n"
     38    else
     39 let b:browsefilter .= "All Files (*)\t*\n"
     40    endif
     41    let b:undo_ftplugin .= " | unlet! b:browsefilter"
     42 endif
     43 
     44 let &cpo = s:cpo_save
     45 unlet s:cpo_save