When using a terminal that supports more than 16 colors (such as urxvt), it it possible to provide different colors to different applications running in the same terminal after another? For example, my vim theme looks best when background and color0 are set to the same value, while htop looks best when they are different.
Asked
Active
Viewed 877 times
4
danijar
- 1,433
- 2
- 14
- 22
-
Write a wrapper or alias that changes colors using ANSI codes, then calls the application? – dirkt Mar 14 '17 at 15:15
-
@dirkt Thanks. Do you have a reference on how to chance the colors using ANSI codes? – danijar Mar 14 '17 at 16:18
1 Answers
1
xterm has this feature:
+dc This option enables the escape sequence to change dynamic
colors. The option sets the dynamicColors option to “true”.
Check for more info: https://github.com/sos4nt/dynamic-colors
Ipor Sircer
- 14,376
- 1
- 27
- 34
-
Thanks. Keeping this open to see if someone knows a solution for urxvt, or even a terminal agnostic one. – danijar Mar 14 '17 at 16:20