Questions tagged [company-mode]

Company-mode is a text completion framework for Emacs. The name stands for "complete anything". It uses pluggable back-ends and front-ends to retrieve and display completion candidates.

Filter by
Sorted by
Tagged with
0 votes
0 answers
17 views

How to trigger completion using company mode and tide?

I use tide for editing TypeScript files with default setup from documentation using company mode. I was just watching a tutorial about Prisma (TypeScript ORM) that uses VS Code and shows an available ...
  • 681
0 votes
0 answers
26 views

Completion in lsp-mode: incremental restriction and fuzzy search, how to?

I am trying to use lsp-mode in emacs. My problem applies to both C++ and Python code. I have confirmed I am using company-mode for completion. When I type a '.' I trigger completion in company-mode ...
0 votes
1 answer
154 views

Company-dabbrev does not work on eglot

I use emacs 28/29 on windows. this is my config. (use-package company :ensure t :pin gnu :init (global-company-mode) :config (setq company-backends '(company-dabbrev) company-idle-delay ...
0 votes
0 answers
30 views

using emacs + eglot + pascal-language-server + company-mode

My stack is the following: i use eglot as an lsp client i use company-mode for completion i use pascal-language-server which i packaged myself, so this could be the issue I got the same stack ...
0 votes
1 answer
32 views

Company doesn't load with Yasnippet

Facing strange problem with auto-completion company-mode. I use the packages Company mode and Yasnippet. When I'm typing in a buffer, I get autocompletion suggestions from Company with Yasnipper. But ...
0 votes
0 answers
22 views

Display function signature in completion popup menu instead of status line with SLIME/SLY in Emacs

What the title says. I'd like the function signature for functions in Common Lisp to display next to the function name in the company-mode autocomplete popup menu instead of at the bottom of the ...
1 vote
0 answers
25 views

Completing words with hyphens with company

I am using company buffer completion. But cannot get to match ligatures with hyphen in them. What can I do to complete parts containing hyphens? Suppose I have the following text ;; This buffer is ...
  • 207
0 votes
1 answer
66 views

How can I turn off Company mode in only some major modes? [duplicate]

I use company when coding. I currently have it set to global. I would like to turn it off for a few major modes. However, instead of turning it off globally, I only want to deactivate company for 2 or ...
0 votes
0 answers
21 views

company-clang pointer alignment

I would like to change the pointer alignment of company-clang. For instance, if I select the completion of a function I wish to see the arguments with pointers or references aligned to the left, ...
  • 1
0 votes
0 answers
14 views

rust-mode with snippets and tabnine

I want to use multiple completion backends with rust-mode. Rust mode automatically enabled completion, but I want to add snippets and tabnine, but for some reason it isn't working. I tried also to ...
0 votes
0 answers
12 views

Company completion overwriting existing text

I am using company with lsp-java, but I think this is a company problem. I have some code like void quz(int bar, int longNamedVariable) { foo(bar, longNamedVariable); } I packaged all the ...
0 votes
0 answers
18 views

LSP clangd + company-mode writes ${n: Variable} strings

I am not sure what exactly to google, on this issue. I have emacs 28.1 installed, with LSP-clangd and company-mode installed. Suppose a function have signature int func(int i, int j), then emacs ...
  • 113
0 votes
0 answers
21 views

Bind all company completion to <Tab>

I am bit confused about different company completion modes. How can I make company always accept completion by instead of ? Currently these three commands I use most: company-complete-selection ...
  • 113
0 votes
1 answer
19 views

Symbol's value as variable is void: company-transformers

I am trying to prevent company-mode from autocompleting numbers. I added the following to my init file. (push (apply-partially #'cl-remove-if (lambda (c) (string-match-p "\\`[0-9]...
  • 163
0 votes
0 answers
56 views

dumb-jump and xref: how to display candidates in a popup below point?

I'm trying to use dumb-jump and set it to use the xref backend as per the instructions . When i do M-. emacs splits screen and opens an xref buffer. But what I want looks like this: It seems like it ...
  • 139
0 votes
0 answers
62 views

When using company and lsp, why does the placeholder text sometimes not get replaced?

In a buffer in c-mode with the following content (with point after retu), pressing enter completes to return expression;. int main(int argc, char** argv) { retu } Point is now at the beginning of ...
  • 143
0 votes
0 answers
28 views

Making words occurring in a specific file available to company-mode

I am using company-mode with (setq company-dabbrev-other-buffers 'all). Although this should search other buffers, I want that the words occurring in a particular files are made available for company-...
  • 455
0 votes
0 answers
18 views

Completion of word or abbreviation

I would like a drop-down menu similar to company-mode to complete words, but then insert either the word completion or the abbreviation associated with it. I take example from the following ...
  • 455
0 votes
1 answer
64 views

When to set configuration variables for company-mode

I have a function that calls global-company-mode with argument 1 (enable) or -1 (disable). A user can enable and disable however many times he wants. Do I have to set the configuration variables for ...
  • 455
0 votes
0 answers
87 views

Enabling and disabling global-company-mode without hook

I want to be able to enable and disable global-company-mode by calling elisp functions in my init file. Could I use (global-company-mode 1) to enable and (global-company-mode -1) to disable Does this ...
  • 455
1 vote
1 answer
31 views

Enabling company-mode with variable setup

I want to enable and disable company-mode. Would I have to reset setup variables, everytime I want to enable company-mode? Should I call company-setup before calling company-enable. Is the ...
  • 455
0 votes
0 answers
21 views

How to setting company completion popup to scroll by a mouse wheel?

I tried adding the following code: (use-package popup :config (define-key popup-menu-keymap [mouse-4] 'popup-next) (define-key popup-menu-keymap [mouse-5] 'popup-previous) ) but it has no effect
0 votes
0 answers
100 views

irony flycheck reports include files not found

I struggle configuring irony and flycheck. The problem that occurs is that the irony does not find the include files. For example, I have: #include <algorithm> Neither is algorithm proposed by ...
  • 131
0 votes
0 answers
426 views

Python LSP Problems

I am having a strange problem. I have my init.el, ~/.emacs.d/lisp and a Python file tcvw.py synced between two computers running the exact same version of Emacs (27.1) and same OS (Debian Sid). In ...
2 votes
1 answer
168 views

What is the name of the face that appears in this list of company completions?

If I have company-mode enabled, and I type in company like this. (company) I then see a list of completions that I can select. My question is - apart from the currently selected item, the word ...
0 votes
0 answers
61 views

company mode: seamless scrolling for completion suggestions

How do I enable seamless scrolling for company-mode suggestions? To wit, I'd like to return to the top suggestion if I scroll down from the last, and go the the bottom if I scroll up from the first. I'...
2 votes
1 answer
145 views

company-mode popups and magit current region are dark while current theme is light

I've been successfully using lsp-mode and magit for a while with a light theme (leuven). Today I was messing with something seemingly unrelated (company-mode and auto-complete settings in my ~/.emacs ...
0 votes
3 answers
436 views

emacs stalling when looking up definitions with lsp-mode and gopls

I'm using lsp-mode as lsp client and gopls as lsp backend in order to lookup function and variable definitions in go projects. On a given large repository (kubernetes) that I recently wiped and cloned ...
0 votes
1 answer
123 views

Delete duplicates from company popups

I use the following snippet to set up company-mode for text files and derived modes. I use a curated word list as the source for company-ispell. (progn (defun sb/company-text-mode () "Add ...
0 votes
1 answer
204 views

unexpected "Visit tags table (default TAGS)" prompt when looking up definitions with lsp-mode and gopls

I'm using company-mode with lsp-mode as lsp client and gopls as lsp backend in order to lookup function and variable definitions in go projects. On some repositories, when I want to lookup a ...
0 votes
1 answer
77 views

Company-anaconda works with root level Python installation but stops working when switching to conda environment with conda.el

I am on Arch Linux and use anaconda-mode with company-anaconda (here is a minimal init.el with which I can replicate the issue). I have Python installed both at root level from the primary package ...
0 votes
1 answer
578 views

How to enable yasnippets for all modes?

Company doesn't show snippets in some modes e.g. python or sh. Yet yas/describe-tables displays all snippets. In other modes e.g. org,emacs-lisp, snippets are shown as expected. Looking at company-...
  • 643
0 votes
1 answer
679 views

How does company mode work?

I am trying to set up a quasi-IDE experience on Emacs for C/++, and I installed the company package. However, it seems it doesn't work. For what I undersood, company by itself is only the front-end. ...
1 vote
1 answer
49 views

Why is Emacs Entering the Debugger despite a condition case wrapper?

The context of my question: I was editing some clojure code, and point was inside a comment, and to the right of three characters: `abc'. I ran the command: M-x company-diag, to ask company mode for a ...
0 votes
1 answer
258 views

Why is company mode not working with company-tng?

I've got a setup like the following in my init.el (use-package company :ensure t :after lsp-mode :hook (after-init . global-company) :bind (:map company-active-map ("<tab>&...
  • 133
2 votes
1 answer
499 views

How to use multiple backends in priority for company-mode

If I do (setq company-backends '(company-tabnine company-capf company-yasnippet)) Then company will try company-tabnine to give me completions. If tabnine fails, it will try capf. If instead I do (...
  • 151
1 vote
1 answer
817 views

How do I change backend for company?

Recently I have discovered tabnine, a really good completion backend. I wanted to use it in emacs. So I went through the installation procedure and now I have it. But when I M-x company-diag, it shows ...
1 vote
1 answer
106 views

How to turn off R help document popup when using ESS?

When I input a function, the R help document pops up automatically. It's very annoying. How to turn it off?
0 votes
2 answers
296 views

Company mode won't autocomplete variables with underscores

I have web-mode and company installed but company just seems to autocomplete the variables without underscores: With Emacs Lisp Mode With Web-mode ;; --- Company --- ;; Autocomplete with dropdown ...
  • 568
3 votes
0 answers
1k views

Company: backend company-capf error

I'm using emacs-lsp with company-capf. While editing an elisp file, it works fine. However, once I run eval-buffer, I get the following error when trying to use completion: Company: backend company-...
  • 131
1 vote
1 answer
273 views

can't get company-reftex-labels to work properly

I have tried to set the company-backend as described on their github page and did not end up with the sweet resulting pop-up completion, in ref as in their image My image: their image: What am I ...
0 votes
1 answer
1k views

company-mode: no completions found

I am new to emacs (long-time vim user). Specifically, I am using doom-emacs. Doom is supposedly set up to use company-mode for auto completion, but I have not gotten it to work. I have the following ...
  • 101
1 vote
1 answer
229 views

Using company mode to complete sentence

As I understand, company mode can help complete the word, but not a sentence. I would like to complete a fragment of sentence. I would like to complete fragment e.g. "portal and hepatic doppler&...
  • 573
0 votes
1 answer
243 views

Emacs company-css, where is the completion of css values?

Company-mode completion seems a little weak in emacs. Is it my configuration? Property completion seems simple enough: strong { color: red; /* <= color is the property */ } Where red is the ...
1 vote
0 answers
169 views

Insert org mode links via helm-mini or refile (or equivalently using e.g. company mode)

I often want to insert a link to another file (that would be easily accessible via helm-mini or refile). I have to do this long dance of going into the target file (and potentially headline), storing ...
  • 1,553
0 votes
0 answers
63 views

Company won't complete at the beginning of org mode headline

For example, with the given text * algorithm * algo<cursor> Fun company-complete it won't complete the word aglorithm. If the cursor is not at the beginning of a headline, then completion works ...
  • 747
1 vote
0 answers
129 views

Company printing stuff to console in ESS

I am using company with ESS, and in some contexts, company will print weird documentation messages to the console: (list "" '(("..." . "")) '("recursive" "use.names" "..." "x" "replace" "drop_null" "...
0 votes
1 answer
335 views

How to make company-lsp case sensitive?

Currently if I try to complete a work, the case of the prefix is ignored with company-lsp. From looking into the code, company-lsp is hard-coded to use ignore-case. As at the time of writing company-...
  • 7,979
1 vote
1 answer
358 views

Why are the company-mode's drop downs ragged?

Here is how my company-mode's drop-downs look, As you can tell, they are uneven, ugly and somehow a different font than what my Emacs is using (Iosevka). I found this question, but did not quite ...
  • 877
2 votes
1 answer
456 views

At what point are file-local and dir-local variables applied to a newly-loaded buffer?

I'm currently attempting to call the function company-org-roam--init-hook from org-mode-hook in order to enable the company-org-roam backend in org-roam buffers. In some of the files in which this ...

1
2 3 4 5