Skip to content

Commit

Permalink
Fixed main view showing an empty line
Browse files Browse the repository at this point in the history
  • Loading branch information
cgxeiji committed Nov 5, 2018
1 parent a62eb0d commit c718c5c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions cmd/gui.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,12 @@ func guiQuery(entries []*scholar.Entry, search string) *scholar.Entry {
}
} else {
v.Clear()
for _, e := range showList {
fmt.Fprint(v, formatEntry(e, maxX/5*3))
for i, e := range showList {
fe := formatEntry(e, maxX*3/5)
if i == len(showList)-1 {
fe = strings.TrimSpace(fe)
}
fmt.Fprint(v, fe)
}
}

Expand Down

0 comments on commit c718c5c

Please sign in to comment.