zsh-users
 help / color / mirror / code / Atom feed
* ANSI bg colour outside of prompt area
@ 2015-02-22 13:23 junkcommander0
  2015-02-22 16:52 ` Ray Andrews
  2015-02-22 19:10 ` Bart Schaefer
  0 siblings, 2 replies; 32+ messages in thread
From: junkcommander0 @ 2015-02-22 13:23 UTC (permalink / raw)
  To: zsh-users

Hey Guys!

This is my first ever mailing list post, please let me know if I'm doing 
this improperly!!

I was wondering if anyone has had any success setting BG colours in 
their terminal with ANSI escape sequences or with some other method.  I 
had some aliases with escape sequences that I used for bash and shell 
that would change the background colour. The colour was never reset, and 
clearing the screen would change the entire terminal's background 
colour.

	ex: 
	echo -ne "\033[1;33;43m"


In zsh, the background color gets reset once the characters have been 
printed.
	ex:
	kecho -ne "\033[1;33;43m abcdefg"


I've tried using zle_highlight, or appending to the end of PROMPT, but 
(as documented) it only colours the editeable lines in the terminal:
	ex:
	zle_highlight=(default:bg=yellow);
	PROMPT="%K%{yellow%}$PROMPT"

I also came across a neat tweak on the mailing list that allows you to 
change the colour of errors (which is neat, but still not what I'm 
looking for):
	ex:
	preexec() { echo -en "preexec () { echo -n "\033[11;43m"; }


I'm running out of steam though I hoped maybe that precmd or something 
like that might yield some results but I'm a little stuck at the moment.  
Any chance that any of you might be able to nudge me in a different 
direction?

Thanks Again,
- Will


^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2015-02-24  8:36 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-22 13:23 ANSI bg colour outside of prompt area junkcommander0
2015-02-22 16:52 ` Ray Andrews
2015-02-22 19:10 ` Bart Schaefer
2015-02-22 20:07   ` junkcommander0
2015-02-22 21:55   ` ZyX
2015-02-23  1:22     ` Bart Schaefer
2015-02-23  1:55       ` Vincent Lefevre
2015-02-23 12:34       ` ZyX
2015-02-22 23:10   ` Ray Andrews
2015-02-23  0:10     ` ZyX
2015-02-23  0:28       ` Kurtis Rader
2015-02-23  1:14         ` Bart Schaefer
2015-02-23  1:44           ` Kurtis Rader
2015-02-23  2:04             ` Vincent Lefevre
2015-02-23  2:18               ` Kurtis Rader
2015-02-23  3:41             ` Ray Andrews
2015-02-23  4:03               ` Kurtis Rader
2015-02-23  5:34                 ` Ray Andrews
2015-02-23  4:14               ` Kurtis Rader
2015-02-23  5:49                 ` Bart Schaefer
2015-02-23  9:46               ` Vincent Lefevre
2015-02-23 16:36                 ` Bart Schaefer
2015-02-23 16:51                   ` Ray Andrews
2015-02-24  2:53                     ` Bart Schaefer
2015-02-24  3:49                       ` junkcommander0
2015-02-24  4:33                         ` Ray Andrews
2015-02-24  4:25                       ` Ray Andrews
2015-02-24  8:36                   ` Vincent Lefevre
2015-02-23  5:27             ` Bart Schaefer
2015-02-23  1:51           ` Vincent Lefevre
2015-02-23  0:55       ` Ray Andrews
2015-02-23  1:36       ` Vincent Lefevre

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).