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.
- Write a wrapper or alias that changes colors using ANSI codes, then calls the application?dirkt– dirkt2017-03-14 15:15:22 +00:00Commented Mar 14, 2017 at 15:15
- @dirkt Thanks. Do you have a reference on how to chance the colors using ANSI codes?danijar– danijar2017-03-14 16:18:31 +00:00Commented Mar 14, 2017 at 16:18
Add a comment |
1 Answer
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
- Thanks. Keeping this open to see if someone knows a solution for urxvt, or even a terminal agnostic one.danijar– danijar2017-03-14 16:20:14 +00:00Commented Mar 14, 2017 at 16:20