Bug 409016 - konsole `\033[0m` not working start from second page of scroll
Summary: konsole `\033[0m` not working start from second page of scroll
Status: REPORTED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: 17.12.3
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-06-21 22:35 UTC by 林果皞
Modified: 2021-03-10 19:12 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
`\033[0m` not working started from 12th row on second page of scroll. (38.31 KB, image/png)
2019-06-21 22:35 UTC, 林果皞
Details

Note You need to log in before you can comment on or make changes to this bug.
Description 林果皞 2019-06-21 22:35:34 UTC
Created attachment 121066 [details]
`\033[0m` not working started from 12th row on second page of scroll.

SUMMARY
konsole `\033[0m` not working started from second page of scroll.

STEPS TO REPRODUCE
1.  Run with command for i in {1..100}; do echo "$i"; echo -en '\033[1;42m AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA  \033[0m'; echo -e 'next text'; done:
2. Ensure the text overflow to bottom.
3. Scroll the page, the second page (12th row on screenshot) color not reset by `\033[0m`.

EXPECTED RESULT
`\033[0m' should able to reset color like first page do.

SOFTWARE/OS VERSIONS
Ubuntu 18.04.2 LTS, Gnome, konsole 17.12.3
Comment 1 Egmont Koblinger 2019-06-23 14:24:45 UTC
It's the bce nightmare again (https://bugzilla.gnome.org/show_bug.cgi?id=754596).

Strictly speaking, konsole behaves correctly.

"\033[0m" is definitely okay. It switches to the default color and applies that for any *newly printed* cell as expected – not for other cells though, like the rest of the line when this sequence is recieved (they are already green by that time).

On the other hand, bce (which is responsible for painting the next line in green) is arguably a terribly designed feature. gnome-terminal tries to mitigate the problem it causes by a slightly different behavior, although cannot fully fix the faulty design.