Skip to content

Commit

Permalink
Merge pull request #225 from Nazariglez/develop
Browse files Browse the repository at this point in the history
v0.9.2
  • Loading branch information
Nazariglez authored Feb 5, 2023
2 parents 0aeb06e + e242f93 commit 2b29023
Show file tree
Hide file tree
Showing 68 changed files with 711 additions and 274 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
# Changelog
All notable changes to this project will be documented in this file.

## v0.9.2 - 05/02/2023

- Added `Fn` keys to `egui`.
- New example `game_tic_tac_toe.rs`.
- Fix corners of shapes using the Draw2D API.
- New example `draw_text_max_width.rs`.
- Fix window's transparency issue on x11 linux.
- Fix an issue with some windows to select the OpenGL context.

## v0.9.1 - 26/01/2023

- Fix docs compilation.

## v0.9.0 - 24/01/2023

- Fix alpha blending mode issue with text rendering using the Draw2D API.
Expand Down
42 changes: 21 additions & 21 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

36 changes: 18 additions & 18 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
categories = ["graphics", "rendering", "wasm", "gui", "multimedia"]
Expand All @@ -13,28 +13,28 @@ license = "MIT OR Apache-2.0"
description = "A simple portable multimedia layer to create apps or games easily"

[package.metadata.docs.rs]
features = ["default", "glyph", "egui", "text", "extra", "audio", "links", "drop_files", "clipboard", "save_file", "texture_to_file", ]
features = ["default", "glyph", "egui", "text", "extra", "audio", "links", "drop_files", "clipboard", "save_file", "texture_to_file"]

[profile.release]
lto = true

[dependencies]
notan_core = { path = "crates/notan_core", version = "0.9.1" }
notan_input = { path = "crates/notan_input", version = "0.9.1" }
notan_app = { path = "crates/notan_app", version = "0.9.1" }
notan_macro = { path = "crates/notan_macro", version = "0.9.1" }
notan_math = { path = "crates/notan_math", version = "0.9.1" }
notan_graphics = { path = "crates/notan_graphics", version = "0.9.1" }
notan_utils = { path = "crates/notan_utils", version = "0.9.1" }
notan_log = { path = "crates/notan_log", version = "0.9.1", optional = true }
notan_glyph = { path = "crates/notan_glyph", version = "0.9.1", optional = true }
notan_draw = { path = "crates/notan_draw", version = "0.9.1", optional = true }
notan_backend = { path = "crates/notan_backend", version = "0.9.1", optional = true }
notan_egui = { path = "crates/notan_egui", version = "0.9.1", optional = true }
notan_text = { path = "crates/notan_text", version = "0.9.1", optional = true }
notan_audio = { path = "crates/notan_audio", version = "0.9.1", optional = true }
notan_extra = { path = "crates/notan_extra", version = "0.9.1", optional = true }
notan_random = { path = "crates/notan_random", version = "0.9.1", optional = true }
notan_core = { path = "crates/notan_core", version = "0.9.2" }
notan_input = { path = "crates/notan_input", version = "0.9.2" }
notan_app = { path = "crates/notan_app", version = "0.9.2" }
notan_macro = { path = "crates/notan_macro", version = "0.9.2" }
notan_math = { path = "crates/notan_math", version = "0.9.2" }
notan_graphics = { path = "crates/notan_graphics", version = "0.9.2" }
notan_utils = { path = "crates/notan_utils", version = "0.9.2" }
notan_log = { path = "crates/notan_log", version = "0.9.2", optional = true }
notan_glyph = { path = "crates/notan_glyph", version = "0.9.2", optional = true }
notan_draw = { path = "crates/notan_draw", version = "0.9.2", optional = true }
notan_backend = { path = "crates/notan_backend", version = "0.9.2", optional = true }
notan_egui = { path = "crates/notan_egui", version = "0.9.2", optional = true }
notan_text = { path = "crates/notan_text", version = "0.9.2", optional = true }
notan_audio = { path = "crates/notan_audio", version = "0.9.2", optional = true }
notan_extra = { path = "crates/notan_extra", version = "0.9.2", optional = true }
notan_random = { path = "crates/notan_random", version = "0.9.2", optional = true }

[workspace]
members = ["crates/*"]
Expand Down
16 changes: 8 additions & 8 deletions crates/notan_app/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan_app"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand All @@ -14,13 +14,13 @@ description = "Provides the core API for Notan"
[dependencies]
log = "0.4.17"
hashbrown = "0.13.2"
notan_core = { path = "../notan_core", version = "0.9.1" }
notan_input = { path = "../notan_input", version = "0.9.1" }
notan_math = { path = "../notan_math", version = "0.9.1" }
notan_macro = { path = "../notan_macro", version = "0.9.1" }
notan_graphics = { path = "../notan_graphics", version = "0.9.1" }
notan_utils = { path = "../notan_utils", version = "0.9.1" }
notan_audio = { path = "../notan_audio", version = "0.9.1", optional = true }
notan_core = { path = "../notan_core", version = "0.9.2" }
notan_input = { path = "../notan_input", version = "0.9.2" }
notan_math = { path = "../notan_math", version = "0.9.2" }
notan_macro = { path = "../notan_macro", version = "0.9.2" }
notan_graphics = { path = "../notan_graphics", version = "0.9.2" }
notan_utils = { path = "../notan_utils", version = "0.9.2" }
notan_audio = { path = "../notan_audio", version = "0.9.2", optional = true }
downcast-rs = "1.2.0"
indexmap = "1.9.2"
futures = "0.3.25"
Expand Down
3 changes: 1 addition & 2 deletions crates/notan_app/src/assets/asset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ where
Arc::try_unwrap(self.inner)
.map_err(|_| {
format!(
"Asset: '{}' cannot be unwrapped because exists more than one reference to it.",
id
"Asset: '{id}' cannot be unwrapped because exists more than one reference to it.",
)
})
.map(|asset_lock| asset_lock.into_inner().unwrap())
Expand Down
7 changes: 3 additions & 4 deletions crates/notan_app/src/assets/storage.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ impl AssetStorage {
let fut = Box::pin(
wasm_bindgen_futures::JsFuture::from(f.array_buffer()).map(|res| match res {
Ok(buffer) => Ok(js_sys::Uint8Array::new(&buffer).to_vec()),
Err(e) => Err(format!("{:?}", e)),
Err(e) => Err(format!("{e:?}")),
}),
);

Expand Down Expand Up @@ -113,12 +113,11 @@ impl AssetStorage {
let tracker = self
.to_load
.remove(id)
.ok_or_else(|| format!("Asset '{}' not found.", id))?;
.ok_or_else(|| format!("Asset '{id}' not found."))?;

if !tracker.is_loaded() {
return Err(format!(
"The loader of '{}' should call 'storage.parse({}, asset)' before it ends.",
id, id
"The loader of '{id}' should call 'storage.parse({id}, asset)' before it ends.",
));
}

Expand Down
3 changes: 1 addition & 2 deletions crates/notan_app/src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,7 @@ where
let _ = plugins.init(&mut app, &mut assets, &mut graphics).map(|flow| match flow {
AppFlow::Next => Ok(()),
_ => Err(format!(
"Aborted application loop because a plugin returns on the init method AppFlow::{:?} instead of AppFlow::Next",
flow
"Aborted application loop because a plugin returns on the init method AppFlow::{flow:?} instead of AppFlow::Next",
)),
})?;

Expand Down
2 changes: 1 addition & 1 deletion crates/notan_audio/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan_audio"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand Down
6 changes: 3 additions & 3 deletions crates/notan_backend/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan_backend"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand All @@ -12,10 +12,10 @@ description = "Provides a default backend for Notan"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[target.'cfg(target_arch = "wasm32")'.dependencies]
notan_web = { path = "../notan_web", version = "0.9.1" }
notan_web = { path = "../notan_web", version = "0.9.2" }

[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
notan_winit = { path = "../notan_winit", version = "0.9.1" }
notan_winit = { path = "../notan_winit", version = "0.9.2" }

[features]
audio = ["notan_web/audio", "notan_winit/audio"]
Expand Down
2 changes: 1 addition & 1 deletion crates/notan_core/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan_core"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand Down
14 changes: 7 additions & 7 deletions crates/notan_draw/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "notan_draw"
version = "0.9.1"
version = "0.9.2"
authors = ["Nazarí González <nazari.nz@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand All @@ -13,12 +13,12 @@ description = "Provides a simple 2D API for Notan"

[dependencies]
log = "0.4.17"
notan_app = { path = "../notan_app", version = "0.9.1" }
notan_graphics = { path = "../notan_graphics", version = "0.9.1" }
notan_macro = { path = "../notan_macro", version = "0.9.1" }
notan_math = { path = "../notan_math", version = "0.9.1" }
notan_glyph = { path = "../notan_glyph", version = "0.9.1" }
notan_text = { path = "../notan_text", version = "0.9.1" }
notan_app = { path = "../notan_app", version = "0.9.2" }
notan_graphics = { path = "../notan_graphics", version = "0.9.2" }
notan_macro = { path = "../notan_macro", version = "0.9.2" }
notan_math = { path = "../notan_math", version = "0.9.2" }
notan_glyph = { path = "../notan_glyph", version = "0.9.2" }
notan_text = { path = "../notan_text", version = "0.9.2" }
lyon = "1.0.1"
serde = { version = "1.0.152", features = ["derive"] }
serde_json = "1.0.91"
Loading

0 comments on commit 2b29023

Please sign in to comment.