robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
ab20681c52
master
1" Vim filetype plugin file 2" Language: FlexWiki, http://www.flexwiki.com/ 3" Maintainer: George V. Reilly <george@reilly.org> 4" Home: http://www.georgevreilly.com/vim/flexwiki/ 5" Other Home: http://www.vim.org/scripts/script.php?script_id=1529 6" Author: George V. Reilly 7" Filenames: *.wiki 8" Last Change: Wed Apr 26 11:00 PM 2006 P 9" Version: 0.3 10 11if exists ( "b:did_ftplugin" ) 12finish 13endif 14 15let b: did_ftplugin = 1 " Don't load another plugin for this buffer 16 17" Reset the following options to undo this plugin. 18let b: undo_ftplugin = "setl tw< wrap< lbr< et< ts< fenc< bomb< ff<" 19 20" Allow lines of unlimited length. Do NOT want automatic linebreaks, 21" as a newline starts a new paragraph in FlexWiki. 22setlocal textwidth = 0 23" Wrap long lines, rather than using horizontal scrolling. 24setlocal wrap 25" Wrap at a character in 'breakat' rather than at last char on screen 26setlocal linebreak 27" Don't transform <TAB> characters into spaces, as they are significant 28" at the beginning of the line for numbered and bulleted lists. 29setlocal noexpandtab 30" 4-char tabstops, per flexwiki.el 31setlocal tabstop = 4 32" Save *.wiki files in UTF-8 33setlocal fileencoding = utf-8 34" Add the UTF-8 Byte Order Mark to the beginning of the file 35setlocal bomb 36" Save <EOL>s as \n, not \r\n 37setlocal fileformat = unix 38 39if exists ( "g:flexwiki_maps" ) 40" Move up and down by display lines, to account for screen wrapping 41" of very long lines 42nmap <buffer> < Up > gk 43nmap <buffer> k gk 44vmap <buffer> < Up > gk 45vmap <buffer> k gk 46 47nmap <buffer> < Down > gj 48nmap <buffer> j gj 49vmap <buffer> < Down > gj 50vmap <buffer> j gj 51 52" for earlier versions - for when 'wrap' is set 53imap <buffer> < S-Down > < C-o > gj 54imap <buffer> < S-Up > < C-o > gk 55if v: version >= 700 56imap <buffer> < Down > < C-o > gj 57imap <buffer> < Up > < C-o > gk 58endif 59endif