I'm using groovy-mode with company-mode enabled; completion suggestions are in all lowercase. Whereas, in java-mode -- a built-in package, and others such as python-mode, ruby-mode, company is giving camelCase suggestions.

How can we get similar behaviour in groovy-mode?


If you use company-dabbrev as the backend of groovy-mode, the problem may be solved by

(setq company-dabbrev-downcase nil)

This command keeps the candidate as it is. If you think that ignoring case is better when the candidates is collected, you should add

(setq company-dabbrev-ignore-case t)

Don't set company-dabbrev-ignore-case 'keep-prefix' since only prefix is kept as it is. Writing my answer, I refer to this on github page.

  • If this command does not work well, I want to know your backend on groovy-mode. You probably use the different backend on groovy-mode. So tell the variable company-backends. – hewld Aug 8 '16 at 13:57

Not the answer you're looking for? Browse other questions tagged or ask your own question.