Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
bevyengine
GitHub Repository: bevyengine/bevy
Path: blob/main/release-content/release-notes/text_gizmos.md
9350 views
---
title: "Text Gizmos" authors: ["@ickshonpe"] pull_requests: [22732]
---

Gizmos can now render text using a built-in stroke font.

usage

Use the text and text_2d to draw text using line segments:

fn draw_text(mut gizmos: Gizmos) { gizmos.text_2d( Isometry2d::IDENTITY, // Position and rotation of the text "Hello Bevy", // Only supports ASCII text 40.0, // Font size in pixels Vec2::ZERO, // Anchor point, zero is centered Color::WHITE, // Color of the text. ); }