From 1cb19dbf65590ffe44b60ac4d5ff7a957de0628f Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sun, 23 Aug 2020 15:57:49 +0900 Subject: Support preview scroll offset relative to window height Related: https://github.com/junegunn/fzf.vim/issues/1092 --- src/options.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/options.go') diff --git a/src/options.go b/src/options.go index 699e8a55..a916e806 100644 --- a/src/options.go +++ b/src/options.go @@ -995,7 +995,7 @@ func parsePreviewWindow(opts *previewOpts, input string) { tokens := strings.Split(input, ":") sizeRegex := regexp.MustCompile("^[1-9][0-9]*%?$") - offsetRegex := regexp.MustCompile("^\\+([0-9]+|{-?[0-9]+})(-[0-9]+)?$") + offsetRegex := regexp.MustCompile("^\\+([0-9]+|{-?[0-9]+})(-[0-9]+|-/[1-9][0-9]*)?$") for _, token := range tokens { switch token { case "": -- cgit v1.2.3