summaryrefslogtreecommitdiff
path: root/files/vim
diff options
context:
space:
mode:
Diffstat (limited to 'files/vim')
-rw-r--r--files/vim/autoload/Juliana.vim14
-rw-r--r--files/vim/colors/lil_pablo.vim2
-rw-r--r--files/vim/patches/qname_edit.diff34
-rw-r--r--files/vim/plugin/qname.1.2.vim9
-rw-r--r--files/vim/vimrc5
5 files changed, 38 insertions, 26 deletions
diff --git a/files/vim/autoload/Juliana.vim b/files/vim/autoload/Juliana.vim
index 9af02d7..492f3d5 100644
--- a/files/vim/autoload/Juliana.vim
+++ b/files/vim/autoload/Juliana.vim
@@ -5,31 +5,31 @@ function! Juliana#Init()
augroup JulianaPersistAu
autocmd ModeChanged [V\x16]*:i let g:Juliana#has_selection = 1
autocmd InsertLeave * let g:Juliana#has_selection = 0
+ " Don't trigger autocomplete until a character is typed.
+ autocmd ModeChanged [nvV\x16]:i setglobal noac | autocmd InsertCharPre * setglobal ac | autocmd! InsertCharPre *
augroup END
- " This won't trigger autocomplete until 2 characters are typed.
- autocmd ModeChanged *:i set noac | augroup JulianaSkipAutocomplete | autocmd TextChangedI * set ac | autocmd! JulianaSkipAutocomplete | augroup END
endfunction
function! Juliana#CompleteTab(type)
if a:type == "START"
- let g:Juliana#stop=0
+ let g:Juliana#stop = 0
return ""
endif
if !g:Juliana#stop
" Vanilla <Tab> if we are at the front of a line.
if a:type == "TAB" && col(".") >= col("$") && !pumvisible()
- let g:Juliana#stop=1
+ let g:Juliana#stop = 1
return "\<Tab>"
elseif a:type == "ALIGN" && !pumvisible() " Align if !pumvisible().
- let g:Juliana#stop=1
+ let g:Juliana#stop = 1
if g:Juliana#has_selection
return "\<ESC>gv=i"
else
return "\<ESC>\<C-v>=i"
endif
elseif a:type == "NEXT" " If pumvisible(), goto the next result.
- let g:Juliana#stop=1
+ let g:Juliana#stop = 1
return "\<C-n>"
endif
endif
@@ -49,7 +49,7 @@ endfunction
function! Juliana#CompleteNTab(type)
if a:type == "FOLD"
- if foldlevel(line(".")) " Toggle fold if on fold.
+ if foldlevel(line(".")) " Toggle fold if on a fold.
return "za"
else
return "\<Tab>"
diff --git a/files/vim/colors/lil_pablo.vim b/files/vim/colors/lil_pablo.vim
index 1ab6d2a..555ac4c 100644
--- a/files/vim/colors/lil_pablo.vim
+++ b/files/vim/colors/lil_pablo.vim
@@ -10,7 +10,9 @@ set background=dark
hi clear
let g:colors_name = 'lil_pablo'
+" :%s/gui\(bg\|fg\)=\(#[0-9a-f]*\|NONE\) //g
" :%s/cterm\(bg\|fg\)=\([0-9]*\|NONE\|fg\)\ /cterm\1=\2\ gui\1=##\2##\ /g
+" :%s/##NONE##/NONE/g
hi Normal ctermfg=15 guifg=#ffffff ctermbg=0 guibg=#000000 cterm=NONE
hi Comment ctermfg=8 guifg=#808080 ctermbg=NONE guibg=NONE cterm=NONE
diff --git a/files/vim/patches/qname_edit.diff b/files/vim/patches/qname_edit.diff
index ab1ed09..b5350c6 100644
--- a/files/vim/patches/qname_edit.diff
+++ b/files/vim/patches/qname_edit.diff
@@ -1,7 +1,7 @@
Post- dos2unix, Tabify, and Trim.
--- a/qname.1.2.vim 2025-08-03 20:12:24.629096223 -0400
-+++ b/qname.1.2.vim 2025-10-30 16:45:40.688588103 -0400
-@@ -7,7 +7,27 @@
++++ b/qname.1.2.vim 2025-11-04 11:19:39.070454407 -0500
+@@ -7,7 +7,30 @@
" License: Vim License
" =============================================================================
@@ -25,11 +25,14 @@ Post- dos2unix, Tabify, and Trim.
+" Fix logic to not include buffers with modifiable off
+" 2025-10-30:
+" Treat <S-BS> the same as <BS>
++" 2025-11-04:
++" Open selected buffer in the current window, even if the same buffer is
++" already open in another window.
+"
" 1.2 2013-01-03
" ADD: <Tab> and <S-Tab> moves selection like <Up> and <Down>
" ADD: Use <silent> mapping to keep cmdline clear
-@@ -30,12 +50,6 @@
+@@ -30,12 +53,6 @@
finish
endif
@@ -42,7 +45,7 @@ Post- dos2unix, Tabify, and Trim.
if exists("g:qname_loaded") && g:qname_loaded
finish
endif
-@@ -53,7 +67,7 @@
+@@ -53,7 +70,7 @@
" use case-sensitive equality operator, otherwise <BS> looks like
" <S-Tab> if 'ignorecase' is set
@@ -51,7 +54,7 @@ Post- dos2unix, Tabify, and Trim.
let s:inp = s:inp[:-2]
elseif _key ==# "\<C-U>"
let s:inp = ""
-@@ -70,16 +84,19 @@
+@@ -70,16 +87,19 @@
call s:swb(str2nr(matchstr(s:s[_sel], '<\zs\d\+\ze>')))
endif
call QNameInit(0)
@@ -75,7 +78,7 @@ Post- dos2unix, Tabify, and Trim.
else
call s:build()
endif
-@@ -88,7 +105,6 @@
+@@ -88,7 +108,6 @@
cal QNameInit(0)
finally
" clean up screen after dismissing search window
@@ -83,7 +86,7 @@ Post- dos2unix, Tabify, and Trim.
call inputrestore()
endtry
endfunc
-@@ -99,6 +115,7 @@
+@@ -99,6 +118,7 @@
let s:cmdh = &cmdheight
if a:start != -1
let s:inp = ""
@@ -91,7 +94,7 @@ Post- dos2unix, Tabify, and Trim.
endif
call s:baselist()
call s:build()
-@@ -112,16 +129,27 @@
+@@ -112,16 +132,27 @@
function! s:build()
let s:s = []
let s:n = []
@@ -122,7 +125,16 @@ Post- dos2unix, Tabify, and Trim.
cal s:colPrinter.put(s:n)
else
cal s:colPrinter.put(s:s)
-@@ -137,37 +165,28 @@
+@@ -129,45 +160,32 @@
+ endfunc
+
+ function! s:swb(bno)
+- if bufwinnr(a:bno) == -1
+- exe "hid b" a:bno
+- else
+- exe bufwinnr(a:bno) . "winc w"
+- endif
++ exe "hid b" a:bno
endfunc
function! s:fmatch(src,pat)
@@ -165,7 +177,7 @@ Post- dos2unix, Tabify, and Trim.
function! s:colPrinter.put(its) dict
let _cols = []
let _trow = self.trow
-@@ -224,11 +243,7 @@
+@@ -224,11 +242,7 @@
function! s:colPrinter.vert(mv) dict
let _t = self.sel + a:mv
let _len = self.len
@@ -178,7 +190,7 @@ Post- dos2unix, Tabify, and Trim.
let self.sel = _t
endif
endfunc
-@@ -244,7 +259,7 @@
+@@ -244,7 +258,7 @@
let _t = _sel/_trow
let _cpos = self.cpos
let _lcol = self.lcol
diff --git a/files/vim/plugin/qname.1.2.vim b/files/vim/plugin/qname.1.2.vim
index 7ecd92f..4e81318 100644
--- a/files/vim/plugin/qname.1.2.vim
+++ b/files/vim/plugin/qname.1.2.vim
@@ -27,6 +27,9 @@
" Fix logic to not include buffers with modifiable off
" 2025-10-30:
" Treat <S-BS> the same as <BS>
+" 2025-11-04:
+" Open selected buffer in the current window, even if the same buffer is
+" already open in another window.
"
" 1.2 2013-01-03
" ADD: <Tab> and <S-Tab> moves selection like <Up> and <Down>
@@ -157,11 +160,7 @@ function! s:build()
endfunc
function! s:swb(bno)
- if bufwinnr(a:bno) == -1
- exe "hid b" a:bno
- else
- exe bufwinnr(a:bno) . "winc w"
- endif
+ exe "hid b" a:bno
endfunc
function! s:fmatch(src,pat)
diff --git a/files/vim/vimrc b/files/vim/vimrc
index b3bb734..93d1215 100644
--- a/files/vim/vimrc
+++ b/files/vim/vimrc
@@ -128,9 +128,8 @@ if isdirectory(expand("~/c"))
endif
set autocomplete
-"set complete=.^4,w^3,b^2,u^2,i^2,d^2
-set complete=.^4,w^3,b^2,u^2
-set completeopt+=menu,popup
+set complete=.^4,w^2,b^2
+set completeopt+=menu,menuone,popup,noinsert,noselect
" Plugins.
let g:fugitive_no_maps = 1