andmarti1424 / sc-im

sc-im - Spreadsheet Calculator Improvised -- An ncurses spreadsheet program for terminal
Other
4.8k stars 203 forks source link

nnoremap doesn't work as expected, depends on other mappings #800

Open SeerLite opened 1 year ago

SeerLite commented 1 year ago

Hi!

nnoremap might not work depending on what (non-recursive) mappings have been done before it. It doesn't seem to be completely isolated from other mappings.

Consider this:

nnoremap "m" "h"
nnoremap "am" "fh"

Pressing am won't do anything (when fh, decrease column width, is expected). Note that it's not that it's recursive and executing ah either:

nnoremap "m" "h"
nnoremap "ah" "fh"

won't do anything.

However, if am is mapped before m is mapped, it works correctly:

nnoremap "am" "fh"
nnoremap "m" "h"

This is how I expect it to work even when the order of the lines is switched.

andmarti1424 commented 1 year ago

hello. yes, i wont say its not working as expected. we might need to add extra doc explaining this.