fix(): fix button text

This commit is contained in:
gbrochar 2023-05-18 11:57:38 +02:00
parent 8f5281e5f2
commit ade1a59cf2
3 changed files with 5 additions and 3 deletions

2
.gitignore vendored
View File

@ -1,5 +1,5 @@
# Assets and songs
assets
assets/textures
songs
# ---> Rust

Binary file not shown.

View File

@ -1,6 +1,7 @@
use bevy::{
prelude::*,
window::PresentMode,
winit::WinitSettings,
};
#[derive(Component)]
@ -30,13 +31,14 @@ fn main() {
resolution:(640., 480.).into(),
present_mode: PresentMode::AutoVsync,
// Tells wasm to resize the window according to the available canvas
fit_canvas_to_parent: true,
fit_canvas_to_parent: false,
// Tells wasm not to override default event handling, like F5, Ctrl+R etc.
prevent_default_event_handling: false,
..default()
}),
..default()}))
.add_plugin(HelloPlugin)
.insert_resource(WinitSettings::desktop_app())
.add_startup_system(setup)
.add_system(button_system)
.run();
@ -126,7 +128,7 @@ fn setup(mut commands: Commands, asset_server: Res<AssetServer>) {
parent.spawn(TextBundle::from_section(
"Button",
TextStyle {
font: asset_server.load("fonts/FiraSans-Bold.ttf"),
font: asset_server.load("fonts/LinLibertine_Rah.ttf"),
font_size: 40.0,
color: Color::rgb(0.9, 0.9, 0.9),
},