From 2564bbce0d4aab9134285a9c324f79c45ca673d8 Mon Sep 17 00:00:00 2001 From: Jakub Darul Date: Mon, 24 Aug 2020 20:36:16 +0200 Subject: [PATCH] Use flyspell-mode for SPC t s if +flyspell present Also corresponding bindigs fix for +emacs-bindigs.el --- modules/config/default/+emacs-bindings.el | 4 +++- modules/config/default/+evil-bindings.el | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/modules/config/default/+emacs-bindings.el b/modules/config/default/+emacs-bindings.el index c9579e258..4c0726df2 100644 --- a/modules/config/default/+emacs-bindings.el +++ b/modules/config/default/+emacs-bindings.el @@ -279,8 +279,10 @@ (:when (featurep! :lang org +present) :desc "org-tree-slide mode" "p" #'org-tree-slide-mode) :desc "Read-only mode" "r" #'read-only-mode - (:when (featurep! :checkers spell) + (:when (and (featurep! :checkers spell) (not (featurep! :checkers spell +flyspell))) :desc "Spell checker" "s" #'spell-fu-mode) + (:when (featurep! :checkers spell +flyspell) + :desc "Spell checker" "s" #'flyspell-mode) (:when (featurep! :lang org +pomodoro) :desc "Pomodoro timer" "t" #'org-pomodoro) (:when (featurep! :ui zen) diff --git a/modules/config/default/+evil-bindings.el b/modules/config/default/+evil-bindings.el index 35adb0e4a..5b6cea3f9 100644 --- a/modules/config/default/+evil-bindings.el +++ b/modules/config/default/+evil-bindings.el @@ -661,8 +661,10 @@ (:when (featurep! :lang org +present) :desc "org-tree-slide mode" "p" #'org-tree-slide-mode) :desc "Read-only mode" "r" #'read-only-mode - (:when (featurep! :checkers spell) + (:when (and (featurep! :checkers spell) (not (featurep! :checkers spell +flyspell))) :desc "Spell checker" "s" #'spell-fu-mode) + (:when (featurep! :checkers spell +flyspell) + :desc "Spell checker" "s" #'flyspell-mode) (:when (featurep! :lang org +pomodoro) :desc "Pomodoro timer" "t" #'org-pomodoro) :desc "Soft line wrapping" "w" #'visual-line-mode