Skip to content

Comments

Add the SVG Preview render mode in place of the Vello option in the preferences#3797

Merged
Keavon merged 7 commits intomasterfrom
svg-preview-render-mode
Feb 22, 2026
Merged

Add the SVG Preview render mode in place of the Vello option in the preferences#3797
Keavon merged 7 commits intomasterfrom
svg-preview-render-mode

Conversation

@Keavon
Copy link
Member

@Keavon Keavon commented Feb 22, 2026

Closes #3512

Followup work: remove the now-dead code for Outline render mode's SVG renderer, since we only want to keep the Vello implementation for that around from now on to simplify things as we phase out full support for non-WebGPU browsers. And we want to guard against any existing documents saved in Outline mode from attempting to draw in outline mode; those should be redirected to SVG Preview mode just like Normal (Vello) mode is.

@gemini-code-assist
Copy link

Summary of Changes

Hello @Keavon, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request enables a new SVG preview render mode within the editor, providing users with a direct visual representation of their artwork's SVG export. Concurrently, it streamlines the rendering system by removing the Vello renderer preference, consolidating rendering decisions within the core logic. The changes ensure that the appropriate rendering pipeline (raster or SVG) is selected based on the active render mode and hardware capabilities, enhancing consistency and user experience.

Highlights

  • SVG Preview Render Mode: Introduced a new "SVG Preview" render mode, allowing users to visualize how their artwork will appear when exported as an SVG.
  • Vello Renderer Preference Removal: Removed the Vello renderer preference from the editor's settings and associated UI/logic, simplifying rendering configuration.
  • Dynamic Rendering Pipeline Selection: Updated the rendering pipeline to dynamically switch to SVG export format when the "SVG Preview" mode is active or when WebGPU is unavailable.
  • Viewport Hole Punch Adjustment: Adjusted the viewport "hole punch" behavior to be inactive during SVG Preview mode on non-WASM targets.
Changelog
  • editor/src/messages/dialog/preferences_dialog/preferences_dialog_message_handler.rs
    • Removed the Vello renderer preference UI from the preferences dialog.
  • editor/src/messages/portfolio/document/document_message_handler.rs
    • Imported wgpu_available for conditional logic.
    • Enabled the "SVG Preview" radio button in the render mode selection.
    • Disabled the "SVG Preview" button if WGPU is not available on WASM targets.
  • editor/src/messages/portfolio/portfolio_message.rs
    • Removed the UpdateVelloPreference message.
  • editor/src/messages/portfolio/portfolio_message_handler.rs
    • Added conditional UpdateViewportHolePunch message based on SvgPreview render mode for non-WASM targets.
    • Removed the message handling for PortfolioMessage::UpdateVelloPreference.
  • editor/src/messages/portfolio/utility_types.rs
    • Removed the use_vello field from PersistentData.
  • editor/src/messages/preferences/preferences_message.rs
    • Removed the VelloPreference message type.
  • editor/src/messages/preferences/preferences_message_handler.rs
    • Removed the vello_preference field and related logic.
    • Removed the use_vello helper function.
    • Updated editor_preferences to no longer include vello_preference.
    • Removed calls to PortfolioMessage::UpdateVelloPreference.
  • editor/src/node_graph_executor/runtime.rs
    • Imported RenderMode.
    • Modified rendering logic to use Svg export format if RenderMode::SvgPreview is active or WGPU is unavailable.
  • frontend/src/components/widgets/inputs/RadioInput.svelte
    • Refactored CSS for hover states and narrow styles.
  • frontend/wasm/src/editor_api.rs
    • Corrected a semicolon to improve code style.
  • node-graph/graph-craft/src/wasm_application_io.rs
    • Removed the VelloPreference enum.
    • Removed the vello_preference field from EditorPreferences.
    • Removed the use_vello method from the GetEditorPreferences trait implementation.
    • Updated the Default implementation for EditorPreferences.
  • node-graph/graphene-cli/src/main.rs
    • Removed the vello_preference initialization from EditorPreferences.
  • node-graph/libraries/application-io/src/lib.rs
    • Removed the use_vello method from the GetEditorPreferences trait.
    • Reordered fields within the RenderConfig struct.
    • Removed the use_vello implementation from DummyPreferences.
  • node-graph/libraries/vector-types/src/vector/style.rs
    • Uncommented and enabled the SvgPreview variant in the RenderMode enum.
Activity
  • No specific activity (comments, reviews, progress) has been recorded for this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

gemini-code-assist[bot]

This comment was marked as resolved.

@Keavon Keavon changed the title Add the "SVG Preview" render mode in place of the Vello option in the preferences Add the SVG Preview render mode in place of the Vello option in the preferences Feb 22, 2026
@Keavon Keavon enabled auto-merge February 22, 2026 20:25
@Keavon Keavon added this pull request to the merge queue Feb 22, 2026
Merged via the queue into master with commit 9f2c871 Feb 22, 2026
5 checks passed
@Keavon Keavon deleted the svg-preview-render-mode branch February 22, 2026 20:28
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

Successfully merging this pull request may close these issues.

Make SVG renderer a preview render mode and take Vello out of preferences

3 participants