Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support evil-fold #199

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion company-coq.el
Original file line number Diff line number Diff line change
Expand Up @@ -3281,8 +3281,30 @@ These keybindings are activated by `company-coq--keybindings-minor-mode'.")

(define-minor-mode company-coq--keybindings-minor-mode
"Minor mode providing convenient company-coq keybindings."
nil
:lighter nil
:keymap company-coq-map)
:keymap company-coq-map
(when (boundp 'evil-fold-list)
(if company-coq--keybindings-minor-mode
(add-to-list 'evil-fold-list
'((company-coq-mode)
:open company-coq-unfold
:close company-coq-fold
:toggle (lambda () (company-coq-features/code-folding-toggle-block nil))
:open-all (lambda () (company-coq-call-compat 'outline-show-all 'show-all))
:close-all (lambda () (company-coq-call-compat 'outline-hide-body 'hide-body))
)
)
(setq evil-fold-list (delete
'((company-coq-mode)
:open company-coq-unfold
:close company-coq-fold
:toggle (lambda () (company-coq-features/code-folding-toggle-block nil))
:open-all (lambda () (company-coq-call-compat 'outline-show-all 'show-all))
:close-all (lambda () (company-coq-call-compat 'outline-hide-body 'hide-body))
)
evil-fold-list)))
))

(defvar company-coq-electric-exit-characters '(?\; ?.)
"Characters that exit the current snippet.")
Expand Down