posit-dev / positron

Positron, a next-generation data science IDE
https://positron.posit.co
Other
2.76k stars 82 forks source link

Ark: Completions should be sensitive to the text on the RHS of the cursor #2574

Open lionel- opened 7 months ago

lionel- commented 7 months ago

From https://github.com/posit-dev/positron-beta/discussions/47

Screen Recording 2024-03-29 at 09 51 35

I think that's annoying enough, and probably not too hard to fix, we'd want to add that to public beta?

juliasilge commented 7 months ago

Is this a completions issue that should get added to https://github.com/posit-dev/positron/issues/1603?

lionel- commented 7 months ago

I've just added it

lionel- commented 6 months ago

Relatedly, @hadley notes:

can completions use text to the right of the cursor as well as text to the left? i.e. I type build_articles() which doesn’t work because I haven’t loaded pkgdown. So I press up, then cmd + left arrow and type pkgdown:: — that then autocompletes to pkgdown::as_pkgdown()build_articles()

olivroy commented 1 month ago

Is this related to this? Or should I open a new issue.

If I attempt to complete in this state (to the left of brackets

image

and I accept the completion suggestion. This gets inserted image

Also,I can't see help text for parameters on hovering

i.e. try to see the docs for the path argument here. image

Also, when pressing F1 at that location, I get the info message

juliasilge commented 1 month ago

We are tracking the extra parentheses being added here: https://github.com/posit-dev/positron/issues/4441

I'm not sure we do have anything about the behavior of F1 inside parentheses, so that would be a new issue but I do notice that RStudio also doesn't bring up Help in that situation.