aboutsummaryrefslogtreecommitdiff
path: root/debug.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2021-03-23 10:02:51 +0000
committerDaniel Eklöf <daniel@ekloef.se>2021-03-23 10:02:51 +0000
commitee75e10e71ca4f942fbbc6cdac6b20fdb57ab67f (patch)
tree605fe7fd43dd842ad7c00ed884ed1d2270655a46 /debug.c
parentMerge branch 'zoom-line-height' (diff)
term: term_print(): clear line break flag
The line break flag is used by the text reflow and text extraction (i.e. copy-paste) logic, to determine whether or not to insert a newline between two lines. There’s some amount of heuristics involved in this. For example, the client application could emit a newline, move the cursor back up, and print text. What does that mean for us? Foot’s behavior up until now has been this: The line break flag is set on the row, when the application emits an explicit linefeed. The flag is cleared when the line is erased. But otherwise not. This meant that emitting a linefeed and then moving the cursor back up and printing text, did not clear the line break flag. This in turn meant that text copied always had newlines inserted, even though that was not the client applications intention. By clearing the line break flag whenever _anything_ is printed to a row, the new behavior is, in practice, that the line break flag is only set on a row if a linefeed was that *last* thing printed to that row. Closes #410
Diffstat (limited to 'debug.c')
0 files changed, 0 insertions, 0 deletions