bevy/crates/bevy_text/src
Mark Nokalt 306c1ac617 Rename Handle::as_weak() to cast_weak() (#5321)
# Objective

Following discussion on #3536 and #3522, `Handle::as_weak()` takes a type `U`, reinterpreting the handle as of another asset type while keeping the same ID. This is mainly used today in font atlas code. This PR does two things:

- Rename the method to `cast_weak()` to make its intent more clear
- Actually change the type uuid in the handle if it's not an asset path variant.

## Migration Guide

- Rename `Handle::as_weak` uses to `Handle::cast_weak`

    The method now properly sets the associated type uuid if the handle is a direct reference (e.g. not a reference to an `AssetPath`), so adjust you code accordingly if you relied on the previous behavior.
2022-10-28 22:43:14 +00:00
..
error.rs Limit FontAtlasSets (#5708) 2022-09-19 16:12:12 +00:00
font_atlas_set.rs Limit FontAtlasSets (#5708) 2022-09-19 16:12:12 +00:00
font_atlas.rs Replace old renderer with new renderer (#3312) 2021-12-14 03:58:23 +00:00
font_loader.rs Add support for OTF fonts (#1200) 2021-01-03 12:10:23 -08:00
font.rs small and mostly pointless refactoring (#2934) 2022-02-13 22:33:55 +00:00
glyph_brush.rs Rename Handle::as_weak() to cast_weak() (#5321) 2022-10-28 22:43:14 +00:00
lib.rs Resolve most remaining execution-order ambiguities (#6341) 2022-10-27 12:56:03 +00:00
pipeline.rs Fixes incorrect glyph positioning for text2d (#6273) 2022-10-18 13:28:34 +00:00
text2d.rs fix nightly clippy warnings (#6395) 2022-10-28 21:03:01 +00:00
text.rs bevy_reflect: Update enum derives (#5473) 2022-08-02 22:40:29 +00:00