Crates.io | bevy_child_window |
lib.rs | bevy_child_window |
version | |
source | src |
created_at | 2025-02-06 16:28:31.411759+00 |
updated_at | 2025-03-01 04:00:29.046033+00 |
description | Allows you to create an embed child window in Bevy |
homepage | |
repository | https://github.com/not-elm/bevy_child_window |
max_upload_size | |
id | 1545828 |
Cargo.toml error: | TOML parse error at line 18, column 1 | 18 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include` |
size | 0 |
This library provides a way to create an embed child window in Bevy.
This is a library for
bevy_webview_wry
, but
can be used in generic bevy applications.
Platform | usable |
---|---|
Windows | ✅ |
MacOS | ✅ |
Linux(X11) | ❌ |
Linux(Wayland) | ❌ |
Web | ❌ |
Android | ❌ |
iOS | ❌ |
You can create the window as child by adding ParentWindow
component to the entity.
use bevy::prelude::*;
use bevy::window::{PrimaryWindow, WindowResolution};
use bevy_child_window::prelude::*;
fn main() {
App::new()
.add_plugins((
DefaultPlugins,
ChildWindowPlugin,
))
.add_systems(Startup, spawn_child_window)
.run();
}
fn spawn_child_window(
mut commands: Commands,
parent: Query<Entity, With<PrimaryWindow>>,
) {
commands.spawn((
ParentWindow(parent.single()),
Window {
title: "Child Window".to_string(),
resolution: WindowResolution::new(500.0, 500.0),
..Default::default()
}
));
}
Please see here.
bevy_child_window | bevy |
---|---|
0.1.0 ~ | 0.15 |
This crate is licensed under the MIT License or the Apache License 2.0.
Welcome to contribute by PR and issues!