zsh-users
 help / color / mirror / code / Atom feed
* change color depending on vi-mode
@ 2006-01-23 11:19 Fabian Braennstroem
  2006-01-23 16:17 ` Bart Schaefer
  2006-01-23 19:55 ` Mike Hernandez
  0 siblings, 2 replies; 5+ messages in thread
From: Fabian Braennstroem @ 2006-01-23 11:19 UTC (permalink / raw)
  To: zsh-users

Hi,

I am pretty new to zsh and like it a lot. As a prompt style
I use 'adam2'. Now, I would like to know, if it is possible
to display some information or change the color of the bar
depending on the current vi-mode? E.g. I would like to have
a red line in insert-mode and a blue line in
navigation-mode.

Greetings!
 Fabian


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

* Re: change color depending on vi-mode
  2006-01-23 11:19 change color depending on vi-mode Fabian Braennstroem
@ 2006-01-23 16:17 ` Bart Schaefer
  2006-01-23 19:55 ` Mike Hernandez
  1 sibling, 0 replies; 5+ messages in thread
From: Bart Schaefer @ 2006-01-23 16:17 UTC (permalink / raw)
  To: zsh-users

On Jan 23, 12:19pm, Fabian Braennstroem wrote:
}
} I use 'adam2'. Now, I would like to know, if it is possible
} to display some information or change the color of the bar
} depending on the current vi-mode?

There was a discussion about something like this last year; search the 
archives for "Vi ZLE bindings".

The short answer is that the only way to do it is to create your own
widget functions for all of the vi commands that change modes.  There
is no "callback" associated with changing the keymap that can be used
to update the prompt.


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

* Re: change color depending on vi-mode
  2006-01-23 11:19 change color depending on vi-mode Fabian Braennstroem
  2006-01-23 16:17 ` Bart Schaefer
@ 2006-01-23 19:55 ` Mike Hernandez
  2006-01-24 15:21   ` Fabian Braennstroem
  1 sibling, 1 reply; 5+ messages in thread
From: Mike Hernandez @ 2006-01-23 19:55 UTC (permalink / raw)
  To: Fabian Braennstroem; +Cc: zsh-users

On  Mon, Jan 23, 2006 at 12:19:33PM +0100, Fabian Braennstroem wrote:
> Hi,
> 
> I am pretty new to zsh and like it a lot. As a prompt style
> I use 'adam2'. Now, I would like to know, if it is possible
> to display some information or change the color of the bar
> depending on the current vi-mode? E.g. I would like to have
> a red line in insert-mode and a blue line in
> navigation-mode.
> 
Check this out:

http://www.gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/zsh/vi-showmode

There are instances where it can act strangely, but for the most
part it works rather well.

Mike H


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

* Re: change color depending on vi-mode
  2006-01-23 19:55 ` Mike Hernandez
@ 2006-01-24 15:21   ` Fabian Braennstroem
  2006-01-24 19:21     ` Thomas Köhler
  0 siblings, 1 reply; 5+ messages in thread
From: Fabian Braennstroem @ 2006-01-24 15:21 UTC (permalink / raw)
  To: zsh-users

Hi to both,

* Mike Hernandez <sequethin@gmail.com> wrote:
> On  Mon, Jan 23, 2006 at 12:19:33PM +0100, Fabian Braennstroem wrote:
>> Hi,
>> 
>> I am pretty new to zsh and like it a lot. As a prompt style
>> I use 'adam2'. Now, I would like to know, if it is possible
>> to display some information or change the color of the bar
>> depending on the current vi-mode? E.g. I would like to have
>> a red line in insert-mode and a blue line in
>> navigation-mode.
>> 
> Check this out:
>
> http://www.gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/zsh/vi-showmode
>
> There are instances where it can act strangely, but for the most
> part it works rather well.

Very nice! Seems to work good enough for me :-)

Greetings!
 Fabian


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

* Re: change color depending on vi-mode
  2006-01-24 15:21   ` Fabian Braennstroem
@ 2006-01-24 19:21     ` Thomas Köhler
  0 siblings, 0 replies; 5+ messages in thread
From: Thomas Köhler @ 2006-01-24 19:21 UTC (permalink / raw)
  To: zsh-users

[-- Attachment #1: Type: text/plain, Size: 1223 bytes --]

Hello Fabian,

Fabian Braennstroem wrote:
> Hi to both,
> 
> * Mike Hernandez <sequethin@gmail.com> wrote:
> > On  Mon, Jan 23, 2006 at 12:19:33PM +0100, Fabian Braennstroem wrote:
> >> Hi,
> >> 
> >> I am pretty new to zsh and like it a lot. As a prompt style
> >> I use 'adam2'. Now, I would like to know, if it is possible
> >> to display some information or change the color of the bar
> >> depending on the current vi-mode? E.g. I would like to have
> >> a red line in insert-mode and a blue line in
> >> navigation-mode.
> >> 
> > Check this out:
> >
> > http://www.gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/zsh/vi-showmode
> >
> > There are instances where it can act strangely, but for the most
> > part it works rather well.
> 
> Very nice! Seems to work good enough for me :-)

Well, for me it works "good enough", but if anyone has bugreports
or such: Please tell me ;-)

> Greetings!
>  Fabian

Ciao,
Thomas

-- 
 Thomas Köhler       Email:       jean-luc@picard.franken.de
     <><             WWW:              http://gott-gehabt.de
                     IRC:                           tkoehler
                     PGP public key available from Homepage!

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

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

end of thread, other threads:[~2006-01-24 19:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-01-23 11:19 change color depending on vi-mode Fabian Braennstroem
2006-01-23 16:17 ` Bart Schaefer
2006-01-23 19:55 ` Mike Hernandez
2006-01-24 15:21   ` Fabian Braennstroem
2006-01-24 19:21     ` Thomas Köhler

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).