Skip to content

Conversation

@ickshonpe
Copy link
Contributor

@ickshonpe ickshonpe commented Nov 20, 2025

Objective

Add naive support for text gizmos.

Draw a label at a given point using the default font. 2d only, no rich text support, no anchors, no rotation.

Fixes #16490

Solution

I'm not familiar with the gizmos implementation, so my plan is to hack together something limited that just about works, and then hand it over to a rendering SME or someone to push over the line.

Done

  • Added a text_2d method to the Gizmos SystemParam that adds text gizmos for rendering to a GizmoTextBuffer resource.
  • In post update, gizmo_text_system does text layout for each text gizmo queued in the GizmoTextBuffer and adds the resulting glyph geometry to the GizmoBuffer.

Todo

  • Rendering isn't implemented yet, need to implement some sort of TextGizmoPipeline in bevy_gizmos_render.
  • I started off by adding a text_gizmos feature-gate, but it overcomplicated things at this stage, so removed it for now. I'll add it back at the end.
@Zeophlite Zeophlite added C-Feature A new feature, making something new possible A-Gizmos Visual editor and debug gizmos A-Text Rendering and layout for characters S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged M-Release-Note Work that should be called out in the blog due to impact D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes labels Dec 3, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Dec 3, 2025

It looks like your PR has been selected for a highlight in the next release blog post, but you didn't provide a release note.

Please review the instructions for writing release notes, then expand or revise the content in the release notes directory to showcase your changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Gizmos Visual editor and debug gizmos A-Text Rendering and layout for characters C-Feature A new feature, making something new possible D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes M-Release-Note Work that should be called out in the blog due to impact S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged

2 participants