vim - Vimscript - Mapping functions -
let's have function give me ascii value of character passed argument , call asciifunc (it's late , can't think of creative names). possible define single mapping calls asciifunc , passes character typed. eg. if function mapped <leader>a
pressing <leader>af
call function asciifunc , pass 'f' parameter?
just avoid confusion, know ga
gives ascii , other information of character under cursor, not i'm looking for. i'm looking way avoid having create multiple mappings 1 each every possible value asciifunc can take argument.
you can call getchar()
function inside asciifunc()
. it'll wait input.
Comments
Post a Comment