mirror of
https://github.com/Llewellynvdm/fzf.git
synced 2024-11-22 04:45:14 +00:00
Do not allow tabs in pointer and marker
This commit is contained in:
parent
89375005b5
commit
1fef36e4bc
@ -751,6 +751,10 @@ func NewTerminal(opts *Options, eventBox *util.EventBox, executor *util.Executor
|
|||||||
hscroll: opts.Hscroll,
|
hscroll: opts.Hscroll,
|
||||||
hscrollOff: opts.HscrollOff,
|
hscrollOff: opts.HscrollOff,
|
||||||
scrollOff: opts.ScrollOff,
|
scrollOff: opts.ScrollOff,
|
||||||
|
pointer: *opts.Pointer,
|
||||||
|
pointerLen: uniseg.StringWidth(*opts.Pointer),
|
||||||
|
marker: *opts.Marker,
|
||||||
|
markerLen: uniseg.StringWidth(*opts.Marker),
|
||||||
wordRubout: wordRubout,
|
wordRubout: wordRubout,
|
||||||
wordNext: wordNext,
|
wordNext: wordNext,
|
||||||
cx: len(input),
|
cx: len(input),
|
||||||
@ -833,8 +837,6 @@ func NewTerminal(opts *Options, eventBox *util.EventBox, executor *util.Executor
|
|||||||
lastAction: actStart,
|
lastAction: actStart,
|
||||||
lastFocus: minItem.Index()}
|
lastFocus: minItem.Index()}
|
||||||
t.prompt, t.promptLen = t.parsePrompt(opts.Prompt)
|
t.prompt, t.promptLen = t.parsePrompt(opts.Prompt)
|
||||||
t.pointer, t.pointerLen = t.processTabs([]rune(*opts.Pointer), 0)
|
|
||||||
t.marker, t.markerLen = t.processTabs([]rune(*opts.Marker), 0)
|
|
||||||
// Pre-calculated empty pointer and marker signs
|
// Pre-calculated empty pointer and marker signs
|
||||||
t.pointerEmpty = strings.Repeat(" ", t.pointerLen)
|
t.pointerEmpty = strings.Repeat(" ", t.pointerLen)
|
||||||
t.markerEmpty = strings.Repeat(" ", t.markerLen)
|
t.markerEmpty = strings.Repeat(" ", t.markerLen)
|
||||||
|
Loading…
Reference in New Issue
Block a user