-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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
Gutter icon background size limited #6553
Conversation
By analyzing the blame information on this pull request, we identified @egamma and @alexandrudima to be potential reviewers |
Hi @kisstkondoros, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution! TTYL, MSBOT; |
@kisstkondoros This proposed change affects existing gutter decorations, such as the one used for breakpoints: I think it would also affect other extensions that use the gutter margin decorations. I really like the idea, but maybe the hover would be a better place to preview the image, as the gutter area is so limited and would only work for icon-type images: https://code.visualstudio.com/docs/extensionAPI/vscode-api#_languages I am not sure if our current |
How about making it configurable? |
I've updated the extension with the mentioned HoverProvider, MarkedString indeed supports images. |
Yes, that's the intend. |
@kisstkondoros Just a suggestion: maybe you can ship your extension with a generic image icon and render the same one in the gutter where images appear. That would cover nicely all image types. Do you still plan to do something in this PR? You could make it configurable by adding/adopting a new option in:
|
About the customization: i did something already in 3708e01, but I haven't changed the vscode.d.ts (i thought it's generated in a way), also I don't have the proper environment for building a version... This week I'll have a look. I appreciate Your suggestions, but I don't really like the idea to show just a generic icon. |
To be able to show images with arbitrary size on the gutter margin, the css property 'background-size' has been made configurable.
@alexandrudima Please have a look :) |
@kisstkondoros, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR. |
Gutter icon background size limited
@kisstkondoros Looks great, thank you! Extra kudos for the tests! ❤️ |
@alexandrudima also please note that I have used URI.parse instead of URI.file to support some special requirements for the mentioned plugin, I think it is not a breaking change but I'm not sure. |
Oh, it might be breaking, I'll write a quick plugin to double check... |
Ok, I checked for both Windows and Linux that absolute gutter paths still work fine even with |
might be related to #12111 @kisstkondoros Can you detail on the special requirements? That change actually is breaking: |
@jrieken I think I've thought about having support also for http/https uri's. With the proposed api change (string | URI) it would be even better 👍 |
@jrieken Thanks for giving a hint about the API change 🙇 |
To be able to show images with arbitrary size on the gutter margin,
the css property 'background-size' has been added.