first commit
This commit is contained in:
commit
0610f4aeab
130 changed files with 9897 additions and 0 deletions
27
fn/-z4h-show-dots
Normal file
27
fn/-z4h-show-dots
Normal file
|
@ -0,0 +1,27 @@
|
|||
#!/usr/bin/env zsh
|
||||
|
||||
local -i cursor=CURSOR
|
||||
local postdisplay=$POSTDISPLAY
|
||||
local buffer=$BUFFER
|
||||
|
||||
BUFFER=$1
|
||||
POSTDISPLAY=..
|
||||
|
||||
if [[ -n $ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE ]]; then
|
||||
local style=$ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE
|
||||
elif (( terminfo[colors] >= 256 )); then
|
||||
local style='fg=244'
|
||||
else
|
||||
local style='fg=black,bold'
|
||||
fi
|
||||
|
||||
region_highlight+=("$#BUFFER $(($#BUFFER + $#POSTDISPLAY)) $style")
|
||||
typeset -gi CURSOR='_z4h_cursor_max()'
|
||||
|
||||
-z4h-cursor-hide
|
||||
zle -R
|
||||
|
||||
BUFFER=$buffer
|
||||
CURSOR=cursor
|
||||
POSTDISPLAY=$postdisplay
|
||||
region_highlight[-1]=()
|
Loading…
Add table
Add a link
Reference in a new issue