Skip to content

Commit c3ff6d4

Browse files
Fix non-crate typos (#18219)
# Objective Correct spelling ## Solution Fix typos, specifically ones that I found in folders other than /crates ## Testing CI --------- Co-authored-by: Alice Cecile <[email protected]>
1 parent f5210c5 commit c3ff6d4

File tree

15 files changed

+26
-26
lines changed

15 files changed

+26
-26
lines changed

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1835,7 +1835,7 @@ path = "examples/asset/multi_asset_sync.rs"
18351835
doc-scrape-examples = true
18361836

18371837
[package.metadata.example.multi_asset_sync]
1838-
name = "Mult-asset synchronization"
1838+
name = "Multi-asset synchronization"
18391839
description = "Demonstrates how to wait for multiple assets to be loaded."
18401840
category = "Assets"
18411841
wasm = true

assets/shaders/specialized_mesh_pipeline.wgsl

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
//! between the vertex and fragment shader. Also shows the custom vertex layout.
33

44
// First we import everything we need from bevy_pbr
5-
// A 2d shader would be vevry similar but import from bevy_sprite instead
5+
// A 2D shader would be very similar but import from bevy_sprite instead
66
#import bevy_pbr::{
77
mesh_functions,
88
view_transformations::position_world_to_clip
@@ -45,4 +45,4 @@ fn vertex(vertex: Vertex) -> VertexOutput {
4545
fn fragment(in: VertexOutput) -> @location(0) vec4<f32> {
4646
// output the color directly
4747
return vec4(in.color, 1.0);
48-
}
48+
}

assets/shaders/tonemapping_test_patterns.wgsl

+4-4
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,19 @@
99
#import bevy_core_pipeline::tonemapping::tone_mapping
1010
#endif
1111

12-
// Sweep across hues on y axis with value from 0.0 to +15EV across x axis
12+
// Sweep across hues on y axis with value from 0.0 to +15EV across x axis
1313
// quantized into 24 steps for both axis.
1414
fn color_sweep(uv_input: vec2<f32>) -> vec3<f32> {
1515
var uv = uv_input;
1616
let steps = 24.0;
1717
uv.y = uv.y * (1.0 + 1.0 / steps);
1818
let ratio = 2.0;
19-
19+
2020
let h = PI * 2.0 * floor(1.0 + steps * uv.y) / steps;
2121
let L = floor(uv.x * steps * ratio) / (steps * ratio) - 0.5;
22-
22+
2323
var color = vec3(0.0);
24-
if uv.y < 1.0 {
24+
if uv.y < 1.0 {
2525
color = cos(h + vec3(0.0, 1.0, 2.0) * PI * 2.0 / 3.0);
2626
let maxRGB = max(color.r, max(color.g, color.b));
2727
let minRGB = min(color.r, min(color.g, color.b));

benches/benches/bevy_ecs/scheduling/schedule.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ pub fn build_schedule(criterion: &mut Criterion) {
7979
// Benchmark graphs of different sizes.
8080
for graph_size in [100, 500, 1000] {
8181
// Basic benchmark without constraints.
82-
group.bench_function(format!("{graph_size}_schedule_noconstraints"), |bencher| {
82+
group.bench_function(format!("{graph_size}_schedule_no_constraints"), |bencher| {
8383
bencher.iter(|| {
8484
let mut app = App::new();
8585
for _ in 0..graph_size {

examples/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ Example | Description
251251
[Embedded Asset](../examples/asset/embedded_asset.rs) | Embed an asset in the application binary and load it
252252
[Extra asset source](../examples/asset/extra_source.rs) | Load an asset from a non-standard asset source
253253
[Hot Reloading of Assets](../examples/asset/hot_asset_reloading.rs) | Demonstrates automatic reloading of assets when modified on disk
254-
[Mult-asset synchronization](../examples/asset/multi_asset_sync.rs) | Demonstrates how to wait for multiple assets to be loaded.
254+
[Multi-asset synchronization](../examples/asset/multi_asset_sync.rs) | Demonstrates how to wait for multiple assets to be loaded.
255255
[Repeated texture configuration](../examples/asset/repeated_texture.rs) | How to configure the texture to repeat instead of the default clamp to edges
256256

257257
## Async Tasks

examples/games/alien_cake_addict.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ fn main() {
4242
.add_systems(OnEnter(GameState::GameOver), display_score)
4343
.add_systems(
4444
Update,
45-
gameover_keyboard.run_if(in_state(GameState::GameOver)),
45+
game_over_keyboard.run_if(in_state(GameState::GameOver)),
4646
)
4747
.run();
4848
}
@@ -378,7 +378,7 @@ fn scoreboard_system(game: Res<Game>, mut display: Single<&mut Text>) {
378378
}
379379

380380
// restart the game when pressing spacebar
381-
fn gameover_keyboard(
381+
fn game_over_keyboard(
382382
mut next_state: ResMut<NextState<GameState>>,
383383
keyboard_input: Res<ButtonInput<KeyCode>>,
384384
) {

examples/games/stepping.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ impl Plugin for SteppingPlugin {
7272
/// Struct for maintaining stepping state
7373
#[derive(Resource, Debug)]
7474
struct State {
75-
// vector of schedule/nodeid -> text index offset
75+
// vector of schedule/node id -> text index offset
7676
systems: Vec<(InternedScheduleLabel, NodeId, usize)>,
7777

7878
// ui positioning

examples/math/custom_primitives.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ fn setup(
121121

122122
// Spawn the 2D heart
123123
commands.spawn((
124-
// We can use the methods defined on the meshbuilder to customize the mesh.
124+
// We can use the methods defined on the `MeshBuilder` to customize the mesh.
125125
Mesh3d(meshes.add(HEART.mesh().resolution(50))),
126126
MeshMaterial3d(materials.add(StandardMaterial {
127127
emissive: RED.into(),
@@ -134,7 +134,7 @@ fn setup(
134134

135135
// Spawn an extrusion of the heart.
136136
commands.spawn((
137-
// We can set a custom resolution for the round parts of the extrusion aswell.
137+
// We can set a custom resolution for the round parts of the extrusion as well.
138138
Mesh3d(meshes.add(EXTRUSION.mesh().resolution(50))),
139139
MeshMaterial3d(materials.add(StandardMaterial {
140140
base_color: RED.into(),
@@ -358,7 +358,7 @@ impl BoundedExtrusion for Heart {}
358358

359359
// You can use the `Meshable` trait to create a `MeshBuilder` for the primitive.
360360
impl Meshable for Heart {
361-
// The meshbuilder can be used to create the actual mesh for that primitive.
361+
// The `MeshBuilder` can be used to create the actual mesh for that primitive.
362362
type Output = HeartMeshBuilder;
363363

364364
fn mesh(&self) -> Self::Output {
@@ -369,15 +369,15 @@ impl Meshable for Heart {
369369
}
370370
}
371371

372-
// You can include any additional information needed for meshing the primitive in the meshbuilder.
372+
// You can include any additional information needed for meshing the primitive in the `MeshBuilder`.
373373
struct HeartMeshBuilder {
374374
heart: Heart,
375375
// The resolution determines the amount of vertices used for each wing of the heart
376376
resolution: usize,
377377
}
378378

379379
// This trait is needed so that the configuration methods of the builder of the primitive are also available for the builder for the extrusion.
380-
// If you do not want to support these configuration options for extrusions you can just implement them for your 2D mesh builder.
380+
// If you do not want to support these configuration options for extrusions you can just implement them for your 2D `MeshBuilder`.
381381
trait HeartBuilder {
382382
/// Set the resolution for each of the wings of the heart.
383383
fn resolution(self, resolution: usize) -> Self;

examples/ui/scroll.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ fn setup(mut commands: Commands, asset_server: Res<AssetServer>) {
4747
.with_children(|parent| {
4848
// header
4949
parent.spawn((
50-
Text::new("Horizontally Scrolling list (Ctrl + Mousewheel)"),
50+
Text::new("Horizontally Scrolling list (Ctrl + MouseWheel)"),
5151
TextFont {
5252
font: asset_server.load("fonts/FiraSans-Bold.ttf"),
5353
font_size: FONT_SIZE,

examples/ui/text_debug.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ fn infotext_system(mut commands: Commands, asset_server: Res<AssetServer>) {
175175
},
176176
));
177177
p.spawn((
178-
TextSpan::new(" this text has zero fontsize"),
178+
TextSpan::new(" this text has zero font size"),
179179
TextFont {
180180
font: font.clone(),
181181
font_size: 0.0,
@@ -229,7 +229,7 @@ fn infotext_system(mut commands: Commands, asset_server: Res<AssetServer>) {
229229
TextColor(BLUE.into()),
230230
));
231231
p.spawn((
232-
TextSpan::new(" this text has negative fontsize"),
232+
TextSpan::new(" this text has negative font size"),
233233
TextFont {
234234
font: font.clone(),
235235
font_size: -42.0,

examples/ui/viewport_debug.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
//! A simple example for debugging viewport coordinates
22
//!
3-
//! This example creates two uinode trees, one using viewport coordinates and one using pixel coordinates,
3+
//! This example creates two UI node trees, one using viewport coordinates and one using pixel coordinates,
44
//! and then switches between them once per second using the `Display` style property.
5-
//! If there are no problems both layouts should be identical, except for the color of the margin changing which is used to signal that the displayed uinode tree has changed
5+
//! If there are no problems both layouts should be identical, except for the color of the margin changing which is used to signal that the displayed UI node tree has changed
66
//! (red for viewport, yellow for pixel).
77
use bevy::{color::palettes::css::*, prelude::*};
88

examples/ui/window_fallthrough.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ fn setup(mut commands: Commands, asset_server: Res<AssetServer>) {
4343
},
4444
));
4545
}
46-
// A simple system to handle some keyboard input and toggle on/off the hittest.
46+
// A simple system to handle some keyboard input and toggle on/off the hit test.
4747
fn toggle_mouse_passthrough(
4848
keyboard_input: Res<ButtonInput<KeyCode>>,
4949
mut window: Single<&mut Window>,

examples/window/low_power.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ fn update_winit(
9494
// Sending a `WakeUp` event is useful when you want the app to update the next
9595
// frame regardless of any user input. This can be used from outside Bevy, see example
9696
// `window/custom_user_event.rs` for an example usage from outside.
97-
// Note that in this example the Wakeup winit event will make the app run in the same
97+
// Note that in this example the `WakeUp` winit event will make the app run in the same
9898
// way as continuous
9999
let _ = event_loop_proxy.send_event(WakeUp);
100100
WinitSettings::desktop_app()

tests/window/change_window_mode.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ fn toggle_window_mode(mut qry_window: Query<&mut Window>) {
4747

4848
window.mode = match window.mode {
4949
WindowMode::Windowed => {
50-
//it takes a while for the window to change from windowed to fullscreen and back
50+
// it takes a while for the window to change from `Windowed` to `Fullscreen` and back
5151
std::thread::sleep(std::time::Duration::from_secs(4));
5252
WindowMode::Fullscreen(
5353
MonitorSelection::Entity(entity),

tools/compile_fail_utils/tests/example.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
fn main() -> compile_fail_utils::ui_test::Result<()> {
22
// Run all tests in the tests/example_tests folder.
33
// If we had more tests we could either call this function
4-
// on everysingle one or use test_multiple and past it an array
4+
// on every single one or use test_multiple and past it an array
55
// of paths.
66
//
77
// Don't forget that when running tests the working directory

0 commit comments

Comments
 (0)