Ignoring `self-insert-command`?
fehmud opened this issue · 7 comments
Hello Mark,
thank you for sharing this useful package.
Would it be possible to make Emacs ignore self-insert-command
when Modalka is enabled? This would avoid accidentally inserting text in Modalka mode.
Best Regards.
One way to do this is to add a major mode hook (modalka-mode-hook
iirc) and in there use add-advice
/remove-advice
to overwrite/restore self-insert-command
.
I'm not absolutely convinced that we should do this in modalka
by default though.
What about, e.g.:
(define-key modalka-mode-map [remap self-insert-command] 'ignore)
I'm not absolutely convinced that we should do this in modalka by default though.
Wouldn't it be surprising to have some keys issuing commands and others inserting text? I tried the Modalka example and noticed this.
Maybe there could be an option to enable/disable self-insert-command
, depending on your view on this issue.
@phil-s Your fix works, thanks. If Mark confirms that there are no side effects, then I shall submit a Pull Request to update README.md
.
@egarrulo Feel free, I see no problem with including this info.
Closing this as I don't see why it should stay open.