From 5b03835bdda9b7580760c0a98261c64a66e302f6 Mon Sep 17 00:00:00 2001 From: Tom Feist Date: Fri, 22 Apr 2011 02:52:47 +0100 Subject: vim-mode/vim_mode: more documentation on how to use uberprompt hooks and expandos to get vim_mode sbar items or variables. --- vim-mode/README.pod | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++- vim-mode/vim_mode.pl | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 136 insertions(+), 2 deletions(-) (limited to 'vim-mode') diff --git a/vim-mode/README.pod b/vim-mode/README.pod index c6de881..dbb7d07 100644 --- a/vim-mode/README.pod +++ b/vim-mode/README.pod @@ -49,6 +49,15 @@ to a script of this size and complexity. =head2 SETUP +Vim Mode provides certain feedback to the user, such as the currently active +mode (command, insert, ex), and if switching buffers, which buffer(s) currently +match the search terms. + +There are two ways to go about displaying this information, as described in +the following sections: + +=head3 Statusbar Items + Run the following command to add a statusbar item that shows which mode you're in. @@ -62,6 +71,64 @@ C B Remember to C after adding these statusbar items to make them permanent. +B If you would rather have these statusbar items on your prompt +line rather than thte window statusbar, please follow these steps. + +For I items (that is, after the input field: + +=over 4 + +=item 1 C + +=item 2 C + +=item 3 C + +=item 4 C + +=back + +For I items (before the prompt): + +=over 4 + +=item 1 C + +=item 2 C + +=item 3 C + +=item 4 C + +=back + +If you wish to add both C and C items, replace steps 1 and 2 +with the following: + +=over 4 + +=item 1 C + +=item 2 C + +=back + +and then complete stages 3 and 4 as above. Replace the C<-after> and C<-alignment> +to suit your location preferences. + +=head3 Expando Variables + +Vim mode augments the existing Irssi expando (automatic variables) with two +additional ones: C<$vim_cmd_mode> and C<$vim_wins>. + +C<$vim_cmd_mode> is the equivalent of the C statusbar item, and +C<$vim_wins> is the counterpart of C. + +They can be added to your theme, or inserted into your uberprompt using +the + +"C" command. + =head3 FILE-BASED CONFIGURATION @@ -334,7 +401,7 @@ Examples: =item * C<:map EC-GE /window goto 1> -=item * C<:map EC-EE > - disable , it does nothing now +=item * C<:map EC-EE > - disable EC-EE, it does nothing now =item * C<:unmap EC-EE> - restore default behavior of CC-EE> after disabling it diff --git a/vim-mode/vim_mode.pl b/vim-mode/vim_mode.pl index fb818dd..e2bfed0 100644 --- a/vim-mode/vim_mode.pl +++ b/vim-mode/vim_mode.pl @@ -49,6 +49,15 @@ to a script of this size and complexity. =head2 SETUP +Vim Mode provides certain feedback to the user, such as the currently active +mode (command, insert, ex), and if switching buffers, which buffer(s) currently +match the search terms. + +There are two ways to go about displaying this information, as described in +the following sections: + +=head3 Statusbar Items + Run the following command to add a statusbar item that shows which mode you're in. @@ -62,6 +71,64 @@ C B Remember to C after adding these statusbar items to make them permanent. +B If you would rather have these statusbar items on your prompt +line rather than thte window statusbar, please follow these steps. + +For I items (that is, after the input field: + +=over 4 + +=item 1 C + +=item 2 C + +=item 3 C + +=item 4 C + +=back + +For I items (before the prompt): + +=over 4 + +=item 1 C + +=item 2 C + +=item 3 C + +=item 4 C + +=back + +If you wish to add both C and C items, replace steps 1 and 2 +with the following: + +=over 4 + +=item 1 C + +=item 2 C + +=back + +and then complete stages 3 and 4 as above. Replace the C<-after> and C<-alignment> +to suit your location preferences. + +=head3 Expando Variables + +Vim mode augments the existing Irssi expando (automatic variables) with two +additional ones: C<$vim_cmd_mode> and C<$vim_wins>. + +C<$vim_cmd_mode> is the equivalent of the C statusbar item, and +C<$vim_wins> is the counterpart of C. + +They can be added to your theme, or inserted into your uberprompt using +the + +"C" command. + =head3 FILE-BASED CONFIGURATION @@ -334,7 +401,7 @@ Examples: =item * C<:map EC-GE /window goto 1> -=item * C<:map EC-EE > - disable , it does nothing now +=item * C<:map EC-EE > - disable EC-EE, it does nothing now =item * C<:unmap EC-EE> - restore default behavior of CC-EE> after disabling it -- cgit v1.2.3