summaryrefslogtreecommitdiff
path: root/src/tui/tui.go
diff options
context:
space:
mode:
authorJunegunn Choi <junegunn.c@gmail.com>2025-01-30 00:50:46 +0900
committerGitHub <noreply@github.com>2025-01-30 00:50:46 +0900
commit6c0ca4a64a4e2f8697dfa830dcae56c1d7ddca51 (patch)
treeb3cb6eefec8009c815d0ce0a4bea3032f8bc0cf8 /src/tui/tui.go
parent6b5d4614114f1a7a34a50c21ed2952f94a5ee81e (diff)
downloadfzf-6c0ca4a64a4e2f8697dfa830dcae56c1d7ddca51.tar.gz
Add --no-input to hide the input section (#4210)
Close #2890 Close #1396 You can't type in queries in this mode, and the only way to trigger an fzf search is to use `search(...)` action. # Click header to trigger search fzf --header '[src] [test]' --no-input --layout reverse \ --header-border bottom --input-border \ --bind 'click-header:transform-search:echo ${FZF_CLICK_HEADER_WORD:1:-1}'
Diffstat (limited to 'src/tui/tui.go')
-rw-r--r--src/tui/tui.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/tui/tui.go b/src/tui/tui.go
index fe8fc243..0c778ad6 100644
--- a/src/tui/tui.go
+++ b/src/tui/tui.go
@@ -615,6 +615,7 @@ type Renderer interface {
NeedScrollbarRedraw() bool
ShouldEmitResizeEvent() bool
Bell()
+ HideCursor()
GetChar() Event
@@ -662,6 +663,7 @@ type FullscreenRenderer struct {
forceBlack bool
prevDownTime time.Time
clicks [][2]int
+ showCursor bool
}
func NewFullscreenRenderer(theme *ColorTheme, forceBlack bool, mouse bool) Renderer {
@@ -670,7 +672,8 @@ func NewFullscreenRenderer(theme *ColorTheme, forceBlack bool, mouse bool) Rende
mouse: mouse,
forceBlack: forceBlack,
prevDownTime: time.Unix(0, 0),
- clicks: [][2]int{}}
+ clicks: [][2]int{},
+ showCursor: true}
return r
}