Commit Graph

32 Commits

Author SHA1 Message Date
Arif Er 00f9ab19ac chore: update copyright headers to 2022
The script used to identify and update the change is added into the GitHub
workflows script directory. A workflow action can be created to trigger the
script to update the headers on the first of every new year. Possibly a task for
a consequent PR.
2022-06-03 17:32:20 +02:00
Dan Kessler 2c661ab49d
Ensure hjkl bindings are respected during company search/filter (#14768) 2021-05-13 19:01:48 -04:00
Maximilian Wolff e9b4131d18 [auto-complete] Removed the last traces of transformer integration
They are mostly obsolete now and harmful for performance.
See #14547 for details.
2021-05-09 20:56:54 +00:00
syl20bnr 97cd83e169 Apply GPLv3 terms explicitly to all elisp files 2021-03-25 22:59:32 -04:00
syl20bnr d55a9e2e67 Update header for year 2021 2021-03-25 22:59:32 -04:00
Maximilian Wolff 8f854da649
Make auto-completion activate/deactivate smartparens properly
auto-completion did not respect the smartparens-mode
defined in the dotfile when disabling/restoring it.

In addition when starting a yasnippet expansion
smartparens-mode was not properly restored resulting
in having smartparens always disabled.

This PR tries to fix both issues. Though judging from
the comments this could kill `hippie-expand` expansion.
However as yasnippet is more common I think this is
to be preferred.
2021-03-16 22:21:40 +01:00
Robert O'Connor 82ba73a1c0
update copyright to 2020 2020-09-23 21:25:01 +02:00
Spenser Truex 05fb56bfbf Remove uses of lexical-let, part of the deprecated cl package
These prevented loading, a serious bug.
2019-12-15 08:45:27 +01:00
lovrolu bc22a259e8 Don't assume the previous binding was evil-insert-digraph 2019-11-15 20:05:23 +01:00
duianto e96f0adfdd Fix C-k in company with tooltip
Got the idea for the fix from this comment:
https://github.com/expez/company-quickhelp/issues/17#issuecomment-526783169

I simplified it to only un/define C-k, since C-j worked without the fix.
2019-10-19 19:42:21 +02:00
Benjamin Reynolds 594fdc8f05 Rename spacemacs/mplist-get functions to be more descriptive
* spacemacs/mplist-get -> spacemacs/mplist-get-values
* spacemacs/plist-get -> spacemacs/mplist-get-value
* refactor spacemacs/mplist-get-value to be defined in terms of mplist-get-values

Ref #10803 See [comment]

[comment]: https://github.com/syl20bnr/spacemacs/pull/10803#issuecomment-395292606
2018-06-14 00:15:49 -04:00
syl20bnr b282e553ba Use dotspacemacs backward compatibility macro instead of aliases 2018-06-08 02:24:38 -04:00
Kalle Lindqvist 2ad98d77a1 auto-completion: add ivy-yasnippet (#10813) 2018-06-05 22:45:37 -04:00
syl20bnr 2df4db5c60 core: new function spacemacs/plist-get
Made to play well with modified plist. Replace spacemacs/mplist-get by
spacemacs/plist-get in spacemacs|add-company-backends
2018-06-04 01:19:44 -04:00
syl20bnr a698c8ba58 auto-completion: fix add-company-backends macro
We must always use spacemacs/mplist-get on an modified plist, mixing both
spacemacs/mplist-get and plist-get leads to undefined behavior as soon as a
keyword as multiple keywords.
2018-06-04 01:07:00 -04:00
Miciah Dashiel Butler Masters 78297be625 Fix various typos
* Fix various isolated typos

"apppend" -> "append"

"availabe" -> "available"

"Descripti using ternon" -> "Description"

"you have not them" -> "you don't have them"

"new on" -> "new one"

"plained" -> "curved"

"repel" -> "REPL"

"vairable" -> "variable"

* Fix a few errors in the CoffeeScript layer readme

Add a missing "the".

Correct a reference to the layer as "javascript" to "coffeescript".

Fix the syntax on the link to CoffeeLint.

* Fix typos: "dofile" -> "dotfile"

* Fix typos: "formated" and "formating"

"formated" -> "formatted"

"formating" -> "formatting"

* hy: Fix docstrings in funcs.el

Fix copy-and-pasted docstring text for
spacemacs/hy-shell-eval-current-form-and-go and
spacemacs/hy-shell-eval-region-and-go.

* Fix typos: "indendation" -> "indentation"

* Fix typos: "the the", "a a"

Fix duplicated (or misplaced) articles.

* Fix typos: "wether" -> "whether"

* Fix typos: "intialize" -> "initialize"
2018-05-23 22:12:30 -04:00
syl20bnr 391bbc1498 fix backends when auto-completion-enable-snippets-in-popup is nil
fixes #10676
2018-05-14 21:32:53 -04:00
syl20bnr 40f41769bd auto-completion: add :call-hooks and rename :hooks to :append-hooks
Add these keywords to macro spacemacs|add-company-backends

:append-hooks controls wether we add the hooks to major mode hook variable
:call-hooks conrols wether we execute the created hooks function right away

Basically for multiple backends setup we want to pass :append-hooks to nil and
:call-hooks to t.
2018-05-12 02:26:37 -04:00
syl20bnr 40f28c7d12 auto-completion: fix duplicate addtion of backends
Reverting a buffer could put multiple entries of the same backend in the buffer
local `company-backends` variable.
This is due to the fact that we mutate `company-backends-xxxx-mode` variable
with:
         (setq ,backends-var-name
               (mapcar 'spacemacs//show-snippets-in-company
                      ,backends-var-name)))

Solution is to add a new variable that won't be mutated when we add the support
for snippets.
2018-05-12 02:03:33 -04:00
syl20bnr 439dafb4dd auto-completion: fix variables not set with multiple modes
When multiple modes where provided to macro spacemacs|add-company-backends along
with variables, only the first mode was taken into account as the `variables`
variable was nil after the first interation on `modes`.
2018-05-12 01:53:54 -04:00
Chao Shen 031aaa164e Remove mapping <c-f> to select the frist completion. 2018-01-09 23:52:40 -05:00
syl20bnr 326965d4ce Happy New Year 2018! 2018-01-04 02:00:25 -05:00
Steven Allen 6b7aa70428 Late expand completion backends in the `spacemacs|add-company-backends` macro
Otherwise, the Haskell layer throws an eager expansion error because
`layers/+lang/haskell/funcs.el`, which calls this macro, is loaded before
`layers/+completion/auto-completion/config.el`, which defines
`spacemacs-default-company-backends`.
2017-04-11 23:51:29 -04:00
syl20bnr 12827c03d8 core: add :hooks property to spacemacs|add-company-backends
Allow to control wether to hook the generated hook functions or not.
2017-03-19 12:40:36 -04:00
syl20bnr fb27ede558 Bump year in copyright headers
Happy New Year 2017!
2017-01-05 23:08:17 -05:00
syl20bnr 74fdbb6795 Refactor and simplify company backends declaration
Enabling a company backend for a specific mode was a tedious tasks with code
scattered at different locations, one for local variable definitions, one for
company hook function definitions and another where the backends were pushed to
the local variables (which was problematic, since we ended up pushing the same
backends over and over again with `SPC f e R`, pushes have been replaced by
add-to-list calls in the new macro).

All these steps are now put together at one place with the new macro
spacemacs|add-company-backends, check its docstring for more info on its
arguments.

This macro also allows to define arbitrary buffer local variables to tune
company for specific modes (similar to layer variables via a keyword :variables)

The code related to company backends management has been moved to the
auto-completion layer in the funcs.el file. A nice side effect of this move is
that it enforces correct encapsulation of company backends related code. We can
now easily detect if there is some configuration leakage when the
auto-completion layer is not used. But we loose macro expansion at file loading
time (not sue it is a big concern though).

The function spacemacs|enable-auto-complete was never used so it has been
deleted which led to the deletion of the now empty file core-auto-completion.el.

The example in LAYERS.org regarding auto-completion is now out of date and has
been deleted. An example to setup auto-completion is provided in the README.org
file of the auto-completion layer.
2017-01-02 00:39:04 -05:00
Eivind Fonn 977a29316b Fix unbound holy-mode error 2016-10-29 15:11:36 +02:00
MadAnd a7232d53e7 Fix auto complete with key sequence in Hybrid mode
Implement handling of `evil-hybrid-state-map` keymap to make completion
with a key sequence work in Hybird state.
2016-08-30 16:18:13 +02:00
Eivind Fonn 886aac6386 Fix C-k not working in company-quickhelp-mode 2016-08-30 16:00:19 +02:00
MadAnd 309e6eb4bb Fix smartparens after nested snippet expansions
Current implementation, #1644, doesn't handle the nested snippet
expansion properly, so you end up with smarparens disabled. Very
annoying.

I improved the implementation to remember the current state of
smartaperns before a top-level snippet expansion and preserve on any
nested snippet expansions.

Also, some housekeeping of the related code:
* Move hook handlers to the `funcs.el`.
* Add comments about yasnippet hooks subtleties relevant to the issue.

Fixes #1512
2016-08-08 13:42:45 +02:00
syl20bnr e1a6f39e0b auto-completion: move functions to funcs.el 2016-04-21 21:35:27 -04:00
syl20bnr 9d0558992c layers directory: create new categories
+chat
+checkers
+emacs
+intl
+os
+pair-programming
+tags
+theme
+web-services
2016-03-23 21:39:43 -04:00
Renamed from layers/auto-completion/funcs.el (Browse further)