From 25e2c9e3e6a2eaafd7d21a6f4e70c836d7888d8d Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Thu, 27 Apr 2006 21:40:34 +0000 Subject: updated for version 7.0f03 --- runtime/ftplugin/debchangelog.vim | 18 ++++++------ runtime/ftplugin/flexwiki.vim | 59 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 69 insertions(+), 8 deletions(-) create mode 100644 runtime/ftplugin/flexwiki.vim (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/debchangelog.vim b/runtime/ftplugin/debchangelog.vim index 6d1f20ee3d..350010105a 100644 --- a/runtime/ftplugin/debchangelog.vim +++ b/runtime/ftplugin/debchangelog.vim @@ -2,7 +2,7 @@ " Language: Debian Changelog " Maintainer: Michael Piefel " Stefano Zacchiroli -" Last Change: 25 April 2006 +" Last Change: 27 April 2006 " License: GNU GPL, version 2.1 or later if exists("g:did_changelog_ftplugin") @@ -203,17 +203,11 @@ au BufEnter * if &filetype == "debchangelog" | call MakeMenu() | endif au BufLeave * if &filetype == "debchangelog" | aunmenu Changelog | endif augroup END -" Debian changelogs are not supposed to have any other text width, -" so the user cannot override this setting -setlocal tw=78 -setlocal comments=f:* -let b:undo_ftplugin = "setlocal tw< comments<" - " }}} " {{{1 folding setlocal foldmethod=expr -set foldexpr=GetDebChangelogFold(v:lnum) +setlocal foldexpr=GetDebChangelogFold(v:lnum) setlocal foldtext=DebChangelogFoldText() " look for an author name searching backward from a given line number @@ -251,4 +245,12 @@ endfunction " }}} +" Debian changelogs are not supposed to have any other text width, +" so the user cannot override this setting +setlocal tw=78 +setlocal comments=f:* + +" Clean unloading +let b:undo_ftplugin = "setlocal tw< comments< foldmethod< foldexpr< foldtext<" + " vim: set foldmethod=marker: diff --git a/runtime/ftplugin/flexwiki.vim b/runtime/ftplugin/flexwiki.vim new file mode 100644 index 0000000000..1e749f69d5 --- /dev/null +++ b/runtime/ftplugin/flexwiki.vim @@ -0,0 +1,59 @@ +" Vim filetype plugin file +" Language: FlexWiki, http://www.flexwiki.com/ +" Maintainer: George V. Reilly +" Home: http://www.georgevreilly.com/vim/flexwiki/ +" Other Home: http://www.vim.org/scripts/script.php?script_id=1529 +" Author: George V. Reilly +" Filenames: *.wiki +" Last Change: Wed Apr 26 11:00 PM 2006 P +" Version: 0.3 + +if exists("b:did_ftplugin") + finish +endif + +let b:did_ftplugin = 1 " Don't load another plugin for this buffer + +" Reset the following options to undo this plugin. +let b:undo_ftplugin = "setl tw< wrap< lbr< et< ts< fenc< bomb< ff<" + +" Allow lines of unlimited length. Do NOT want automatic linebreaks, +" as a newline starts a new paragraph in FlexWiki. +setlocal textwidth=0 +" Wrap long lines, rather than using horizontal scrolling. +setlocal wrap +" Wrap at a character in 'breakat' rather than at last char on screen +setlocal linebreak +" Don't transform characters into spaces, as they are significant +" at the beginning of the line for numbered and bulleted lists. +setlocal noexpandtab +" 4-char tabstops, per flexwiki.el +setlocal tabstop=4 +" Save *.wiki files in UTF-8 +setlocal fileencoding=utf-8 +" Add the UTF-8 Byte Order Mark to the beginning of the file +setlocal bomb +" Save s as \n, not \r\n +setlocal fileformat=unix + +if exists("g:flexwiki_maps") + " Move up and down by display lines, to account for screen wrapping + " of very long lines + nmap gk + nmap k gk + vmap gk + vmap k gk + + nmap gj + nmap j gj + vmap gj + vmap j gj + + " for earlier versions - for when 'wrap' is set + imap gj + imap gk + if v:version >= 700 + imap gj + imap gk + endif +endif -- cgit v1.2.3