diff --git a/Cargo.lock b/Cargo.lock index b56c157..518c720 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -310,12 +310,13 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "image" -version = "0.25.5" +version = "0.25.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd6f44aed642f18953a158afeb30206f4d50da59fbc66ecb53c66488de73563b" +checksum = "529feb3e6769d234375c4cf1ee2ce713682b8e76538cb13f9fc23e1400a591e7" dependencies = [ "bytemuck", "byteorder-lite", + "moxcms", "num-traits", ] @@ -379,6 +380,16 @@ dependencies = [ "autocfg", ] +[[package]] +name = "moxcms" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddd32fa8935aeadb8a8a6b6b351e40225570a37c43de67690383d87ef170cd08" +dependencies = [ + "num-traits", + "pxfm", +] + [[package]] name = "num-traits" version = "0.2.19" @@ -432,6 +443,15 @@ dependencies = [ "unicode-ident", ] +[[package]] +name = "pxfm" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f55f4fedc84ed39cb7a489322318976425e42a147e2be79d8f878e2884f94e84" +dependencies = [ + "num-traits", +] + [[package]] name = "quote" version = "1.0.38" diff --git a/src/common/platform_api.rs b/src/common/platform_api.rs index 006822a..ce7dea8 100644 --- a/src/common/platform_api.rs +++ b/src/common/platform_api.rs @@ -3,7 +3,7 @@ use crate::{ImageOnHeap, Result, WindowId, WindowList}; pub trait PlatformApi: Send { /// 1. it does check for the screenshot /// 2. it checks for transparent margins and configures the api - /// to cut them away in further screenshots + /// to cut them away in further screenshots fn calibrate(&mut self, window_id: WindowId) -> Result<()>; fn window_list(&self) -> Result; fn capture_window_screenshot(&self, window_id: WindowId) -> Result; diff --git a/src/linux/x11_api.rs b/src/linux/x11_api.rs index d8f1df9..5ae4634 100644 --- a/src/linux/x11_api.rs +++ b/src/linux/x11_api.rs @@ -128,7 +128,7 @@ impl X11Api { impl PlatformApi for X11Api { /// 1. error if no screenshot is capture-able /// 2. it checks for transparent margins and configures the api - /// to cut them away in further screenshots + /// to cut them away in further screenshots fn calibrate(&mut self, window_id: WindowId) -> Result<()> { let image = self.capture_window_screenshot(window_id)?; self.margin = identify_transparency(*image)?;