Open
Conversation
| "engines": { | ||
| "vscode": "^1.75.0", | ||
| "positron": "^2025.12.0" | ||
| "positron": "^2026.05.0" |
Collaborator
There was a problem hiding this comment.
@juliasilge warned me about aggressively bumping the positron version due to posit-dev/positron#11321, but I guess that's fixed now? If so, I can also remove some runtime version checks in the StatementRange code
jmcphers
added a commit
to posit-dev/positron
that referenced
this pull request
Mar 20, 2026
) This change adds metadata to execution requests so that it is possible for kernels to size plots to fit the viewport/DPI. For Quarto, we add cell options (such as `fig-width` and `fig-height`) to the execution metadata; for both Quarto inline outputs and Jupyter editors, we add the width of the output field and the device pixel ratio to the execution request. In notebooks, this means that your plots render crisply on Retina displays and are sized appropriately to your viewport: <img width="768" height="831" alt="image" src="https://github.com/user-attachments/assets/d2a5ac46-afb3-4a88-9b79-deab6d842b41" /> In Quarto inline outputs, this means that figure width/height are respected, too, so you get a preview with the correct aspect ratio: <img width="758" height="363" alt="image" src="https://github.com/user-attachments/assets/98a1505a-8620-43b0-ba0a-bec65ec01daa" /> Requires posit-dev/ark#1119 Requires posit-dev/qa-example-content#116 Related to quarto-dev/quarto#938 Addresses #8104 Addresses #12150 ### Release Notes <!-- Optionally, replace `N/A` with text to be included in the next release notes. The `N/A` bullets are ignored. If you refer to one or more Positron issues, these issues are used to collect information about the feature or bugfix, such as the relevant language pack as determined by Github labels of type `lang: `. The note will automatically be tagged with the language. These notes are typically filled by the Positron team. If you are an external contributor, you may ignore this section. --> #### New Features - Quarto inline output for R now respects `fig-width` and `fig-height` options (#12150) #### Bug Fixes - Plots in R notebooks are now sized correctly (#8104) ### QA Notes This PR doesn't attempt to size Python plots, though it takes the first step towards doing so by adding the right metadata. I added a hidden magic you can use to see what is being sent to Python: ```python %_positron_exec_metadata ``` The Ark equivalent is `.ps.internal(active_request())`. It also doesn't apply to the Plots pane, just notebook-style execution. We'll need to wait for a new Quarto extension to do that (quarto-dev/quarto#938). Test tags: `@:quarto` `@positron-notebooks` `@notebooks`
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change amends code/cell executions with the Quarto cell options. This will enable backends to change the way execution and rendering work based on cell options.
Note
This can't be merged until Positron 2026.05 is released. It is the first release that will include the new API parameters used here.