Skip to content
Myr

Fix minimum preview window height

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent c440418 · Browse files · 1 file+5 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+5 added−1 removed

  • other:+5 added−1 removed

1 file+5 added−1 removed

modified:src/terminal.go+5 added-1 removed
863 unmodified lines
864 t.pwindow = t.tui.NewWindow(y, x, pwidth, pheight, true, noBorder)865 }866 verticalPad := 2867 minPreviewHeight := 3868 if t.previewOpts.border == tui.BorderNone {868 switch t.previewOpts.border {869 case tui.BorderNone, tui.BorderVertical, tui.BorderLeft, tui.BorderRight:870 verticalPad = 0871 minPreviewHeight = 1872 case tui.BorderTop, tui.BorderBottom:873 verticalPad = 1874 minPreviewHeight = 2875 }876 switch t.previewOpts.position {877 case posUp:878 pheight := calculateSize(height, t.previewOpts.size, minHeight, minPreviewHeight, verticalPad)
1893 unmodified lines