From 6902c22a779aeb3389843a36ee41af2ab633bb07 Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Sat, 16 May 2020 22:29:53 +0200 Subject: selection: copy: insert line break if either cell is empty --- selection.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'selection.c') diff --git a/selection.c b/selection.c index 59cab9a7..3928e4cb 100644 --- a/selection.c +++ b/selection.c @@ -232,7 +232,8 @@ extract_one(struct terminal *term, struct row *row, struct cell *cell, if (ctx->last_row != NULL && row != ctx->last_row && ((term->selection.kind == SELECTION_NORMAL && - ctx->last_row->linebreak) || + (ctx->last_row->linebreak || + ctx->empty_count > 0 || cell->wc == 0)) || term->selection.kind == SELECTION_BLOCK)) { /* Last cell was the last column in the selection */ -- cgit v1.3