As I said in the comments, mappings in are not designed to do what you want to do. An interesting option for this use case is
This option allows to keep the behavior or your keyboard in insert mode and change its behavior in the other modes.
To use it Vim has to be compiled with
+langmap, you can check that this option is enabled with
echo has('langmap'): if the command returns
1 the option is enabled else you'll have to get a setup with this option enabled (to know how to do that, it is another question).
When it is enabled, the option takes pairs of characters for example
set langmap += à@ will allow you to add a
à in your buffer when you're in insert mode and you type a
à but typing
à in normal mode will actually trigger a
@ (this example can be useful on azerty keyboards to ease work with macros).
To use langmap in greek you can follow the example given in
:h 'langmap' adding this line to your
vimrc (Copying this line from here may not be a good idea since I'm really not sure of the encoding, yanking the line directly from the help file is probably safer):
Now from what I understand in your comments it remains an issue when you try to use predefined commands: when you type a command, the insert mode behavior will be triggered instead of the langmap defined behavior. Unfortunately I'm not sure I have a good solution for that. One idea could be to redefine commands for example like that:
command λς lw
This way when you'll type the command
λς Vim will execute
lw but I see several drawbacks to this method:
- It might be a huge pain in the butt to redefine all the commands you want to use.
- User-defined commands have to start with a capital letter, and I have now idea how convenient it is to do that in greek.
So maybe a plugin suggested by @Alexander Myshov in his answer to this question could be useful (as I never tried any of these I don't know if they solve the problem but it seems like they do).