mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-04 06:36:24 +00:00
Do not add a trailing newline when wrapping
This commit is contained in:
parent
e42b4fd9a6
commit
924cd4cadd
4 changed files with 8 additions and 7 deletions
|
|
@ -235,11 +235,7 @@ func lines_for_context_chunk(data *DiffData, hunk_num int, chunk *Chunk, chunk_n
|
|||
}
|
||||
|
||||
func splitlines(text string, width int) []string {
|
||||
lines := style.WrapTextAsLines(text, "", width)
|
||||
if len(lines) > 1 && lines[len(lines)-1] == "" {
|
||||
lines = lines[:len(lines)-1]
|
||||
}
|
||||
return lines
|
||||
return style.WrapTextAsLines(text, "", width)
|
||||
}
|
||||
|
||||
func render_half_line(line_number int, line, ltype string, margin_size, available_cols int, center Center, ans []string) []string {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue