Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autocompleted attribute doesn't display documentation for popped up attribute values #760

Closed
bimimicah opened this issue Aug 12, 2022 · 3 comments

Comments

@bimimicah
Copy link

This is a second problem discovered while investigating #736:

  • If you create the attribute (instead of typing manually) by typing a space, the first letter, then choose the attribute name from the dropdown, the attribute will be autocompleted, and the enumerated attribute values will appear in a dropdown, as expected. However, none of them will display documentation, even if all of them have documentation in the xsd.

For illustration:

image

  • Type <space>, then 'a'

image

  • Press <tab>

image

Originally posted by @bimimicah in #736 (comment)

@bimimicah
Copy link
Author

My guess of a model of LSP interaction, copied from #736:

  1. user types 'a', triggers a textDocument/completion call to the LSP server (for the attributes beginning with 'a'), returning a list of completion items including documentation

  2. user selects the item from the list and presses , choosing the completion item, and triggering a second textDocument/completion call to the LSP server (for the chosen attribute's values), which should also return a list of completion items including documentation?

@angelozerr My guess is maybe the CompletionItems returned in step 2 do not include the 'documentation' attribute. Could that be the issue?

I see your idea but it will require some hack on client side so it will require to do this Hack for vscode eclipe sublime etc wuich is not the goal of lsp.

Please create an issue for this problem. Perhaps there is a solution that I miss with lsp . We should study in détail the mroblem.

The 'documentation' attribute is built-in to the 'CompletionItem' Interface, so I would hope that it does not require a hack to fix? I may be misunderstanding something. Thanks for your help.

@angelozerr
Copy link
Contributor

We use LSP choice which supports only a list of string, I fear that we can not fix this issue because of LSP limitation.

@angelozerr
Copy link
Contributor

I close this issue since LSP doesnt provide this feature.

@angelozerr angelozerr closed this as not planned Won't fix, can't repro, duplicate, stale Nov 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants