names icon indicating copy to clipboard operation
names copied to clipboard

How to deal with completions?

Open CestDiego opened this issue 9 years ago • 3 comments

How to complete functions that are defined in the current namespace. Is there even a way for company or autocomplete to be context aware and complete functions without the namespace while inside the defined namespace and then complete functions with the namespace when writing code outside of the package? as in trying to setq a variable defined in our package?

CestDiego avatar Aug 31 '15 05:08 CestDiego

Right now there's nothing as smart as that. The company-ddabrev backend is capable of completing names without the namespace, and the company-capf offers names with the namespace. So if you use both backends you should be offered both options at least.

That said I'm about to release another package (Nameless), whichi will provide a similar effect to Names with much less fuss (and it works with company). So hang tight.

Malabarba avatar Sep 01 '15 11:09 Malabarba

I saw nameless package :) and was curious about it. but will it mess with the fill-column?

CestDiego avatar Sep 01 '15 15:09 CestDiego

There's a variable in it called nameless-affect-indentation-and-filling. So you can set it to nil if you don't want to affect the fill-column, or you can set it to 'outside-strings if you're only worried about strings.

Malabarba avatar Sep 01 '15 16:09 Malabarba