DeltaXML / vscode-xslt-tokenizer

VSCode extension for highlighting XSLT and XPath (upto 3.0/3.1)
MIT License
46 stars 4 forks source link

No options for simple and complex variables in auto-completion for message are available #135

Closed Cutuchiqueno closed 7 months ago

Cutuchiqueno commented 7 months ago

The section on debugging in the documentation recommends to use special auto-completion for xsl-message and shows 3 options blank, simple-variables and complex variables. However, when I instagate auto-completion only blank exists. Thus, I am not able to generate the corresponding debugging template.

pgfearo commented 7 months ago

There is an important restriction on the xsl:message auto-completion:

It only offers simple-variables and _complexvariables options in the auto-complete list for variables declared before the cursor position and inside the immediate scope of the current XSLT instruction element.

In most cases, this restriction is helpful because it helps avoid overwhelming the user with too much information in the xsl:message output in one go. Each separate xsl:message has it's own header to it's clearer when the output has come from.

That said, I've found this can be an annoyance for example when I want to print out the values of global xsl:param and xsl:variable declarations.

I will improve the documentation to mention this restriction.

Cutuchiqueno commented 7 months ago

Thanks for the clarifications. It works for local variables in scope, now that I looked out for situations in which local variables exist.