Skip to content

Commit

Permalink
Fix offset in completion printing (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
maxlandon authored Dec 14, 2023
1 parent 240f4ce commit a558922
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions internal/completion/group.go
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,6 @@ func (g *group) longestValueDescribed(vals []Candidate) int {

if val.descLen > longestDesc {
longestDesc = val.descLen

}

if val.descLen > longestDesc {
Expand All @@ -344,7 +343,7 @@ func (g *group) longestValueDescribed(vals []Candidate) int {
}

// Always add one: there is at least one space between each column.
return longestVal + longestDesc + 1
return longestVal + longestDesc + 2
}

func (g *group) trimDisplay(comp Candidate, pad, col int) (candidate, padded string) {
Expand Down

0 comments on commit a558922

Please sign in to comment.