diff options
author | Karel Kočí <cynerd@email.cz> | 2016-06-30 16:11:56 +0200 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2016-06-30 16:11:56 +0200 |
commit | 9931e0888b2419326ae10ebbfae532261c5c125f (patch) | |
tree | 7504be5daccbb7b7d1ea396754de47b11ed790e5 /vim/bundle/tlib_vim/autoload/tlib/selection.vim | |
parent | e573b3020c032400eed60b649a2cbf55266e6bb0 (diff) | |
download | myconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.tar.gz myconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.tar.bz2 myconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.zip |
Fix submodules
Diffstat (limited to 'vim/bundle/tlib_vim/autoload/tlib/selection.vim')
m--------- | vim/bundle/tlib_vim | 0 | ||||
-rw-r--r-- | vim/bundle/tlib_vim/autoload/tlib/selection.vim | 40 |
2 files changed, 0 insertions, 40 deletions
diff --git a/vim/bundle/tlib_vim b/vim/bundle/tlib_vim new file mode 160000 +Subproject 5636472e5dba1a4104376ce6bd93cc2546e0248 diff --git a/vim/bundle/tlib_vim/autoload/tlib/selection.vim b/vim/bundle/tlib_vim/autoload/tlib/selection.vim deleted file mode 100644 index 4417157..0000000 --- a/vim/bundle/tlib_vim/autoload/tlib/selection.vim +++ /dev/null @@ -1,40 +0,0 @@ -" @Author: Tom Link (mailto:micathom AT gmail com?subject=[vim]) -" @Website: http://www.vim.org/account/profile.php?user_id=4037 -" @License: GPL (see http://www.gnu.org/licenses/gpl.txt) -" @Last Change: 2016-01-03 -" @Revision: 3 - - -" :display: tlib#selection#GetSelection(mode, ?mbeg="'<", ?mend="'>", ?opmode='selection') -" mode can be one of: selection, lines, block -function! tlib#selection#GetSelection(mode, ...) range "{{{3 - if a:0 >= 2 - let mbeg = a:1 - let mend = a:2 - else - let mbeg = "'<" - let mend = "'>" - endif - let opmode = a:0 >= 3 ? a:3 : 'selection' - let l0 = line(mbeg) - let l1 = line(mend) - let text = getline(l0, l1) - let c0 = col(mbeg) - let c1 = col(mend) - " TLogVAR mbeg, mend, opmode, l0, l1, c0, c1 - " TLogVAR text[-1] - " TLogVAR len(text[-1]) - if opmode == 'block' - let clen = c1 - c0 - call map(text, 'strpart(v:val, c0, clen)') - elseif opmode == 'selection' - if c1 > 1 - let text[-1] = strpart(text[-1], 0, c1 - (a:mode == 'o' || c1 > len(text[-1]) ? 0 : 1)) - endif - if c0 > 1 - let text[0] = strpart(text[0], c0 - 1) - endif - endif - return text -endf - |