-
Notifications
You must be signed in to change notification settings - Fork 74
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
No way to format document symbols and outline with custom symbol filters #633
Comments
What is your suggestion to customize that? |
I think I would see it working 1 of 2 ways: Option 1: Or {
"pattern": "build*.xml",
"expressions" :[
{
"xpath": "//target/@name",
"format":
{
// keep the value of the attribute "name" on the same line
// as the target element, and only show the attribute value
"position": "sameLine",
"valueOnly": true
}
},
{
"xpath": "//text()"
}
]
} Example mocked up screenshot: I would think this specific case would only be applied when there is only 1 attribute being shown in the outline. For cases where there is more than 1 attribute, I certainly understand it making sense to show them nested under their elements. For my specific use of this, it would be very helpful to be able to quickly see all the target names in my build.xml file (and it would be nice for all the property names too). But I could certainly see this kind of customization point being useful for other xml based files as well. |
Ok I see the idea thanks. For the moment, I don't know when we will able to implement this feature. |
Ok sounds good, I appreciate you taking a look at this :) |
proposed server side fix for: redhat-developer/vscode-xml#633 if the change looks like a good approach, automated tests and documentation updates will follow in a separate commit
client side documentation update for: redhat-developer#633 this PR is dependent on the server side PR: eclipse/lemminx#1151
client side documentation update for: redhat-developer#633 this PR is dependent on the server side PR: eclipse/lemminx#1151 updating commits for gpg sig, sorry for the noise
proposed server side fix for: redhat-developer/vscode-xml#633 Signed-off-by: Charlie Cadwell <twoseascharlie@gmail.com>
client side documentation update for: #633 this PR is dependent on the server side PR: eclipse/lemminx#1151
Closing this issue as this has been implemented with: |
There doesn't appear to be a way to control the way custom symbol filter rules are displayed in the outline.
Ex:
using this config:
If I have a symbol filter for text, it is shown next to the element in the outline:
If I have a symbol filter for an attribute, it is shown as a child element in the outline:
For an extension that has great customizability, this seems like a missing customization point. I would love the ability to move the attribute in the outline to the same line as the xml element.
The text was updated successfully, but these errors were encountered: