Add doc comments for the fields of Text2dBundle (#7749)

# Objective

Add doc comments for the fields of Text2dBundle.
This commit is contained in:
ickshonpe 2023-02-20 04:15:16 +00:00
parent 7ec9258f08
commit 093d420bb0

View file

@ -58,12 +58,19 @@ impl Text2dBounds {
/// [Example usage.](https://github.com/bevyengine/bevy/blob/latest/examples/2d/text2d.rs)
#[derive(Bundle, Clone, Debug, Default)]
pub struct Text2dBundle {
/// Contains the text.
pub text: Text,
/// How the text is positioned relative to its transform.
pub text_anchor: Anchor,
pub transform: Transform,
pub global_transform: GlobalTransform,
/// The maximum width and height of the text.
pub text_2d_bounds: Text2dBounds,
/// The transform of the text.
pub transform: Transform,
/// The global transform of the text.
pub global_transform: GlobalTransform,
/// The visbility properties of the text.
pub visibility: Visibility,
/// Algorithmically-computed indication of whether an entity is visible and should be extracted for rendering.
pub computed_visibility: ComputedVisibility,
}