dash-docs-el / helm-dash

Browse Dash docsets inside emacs
511 stars 59 forks source link

Feature request: additional helm-dash-candidate-format #160

Closed jesuspc closed 7 years ago

jesuspc commented 7 years ago

Currently there are three format tokens available:

%d - docset name %n - name of the token %t - type of the token

Even when using all of those there are still circumstances in which a search pattern outputs multiple results that can not be distinguished. For instance:

screen shot 2017-09-04 at 20 52 52

That's the same search pattern result in the Dash UI:

screen shot 2017-09-04 at 20 53 13

Note that in the second case there is additional information available (the module where the function is defined).

Would it be possible to provide additional candidate-format tokens so the additional information that is shown in the Dash.app also appears in the helm buffer?

kidd commented 7 years ago

Yes, it probably can be added.

We should take a look at the table structure of those docsets and see where to fetch that data.

kidd commented 7 years ago

I have a working solution for this (adding "%f" for filename), but I'm afraid there can be a performance deterioration. I'll push it in a branch and we should try it for some time.

I'm probably hairsplitting, but want to be sure that for normal cases there is no noticeable delay (ill-formed strings would probably show the delay, but f*ckit)

kidd commented 7 years ago

there you go. test it in that branch for now. https://github.com/areina/helm-dash/pull/161

jesuspc commented 7 years ago

That's great! Thanks!

screen shot 2017-09-06 at 19 32 37

It really makes a difference.

kidd commented 7 years ago

I'm merging it for now. If it becomes a performance issue, we can optimize it by evaluating %f lazily.