Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

5
  • actually, I have tried these ones but either they did not work or I could not understand exactly. Commented Apr 8, 2020 at 23:23
  • 2
    @muyustan or something else might be interfering (say, you have a coloured prompt which resets the colours) Commented Apr 9, 2020 at 2:47
  • This is not the analogous command, because this is not what the color command does. To do what the color command does, one would need a DECCARA that could change colours (as some terminal emulators support as an extension), and a way to describe that via terminfo. The color command both sets the current pen/paper colours and changes the colours of all existing cells in the screen buffer. Commented Apr 9, 2020 at 13:02
  • @JdeBP actually, if it would be able to change the lines which comes next, it would be enough. However, even that is not satisfied in my situation. I am adding what my terminal looks like when I use the commands in this answer. See my comment below Commented Apr 9, 2020 at 13:50
  • I am adding how my terminal(default of Linux Mint 19.03) responds: ibb.co/g98D2j5 -- It looks like, setaf does not do anything and setab does not do exactly what your example shows. Commented Apr 9, 2020 at 13:51