GNU ELPA - company

company Atom Feed

Description
Modular text completion framework
Latest
company-1.0.2.tar (.sig), 2024-Sep-23, 2.63 MiB
Maintainer
Dmitry Gutov <dmitry@gutov.dev>
Website
http://company-mode.github.io/
Browse ELPA's repository
CGit or Gitweb
Badge
Manual
company

To install this package from Emacs, use package-install or list-packages.

Full description

Company is a modular completion framework.  Modules for retrieving completion
candidates are called backends, modules for displaying them are frontends.

Company comes with many backends, e.g. `company-etags'.  These are
distributed in separate files and can be used individually.

Enable `company-mode' in all buffers with M-x global-company-mode.  For
further information look at the documentation for `company-mode' (C-h f
company-mode RET).

If you want to start a specific backend, call it interactively or use
`company-begin-backend'.  For example:
M-x company-abbrev will prompt for and insert an abbrev.

To write your own backend, look at the documentation for `company-backends'.
Here is a simple example completing "foo":

(defun company-my-backend (command &optional arg &rest ignored)
  (interactive (list 'interactive))
  (pcase command
    (`interactive (company-begin-backend 'company-my-backend))
    (`prefix (company-grab-symbol))
    (`candidates (list "foobar" "foobaz" "foobarbaz"))
    (`meta (format "This value is named %s" arg))))

Sometimes it is a good idea to mix several backends together, for example to
enrich gtags with dabbrev-code results (to emulate local variables).  To do
this, add a list with both backends as an element in `company-backends'.

Old versions

company-1.0.1.tar.lz2024-Sep-212.04 MiB
company-1.0.0.tar.lz2024-Sep-212.04 MiB
company-0.10.2.tar.lz2024-Mar-312.03 MiB
company-0.10.1.tar.lz2023-Oct-062.03 MiB
company-0.10.0.tar.lz2023-Oct-042.03 MiB
company-0.9.13.tar.lz2020-Jul-2666.1 KiB
company-0.9.9.tar.lz2018-Dec-1372.6 KiB
company-0.9.8.tar.lz2018-Dec-0972.5 KiB
company-0.9.7.tar.lz2018-Nov-0672.4 KiB
company-0.9.6.tar.lz2018-Feb-2370.2 KiB
company-0.9.5.tar.lz2018-Feb-1870.0 KiB
company-0.9.4.tar.lz2017-Jul-1567.3 KiB
company-0.9.3.tar.lz2017-Mar-2958.6 KiB
company-0.9.0.tar.lz2016-Jun-2364.4 KiB
company-0.8.12.tar.lz2015-Mar-0559.9 KiB
company-0.8.0.tar.lz2014-Apr-2052.0 KiB
company-0.7.3.tar.lz2014-Mar-2549.8 KiB
company-0.6.14.tar.lz2014-Jan-2645.6 KiB
company-0.6.tar.lz2013-Mar-2034.5 KiB
company-0.5.tar.lz2012-Nov-2933.0 KiB

News

History of user-visible changes

2024-09-23 (1.0.2)

  • More reliable cache expiration (at the beginning of completion).

2024-09-21 (1.0.1)

  • Fix for failover from a backend group to the next backend.

2024-09-21 (1.0.0)

  • company-complete-common now performs generalized expand common part completion when the backend supports that. In particular, for completion-at-point-functions it queries completion-try-completion. company-dabbrev-code and company-etags also do that when completion-styles support is enabled.
  • company-dabbrev-other-buffers and company-dabbrev-code-other-buffers can now take a function as its value (#1485)
  • Completion works in the middle of a symbol (#1474).
  • New user option company-inhibit-inside-symbols. Set it to t to switch closer to the previous behavior.
  • Improved behavior when user types new character while completion is being computed: better performance, less blinking (in the rare cases when it still happened). This affects native async backends and is opt-in with company-capf.
  • For that, company-capf supports interrupting computation on new user input. Completion functions that want to take advantage of this behavior should include :company-use-while-no-input t in the returned properties.
  • company-elisp has been removed. It's not needed since Emacs 24.4, with all of its features having been incorporated into the built-in Elisp completion.
  • company-files shows shorter completions. Previously, the popup spanned the whole absolute file name being completed, and now it starts after the nearest directory separator (#1040).
  • New user option company-capf-disabled-functions (#1437).
  • Better support for yas-key-syntaxes (#1268).
  • New user option company-tooltip-scrollbar-width with default 0.4.
  • The tooltip uses a more complex rendering approach, supporting double width/CJK characters, as well as buffer text of different sizes (#1394). variable-pitch-mode is also working better, although when using it it's recommended to customize the company-tooltip face to be monospaced.
  • New user option company-dabbrev-code-completion-styles. Use it to enable fuzzy matching in company-dabbrev-code (#1215). An example configuration one can try:
(setq company-dabbrev-code-ignore-case t
      company-dabbrev-code-completion-styles '(basic flex))
  • New user option company-etags-completion-styles, to be used the same way.

  • The backend command keep-prefix is being phased out. The built-in backends implement it internally now, which resolved a number of sharp edges (mostly) around "grouped" backends. To make that easier, several helpers were added, such as company-cache-fetch and company-substitute-prefix (#1411). And company-ispell uses the cache to keep the currently selected dictionary loaded in memory between completions.

  • The "length override" behavior in grouped backends now acts on each backend separately (#1405).

2023-10-08 (0.10.2)

  • More company-auto-update-doc-related fixes.
  • Better handling of C-g performed inside a doc-buffer handler (#1408).

2023-10-06 (0.10.1)

  • Fix upgrading from 0.9.13 when the package is already loaded (#1406).

2023-10-04 (0.10.0)

... ...