robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
cbf54ec2a5
master
1" Vim syntax support file 2" Maintainer: The Vim Project <https://github.com/vim/vim> 3" Last Change: 2023 Aug 10 4" Former Maintainer: Bram Moolenaar <Bram@vim.org> 5 6" This file is used for ":syntax off". 7" It removes the autocommands and stops highlighting for all buffers. 8 9if ! has ( "syntax" ) 10finish 11endif 12 13" Remove all autocommands for the Syntax event. This also avoids that 14" "syntax=foo" in a modeline triggers the SynSet() function of synload.vim. 15au ! Syntax 16 17" remove all syntax autocommands and remove the syntax for each buffer 18augroup syntaxset 19au ! 20au BufEnter * syn clear 21au BufEnter * if exists ( "b:current_syntax" ) |unlet b: current_syntax |endif 22doautoall syntaxset BufEnter * 23au ! 24augroup END 25 26if exists ( "syntax_on" ) 27unlet syntax_on 28endif 29if exists ( "syntax_manual" ) 30unlet syntax_manual 31endif