" AlignMapsPlugin: Alignment maps based upon and " Maintainer: Dr. Charles E. Campbell. " Date: Jan 07, 2013 " " NOTE: the code herein needs vim 7.0 or later " Copyright: Copyright (C) 1999-2012 Charles E. Campbell {{{1 " Permission is hereby granted to use and distribute this code, " with or without modifications, provided that this copyright " notice is copied with it. Like anything else that's free, " AlignMaps.vim is provided *as is* and comes with no warranty " of any kind, either expressed or implied. By using this " plugin, you agree that in no event will the copyright " holder be liable for any damages resulting from the use " of this software. " Romans 1:20 For the invisible things of Him since the creation of the {{{1 " world are clearly seen, being perceived through the things that are " made, even His everlasting power and divinity; that they may be " without excuse. " --------------------------------------------------------------------- " Usage: {{{1 " Use 'a to mark beginning of to-be-aligned region, Alternative: use V " move cursor to end of region, and execute map. (linewise visual mode) to " The maps also set up marks 'y and 'z, and retain mark region, execute same " 'a at the beginning of region. map. Uses 'a, 'y, and 'z. " " The start/end wrappers save and restore marks 'y and 'z. " " Although the comments indicate the maps use a leading backslash, " actually they use (:he mapleader), so the user can " specify that the maps start how he or she prefers. " " Note: these maps all use . " " Load Once: {{{1 if &cp || exists("g:loaded_AlignMapsPlugin") finish endif let s:keepcpo = &cpo let g:loaded_AlignMapsPlugin = "v43" set cpo&vim " ===================================================================== " Public Interface: {{{1 com! AlignMapsClean :call AlignMaps#AlignMapsClean() " ===================================================================== " Maps: {{{1 " --------------------------------------------------------------------- " WS: wrapper start map (internal) {{{2 " Produces a blank line above and below, marks with 'y and 'z if !hasmapto('WrapperStart') map WS AlignMapsWrapperStart endif nnoremap