Loading ...
Sorry, an error occurred while loading the content.

53954RE: Mapping greater than ( ) key

Expand Messages
  • Dave Silvia
    Oct 2, 2004
    • 0 Attachment
      I guess I don't see what you're trying to do. What does the '>' do? Just
      place text? If I do

      :execute "inoremap \> ><CR>"

      It successfully maps '>' and outputs '>'

      Can you give an example that is independent enough for others to work with?
      Something that doesn't work like you'd like it to, what exactly you expected
      to see, and how it can be reproduced independent of your xml.

      I'm kinda old school. I'm used to 'give me the input, the expected output
      and let me see what I can come up with'. :-)

      thx,
      Dave S.

      *** -----Original Message-----
      *** From: David Nebauer [mailto:davidnebauer@...]
      *** Sent: Sunday, October 03, 2004 12:39 AM
      *** To: Dave Silvia
      *** Cc: vim@...
      *** Subject: Re: Mapping greater than (<gt>) key
      ***
      ***
      *** You've used an interesting technique. Unfortunately, I can get
      *** it to work
      *** only in 'normal' mode -- if I type ":normal >" at the cmdline
      *** the 'mapped'
      *** text appears on the command line.
      ***
      *** In 'insert' mode the usual behaviour of '>' occurs. I'm
      *** looking for a mapping
      *** that works in insert mode as I type.
      ***
      *** Thanks for your suggestion.
      ***
      *** Regards,
      *** David.
      ***
      *** On Sun, 3 Oct 2004 01:46 pm, Dave Silvia wrote:
      *** > This seems to work:
      *** >
      *** > Vive:
      *** > normal >k
      *** > Results:
      *** >
      *** > Vive:
      *** > :execute "map \> :echo 'I have remapped greater than'<CR>"
      *** >
      *** > normal >
      *** > Results:
      *** >
      *** > I have remapped greater than
      *** >
      *** > Vive:
      *** >
      *** > HTH:
      *** >
      *** > thx,
      *** > Dave S.
      *** >
      *** > *** -----Original Message-----
      *** > *** From: David Nebauer [mailto:davidnebauer@...]
      *** > *** Sent: Saturday, October 02, 2004 10:28 PM
      *** > *** To: vim@...
      *** > *** Subject: Mapping greater than (<gt>) key
      *** > ***
      *** > ***
      *** > *** I'm trying to create the following mappings for use in editing
      *** > *** xml files:
      *** > ***
      *** > *** > --> >
      *** > *** ,> --> >
      *** > ***
      *** > *** What I'm running straight into is the shift-lines function of
      *** > *** the '>' key.
      *** > *** The mapping does not appear to intercept the keystroke before
      *** > *** it performs the
      *** > *** shift-lines action.
      *** > ***
      *** > *** I've tried the following without success:
      *** > *** [Note: 'Standard behaviour' is the usual behaviour of the
      *** <gt> key.]
      *** > ***
      *** > *** inoremap > > " Standard behaviour
      *** > *** inoremap <gt> > " Standard behaviour
      *** > *** inoremap \> > " Standard behaviour
      *** > *** inoremap \\> > " Standard behaviour
      *** > ***
      *** > *** As you can see, I'm guessing wildly with the last two attempts.
      *** > *** Is the '>'
      *** > *** key unmappable?
      *** > ***
      *** > *** I'm happy to do without the shift-lines feature while editing
      *** > *** xml. I used the
      *** > *** following mappings for less-than without any trouble:
      *** > ***
      *** > *** inoremap < <
      *** > *** inoremap ,< <lt> || inoremap ,< < " either works
      *** > ***
      *** > *** I've searched the net high and low for information on this
      *** > *** problem without any
      *** > *** success. I'm sure it must have been solved long ago.
      *** Any help greatly
      *** > *** appreciated.
      *** > ***
      *** > *** Regards,
      *** > *** David.
      ***
      *** --
      *** Regards,
      *** David
      ***
      *** -------------------------------------------
      *** Email: david@...
      *** Phone: +61 (0) 401 029 885
    • Show all 8 messages in this topic