From fdcc30236721f2cf7bdffe788127a35ca376d453 Mon Sep 17 00:00:00 2001 From: edouardparis Date: Fri, 29 Mar 2024 15:27:05 +0100 Subject: [PATCH] gui: iced-0.12 --- gui/Cargo.lock | 1521 ++++++++++++++++---------- gui/Cargo.toml | 10 +- gui/src/app/state/receive.rs | 4 +- gui/src/app/view/coins.rs | 1 - gui/src/app/view/home.rs | 1 - gui/src/app/view/mod.rs | 1 - gui/src/app/view/psbt.rs | 5 +- gui/src/app/view/psbts.rs | 1 - gui/src/app/view/receive.rs | 5 +- gui/src/app/view/recovery.rs | 10 +- gui/src/app/view/settings.rs | 1 - gui/src/app/view/spend/mod.rs | 14 +- gui/src/app/view/transactions.rs | 1 - gui/src/installer/view.rs | 31 +- gui/src/launcher.rs | 1 - gui/src/loader.rs | 1 - gui/src/main.rs | 25 +- gui/ui/Cargo.toml | 2 +- gui/ui/src/component/amount.rs | 2 +- gui/ui/src/component/card.rs | 2 +- gui/ui/src/component/collapse.rs | 41 +- gui/ui/src/component/event.rs | 9 +- gui/ui/src/component/form.rs | 4 +- gui/ui/src/component/hw.rs | 2 +- gui/ui/src/component/modal.rs | 103 +- gui/ui/src/component/notification.rs | 1 - gui/ui/src/component/text.rs | 50 +- gui/ui/src/component/toast.rs | 89 +- gui/ui/src/font.rs | 4 +- gui/ui/src/lib.rs | 28 +- gui/ui/src/theme.rs | 385 ++++--- gui/ui/src/util.rs | 25 - 32 files changed, 1410 insertions(+), 970 deletions(-) delete mode 100644 gui/ui/src/util.rs diff --git a/gui/Cargo.lock b/gui/Cargo.lock index 141cde7f..88652c99 100644 --- a/gui/Cargo.lock +++ b/gui/Cargo.lock @@ -91,9 +91,9 @@ dependencies = [ [[package]] name = "ahash" -version = "0.7.6" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" +checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9" dependencies = [ "getrandom", "once_cell", @@ -107,6 +107,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", + "getrandom", "once_cell", "version_check", "zerocopy", @@ -135,20 +136,23 @@ checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" [[package]] name = "android-activity" -version = "0.4.3" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64529721f27c2314ced0890ce45e469574a73e5e6fdd6e9da1860eb29285f5e0" +checksum = "ee91c0c2905bae44f84bfa4e044536541df26b7703fd0888deeb9060fcc44289" dependencies = [ "android-properties", - "bitflags 1.3.2", + "bitflags 2.4.2", "cc", + "cesu8", + "jni", "jni-sys", "libc", "log", "ndk", "ndk-context", "ndk-sys", - "num_enum 0.6.1", + "num_enum", + "thiserror", ] [[package]] @@ -194,10 +198,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] -name = "ash" -version = "0.37.2+1.3.238" +name = "as-raw-xcb-connection" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28bf19c1f0a470be5fbf7522a308a05df06610252c5bcf5143e1b23f629a9a03" +checksum = "175571dd1d178ced59193a6fc02dde1b972eb0bc56c892cde9beeceac5bf0f6b" + +[[package]] +name = "ash" +version = "0.37.3+1.3.251" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39e9c3835d686b0a6084ab4234fcd1b07dbf6e4767dce60874b12356a25ecd4a" dependencies = [ "libloading 0.7.4", ] @@ -231,9 +241,15 @@ checksum = "b9ccdd8f2a161be9bd5c023df56f1b2a0bd1d83872ae53b71a84a12c9bf6e842" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + [[package]] name = "autocfg" version = "1.1.0" @@ -467,21 +483,21 @@ dependencies = [ [[package]] name = "block-sys" -version = "0.1.0-beta.1" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa55741ee90902547802152aaf3f8e5248aab7e21468089560d4c8840561146" +checksum = "ae85a0696e7ea3b835a453750bf002770776609115e6d25c6d2ff28a8200f7e7" dependencies = [ "objc-sys", ] [[package]] name = "block2" -version = "0.2.0-alpha.6" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8dd9e63c1744f755c2f60332b88de39d341e5e86239014ad839bd71c106dec42" +checksum = "15b55663a85f33501257357e6421bb33e769d5c9ffb5ba0921c975a123e35e68" dependencies = [ "block-sys", - "objc2-encode", + "objc2", ] [[package]] @@ -507,7 +523,7 @@ checksum = "fdde5c9cd29ebd706ce1b35600920a33550e402fc998a2e53ad3b42c3c47a192" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -545,15 +561,28 @@ dependencies = [ [[package]] name = "calloop" -version = "0.10.5" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a59225be45a478d772ce015d9743e49e92798ece9e34eda9a6aa2a6a7f40192" +checksum = "fba7adb4dd5aa98e5553510223000e7148f621165ec5f9acd7113f6ca4995298" dependencies = [ + "bitflags 2.4.2", "log", - "nix 0.25.1", - "slotmap", + "polling", + "rustix 0.38.34", + "slab", "thiserror", - "vec_map", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f0ea9b9476c7fad82841a8dbb380e2eae480c21910feba80725b46931ed8f02" +dependencies = [ + "calloop", + "rustix 0.38.34", + "wayland-backend", + "wayland-client", ] [[package]] @@ -565,6 +594,12 @@ dependencies = [ "jobserver", ] +[[package]] +name = "cesu8" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" + [[package]] name = "cfg-if" version = "1.0.0" @@ -577,6 +612,12 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" +[[package]] +name = "cfg_aliases" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77e53693616d3075149f4ead59bdeecd204ac6b8192d8969757601b74bddf00f" + [[package]] name = "chacha20" version = "0.9.1" @@ -601,12 +642,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "checked_int_cast" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17cc5e6b5ab06331c33589842070416baa137e8b0eb912b008cfd4a78ada7919" - [[package]] name = "chrono" version = "0.4.24" @@ -635,13 +670,11 @@ dependencies = [ [[package]] name = "clipboard-win" -version = "4.5.0" +version = "5.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7191c27c2357d9b7ef96baac1773290d4ca63b24205b82a3fd8a0637afcf0362" +checksum = "79f4473f5144e20d9aceaf2972478f06ddf687831eafeeb434fbaf0acc4144ad" dependencies = [ "error-code", - "str-buf", - "winapi", ] [[package]] @@ -657,35 +690,35 @@ dependencies = [ [[package]] name = "clipboard_wayland" -version = "0.2.0" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f6364a9f7a66f2ac1a1a098aa1c7f6b686f2496c6ac5e5c0d773445df912747" +checksum = "003f886bc4e2987729d10c1db3424e7f80809f3fc22dbc16c685738887cb37b8" dependencies = [ "smithay-clipboard", ] [[package]] name = "clipboard_x11" -version = "0.4.0" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "983a7010836ecd04dde2c6d27a0cb56ec5d21572177e782bdcb24a600124e921" +checksum = "4274ea815e013e0f9f04a2633423e14194e408a0576c943ce3d14ca56c50031c" dependencies = [ "thiserror", - "x11rb 0.9.0", + "x11rb", ] [[package]] name = "cocoa" -version = "0.24.1" +version = "0.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" +checksum = "f6140449f97a6e97f9511815c5632d84c8aacf8ac271ad77c559218161a1373c" dependencies = [ "bitflags 1.3.2", "block", "cocoa-foundation", "core-foundation", "core-graphics", - "foreign-types", + "foreign-types 0.5.0", "libc", "objc", ] @@ -700,7 +733,7 @@ dependencies = [ "block", "core-foundation", "core-graphics-types", - "foreign-types", + "foreign-types 0.3.2", "libc", "objc", ] @@ -737,10 +770,54 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" [[package]] -name = "com-rs" -version = "0.2.1" +name = "com" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf43edc576402991846b093a7ca18a3477e0ef9c588cde84964b5d3e43016642" +checksum = "7e17887fd17353b65b1b2ef1c526c83e26cd72e74f598a8dc1bee13a48f3d9f6" +dependencies = [ + "com_macros", +] + +[[package]] +name = "com_macros" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d375883580a668c7481ea6631fc1a8863e33cc335bf56bfad8d7e6d4b04b13a5" +dependencies = [ + "com_macros_support", + "proc-macro2", + "syn 1.0.109", +] + +[[package]] +name = "com_macros_support" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad899a1087a9296d5644792d7cb72b8e34c1bec8e7d4fbc002230169a6e8710c" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "combine" +version = "4.6.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba5a308b75df32fe02788e748662718f03fde005016435c444eea572398219fd" +dependencies = [ + "bytes", + "memchr", +] + +[[package]] +name = "concurrent-queue" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" +dependencies = [ + "crossbeam-utils", +] [[package]] name = "const-oid" @@ -772,9 +849,9 @@ dependencies = [ [[package]] name = "core-foundation" -version = "0.9.3" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" dependencies = [ "core-foundation-sys", "libc", @@ -782,32 +859,31 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.4" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" [[package]] name = "core-graphics" -version = "0.22.3" +version = "0.23.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" +checksum = "c07782be35f9e1140080c6b96f0d44b739e2278479f64e02fdab4e32dfd8b081" dependencies = [ "bitflags 1.3.2", "core-foundation", "core-graphics-types", - "foreign-types", + "foreign-types 0.5.0", "libc", ] [[package]] name = "core-graphics-types" -version = "0.1.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" +checksum = "45390e6114f68f718cc7a830514a96f903cccd70d02a8f6d9f643ac4ba45afaf" dependencies = [ "bitflags 1.3.2", "core-foundation", - "foreign-types", "libc", ] @@ -822,16 +898,17 @@ dependencies = [ [[package]] name = "cosmic-text" -version = "0.9.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0b68966c2543609f8d92f9d33ac3b719b2a67529b0c6c0b3e025637b477eef9" +checksum = "75acbfb314aeb4f5210d379af45ed1ec2c98c7f1790bf57b8a4c562ac0c51b71" dependencies = [ - "aliasable", "fontdb", "libm", "log", "rangemap", - "rustybuzz 0.8.0", + "rustc-hash", + "rustybuzz 0.11.0", + "self_cell", "swash", "sys-locale", "unicode-bidi", @@ -929,6 +1006,16 @@ dependencies = [ "typenum", ] +[[package]] +name = "ctor" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "edb49164822f3ee45b17acd4a208cfc1251410cf0cad9a833234c9890774dd9f" +dependencies = [ + "quote", + "syn 2.0.60", +] + [[package]] name = "ctr" version = "0.9.2" @@ -938,6 +1025,12 @@ dependencies = [ "cipher", ] +[[package]] +name = "cursor-icon" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96a6ac251f4a2aca6b3f91340350eab87ae57c3f127ffeb585e92bd336717991" + [[package]] name = "curve25519-dalek" version = "4.1.2" @@ -962,7 +1055,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -989,7 +1082,7 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -1006,25 +1099,25 @@ checksum = "2345488264226bf682893e25de0769f3360aac9957980ec49361b083ddaa5bc5" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] name = "d3d12" -version = "0.6.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8f0de2f5a8e7bd4a9eec0e3c781992a4ce1724f68aec7d7a3715344de8b39da" +checksum = "3e3d747f100290a1ca24b752186f61f6637e1deffe3bf6320de6fcb29510a307" dependencies = [ - "bitflags 1.3.2", - "libloading 0.7.4", + "bitflags 2.4.2", + "libloading 0.8.1", "winapi", ] [[package]] name = "data-url" -version = "0.2.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d7439c3735f405729d52c3fbbe4de140eaf938a1fe47d227c27f8254d4302a5" +checksum = "5c297a1c74b71ae29df00c3e22dd9534821d60eb9af5a0192823fa2acea70c2a" [[package]] name = "der" @@ -1096,11 +1189,11 @@ checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" [[package]] name = "dlib" -version = "0.5.0" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac1b7517328c04c2aa68422fc60a41b92208182142ed04a25879c26c8f878794" +checksum = "330c60081dcc4c72131f8eb70510f1ac07223e5d4163db481a04a0befcffa412" dependencies = [ - "libloading 0.7.4", + "libloading 0.8.1", ] [[package]] @@ -1124,6 +1217,45 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" +[[package]] +name = "drm" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0f8a69e60d75ae7dab4ef26a59ca99f2a89d4c142089b537775ae0c198bdcde" +dependencies = [ + "bitflags 2.4.2", + "bytemuck", + "drm-ffi", + "drm-fourcc", + "rustix 0.38.34", +] + +[[package]] +name = "drm-ffi" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41334f8405792483e32ad05fbb9c5680ff4e84491883d2947a4757dc54cb2ac6" +dependencies = [ + "drm-sys", + "rustix 0.38.34", +] + +[[package]] +name = "drm-fourcc" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0aafbcdb8afc29c1a7ee5fbe53b5d62f4565b35a042a662ca9fecd0b54dae6f4" + +[[package]] +name = "drm-sys" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d09ff881f92f118b11105ba5e34ff8f4adf27b30dae8f12e28c193af1c83176" +dependencies = [ + "libc", + "linux-raw-sys 0.6.4", +] + [[package]] name = "ecdsa" version = "0.16.9" @@ -1180,34 +1312,19 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.3" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "136526188508e25c6fef639d7927dfb3e0e3084488bf202267829cf7fc23dbdd" +checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", "libc", + "windows-sys 0.52.0", ] [[package]] name = "error-code" -version = "2.3.1" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64f18991e7bf11e7ffee451b5318b5c1a73c52d0d0ada6e5a3017c8c1ced6a21" -dependencies = [ - "libc", - "str-buf", -] +checksum = "a0474425d51df81997e2f90a21591180b38eccf27292d755f3e30750225c175b" [[package]] name = "etagere" @@ -1271,6 +1388,12 @@ dependencies = [ "instant", ] +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + [[package]] name = "fern" version = "0.6.2" @@ -1375,13 +1498,13 @@ dependencies = [ [[package]] name = "fontdb" -version = "0.14.1" +version = "0.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af8d8cbea8f21307d7e84bca254772981296f058a1d36b461bf4d83a7499fc9e" +checksum = "020e203f177c0fb250fb19455a252e838d2bbbce1f80f25ecc42402aafa8cd38" dependencies = [ "fontconfig-parser", "log", - "memmap2 0.6.2", + "memmap2 0.8.0", "slotmap", "tinyvec", "ttf-parser 0.19.2", @@ -1393,7 +1516,28 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" dependencies = [ - "foreign-types-shared", + "foreign-types-shared 0.1.1", +] + +[[package]] +name = "foreign-types" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" +dependencies = [ + "foreign-types-macros", + "foreign-types-shared 0.3.1", +] + +[[package]] +name = "foreign-types-macros" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.60", ] [[package]] @@ -1402,6 +1546,12 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" +[[package]] +name = "foreign-types-shared" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" + [[package]] name = "form_urlencoded" version = "1.1.0" @@ -1468,7 +1618,7 @@ checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -1514,12 +1664,12 @@ dependencies = [ [[package]] name = "gethostname" -version = "0.2.3" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" +checksum = "0176e0459c2e4a1fe232f984bca6890e681076abb9934f6cea7c326f3fc47818" dependencies = [ "libc", - "winapi", + "windows-targets 0.48.0", ] [[package]] @@ -1562,16 +1712,27 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ad0a93d233ebf96623465aad4046a8d3aa4da22d4f4beba5388838c8a434bbb4" [[package]] -name = "glam" -version = "0.24.2" +name = "gl_generator" +version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5418c17512bdf42730f9032c74e1ae39afc408745ebb2acf72fbc4691c17945" +checksum = "1a95dfc23a2b4a9a2f5ab41d194f8bfda3cabec42af4e39f08c339eb2a0c124d" +dependencies = [ + "khronos_api", + "log", + "xml-rs", +] + +[[package]] +name = "glam" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151665d9be52f9bb40fc7966565d39666f2d1e69233571b71b87791c7e0528b3" [[package]] name = "glow" -version = "0.12.1" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e007a07a24de5ecae94160f141029e9a347282cfe25d1d58d85d845cf3130f1" +checksum = "bd348e04c43b32574f2de31c8bb397d96c9fcfa1371bd4ca6d8bdc464ab121b1" dependencies = [ "js-sys", "slotmap", @@ -1580,10 +1741,19 @@ dependencies = [ ] [[package]] -name = "glyphon" -version = "0.3.0" +name = "glutin_wgl_sys" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e87caa7459145f5e5f167bf34db4532901404c679e62339fb712a0e3ccf722a" +checksum = "6c8098adac955faa2d31079b65dc48841251f69efd3ac25477903fc424362ead" +dependencies = [ + "gl_generator", +] + +[[package]] +name = "glyphon" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a62d0338e4056db6a73221c2fb2e30619452f6ea9651bac4110f51b0f7a7581" dependencies = [ "cosmic-text", "etagere", @@ -1593,34 +1763,34 @@ dependencies = [ [[package]] name = "gpu-alloc" -version = "0.5.3" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fc59e5f710e310e76e6707f86c561dd646f69a8876da9131703b2f717de818d" +checksum = "fbcd2dba93594b227a1f57ee09b8b9da8892c34d55aa332e034a228d0fe6a171" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "gpu-alloc-types", ] [[package]] name = "gpu-alloc-types" -version = "0.2.0" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54804d0d6bc9d7f26db4eaec1ad10def69b599315f487d32c334a80d1efe67a5" +checksum = "98ff03b468aa837d70984d55f5d3f846f6ec31fe34bbb97c4f85219caeee1ca4" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", ] [[package]] name = "gpu-allocator" -version = "0.22.0" +version = "0.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce95f9e2e11c2c6fadfce42b5af60005db06576f231f5c92550fdded43c423e8" +checksum = "6f56f6318968d03c18e1bcf4857ff88c61157e9da8e47c5f29055d60e1228884" dependencies = [ - "backtrace", "log", + "presser", "thiserror", "winapi", - "windows 0.44.0", + "windows 0.52.0", ] [[package]] @@ -1698,7 +1868,7 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" dependencies = [ - "ahash 0.7.6", + "ahash 0.7.8", ] [[package]] @@ -1728,14 +1898,14 @@ dependencies = [ [[package]] name = "hassle-rs" -version = "0.10.0" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1397650ee315e8891a0df210707f0fc61771b0cc518c3023896064c5407cb3b0" +checksum = "af2a7e73e1f34c48da31fb668a907f250794837e08faa144fd24f0b8b741e890" dependencies = [ - "bitflags 1.3.2", - "com-rs", + "bitflags 2.4.2", + "com", "libc", - "libloading 0.7.4", + "libloading 0.8.1", "thiserror", "widestring", "winapi", @@ -1758,9 +1928,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.3.2" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -1909,9 +2079,9 @@ dependencies = [ [[package]] name = "iced" -version = "0.10.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c708807ec86f99dd729dc4d42db5239acf118cec14d3c5f57679dcfdbbc472b1" +checksum = "7d4eb0fbbefb8c428b70680e77ed9013887b17c1d6be366b40f264f956d1a096" dependencies = [ "iced_core", "iced_futures", @@ -1924,23 +2094,26 @@ dependencies = [ [[package]] name = "iced_core" -version = "0.10.0" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64d0bc4fbf018576d08d93f838e6058cc6f10bbc05e04ae249a2a44dffb4ebc8" +checksum = "7d7e6bbd197f311ed3d8b71651876b0ce01318fde52cda862a9a7a4373c9b930" dependencies = [ - "bitflags 1.3.2", - "instant", + "bitflags 2.4.2", + "glam", "log", + "num-traits", "palette", + "raw-window-handle", + "smol_str", "thiserror", - "twox-hash", + "web-time", + "xxhash-rust", ] [[package]] name = "iced_futures" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14dab0054a9c7a1cbce227a8cd9ee4a094497b3d06094551ac6c1488d563802e" +version = "0.12.3" +source = "git+https://github.com/edouardparis/iced?branch=patch-0.12.3#459c8eb3da2ae21461ee56baea8a1b10d38ff6e0" dependencies = [ "futures", "iced_core", @@ -1952,53 +2125,57 @@ dependencies = [ [[package]] name = "iced_graphics" -version = "0.9.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67ff14447a221e9e9205a13d84d7bbdf0636a3b1daa02cfca690ed09689c4d2b" +checksum = "6a044c193ef0840eacabfa05424717331d1fc5b3ecb9a89316200c75da2ba9a4" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "bytemuck", - "glam", + "cosmic-text", "half", "iced_core", + "iced_futures", "image", "kamadak-exif", "log", "lyon_path", + "once_cell", "raw-window-handle", + "rustc-hash", "thiserror", + "unicode-segmentation", + "xxhash-rust", ] [[package]] name = "iced_renderer" -version = "0.1.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1033385b0db0099a0d13178c9ff93c1ce11e7d0177522acf578bf79febdb2af8" +checksum = "5c281e03001d566058f53dec9325bbe61c62da715341206d2627f57a3ecc7f69" dependencies = [ "iced_graphics", "iced_tiny_skia", "iced_wgpu", "log", - "raw-window-handle", "thiserror", ] [[package]] name = "iced_runtime" -version = "0.1.1" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c6c89853e1250c6fac82c5015fa2144517be9b33d4b8e456f10e198b23e28bd" +checksum = "a79f852c01cc6d61663c94379cb3974ac3ad315a28c504e847d573e094f46822" dependencies = [ "iced_core", "iced_futures", + "raw-window-handle", "thiserror", ] [[package]] name = "iced_style" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d85c47d9d13e2281f75ddf98c865daf2101632bd2b855c401dd0b1c8b81a31a0" +version = "0.12.3" +source = "git+https://github.com/edouardparis/iced?branch=patch-0.12.3#459c8eb3da2ae21461ee56baea8a1b10d38ff6e0" dependencies = [ "iced_core", "once_cell", @@ -2007,30 +2184,29 @@ dependencies = [ [[package]] name = "iced_tiny_skia" -version = "0.1.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7715f6222c9470bbbd75a39f70478fa0d1bdfb81a377a34fd1b090ffccc480b" +checksum = "8c2228781f4d381a1cbbd7905a9f077351aa8d37269094021d5d9e779f130aff" dependencies = [ "bytemuck", "cosmic-text", "iced_graphics", - "kurbo", + "kurbo 0.10.4", "log", - "raw-window-handle", "resvg", "rustc-hash", "softbuffer", - "tiny-skia 0.10.0", - "twox-hash", + "tiny-skia", + "xxhash-rust", ] [[package]] name = "iced_wgpu" -version = "0.11.1" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "703f7c5de46b997ed7b18e05ec67059dcdf3beeac51e917c21071b021bb848b9" +checksum = "e3c243b6700452886aac1ee1987e84d9fb43b56b53fea9a1eb67713fd0fde244" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "bytemuck", "futures", "glam", @@ -2040,18 +2216,15 @@ dependencies = [ "log", "lyon", "once_cell", - "raw-window-handle", "resvg", - "rustc-hash", - "twox-hash", "wgpu", ] [[package]] name = "iced_widget" -version = "0.1.3" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a177219ae51c3ba08f228ab932354b360cc669e94aec50c01e7c9b675f074c7c" +checksum = "7e01b2212adecf1cb80e2267f302c0e0c263e55f97812056949199ccf9f0b908" dependencies = [ "iced_renderer", "iced_runtime", @@ -2065,22 +2238,32 @@ dependencies = [ [[package]] name = "iced_winit" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad0c884bcb14722a57192b40a5ef6b5e170fa2f01fe2ff28d6cdd9efe37acf70" +version = "0.12.3" +source = "git+https://github.com/edouardparis/iced?branch=patch-0.12.3#459c8eb3da2ae21461ee56baea8a1b10d38ff6e0" dependencies = [ "iced_graphics", "iced_runtime", "iced_style", "log", - "raw-window-handle", "thiserror", + "tracing", "web-sys", "winapi", "window_clipboard", "winit", ] +[[package]] +name = "icrate" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99d3aaff8a54577104bafdf686ff18565c3b6903ca5782a2026ef06e2c7aa319" +dependencies = [ + "block2", + "dispatch", + "objc2", +] + [[package]] name = "idna" version = "0.3.0" @@ -2152,9 +2335,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" dependencies = [ "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", ] [[package]] @@ -2163,7 +2343,7 @@ version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ - "hermit-abi 0.3.2", + "hermit-abi 0.3.9", "libc", "windows-sys 0.48.0", ] @@ -2183,12 +2363,37 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" +[[package]] +name = "jni" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a87aa2bb7d2af34197c04845522473242e1aa17c12f4935d5856491a7fb8c97" +dependencies = [ + "cesu8", + "cfg-if", + "combine", + "jni-sys", + "log", + "thiserror", + "walkdir", + "windows-sys 0.45.0", +] + [[package]] name = "jni-sys" version = "0.3.0" @@ -2215,9 +2420,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.64" +version = "0.3.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" dependencies = [ "wasm-bindgen", ] @@ -2271,15 +2476,21 @@ dependencies = [ [[package]] name = "khronos-egl" -version = "4.1.0" +version = "6.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c2352bd1d0bceb871cb9d40f24360c8133c11d7486b68b5381c1dd1a32015e3" +checksum = "6aae1df220ece3c0ada96b8153459b67eebe9ae9212258bb0134ae60416fdf76" dependencies = [ "libc", - "libloading 0.7.4", + "libloading 0.8.1", "pkg-config", ] +[[package]] +name = "khronos_api" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc" + [[package]] name = "kurbo" version = "0.9.4" @@ -2289,6 +2500,16 @@ dependencies = [ "arrayvec", ] +[[package]] +name = "kurbo" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1618d4ebd923e97d67e7cd363d80aef35fe961005cbbbb3d2dad8bdd1bc63440" +dependencies = [ + "arrayvec", + "smallvec", +] + [[package]] name = "lazy_static" version = "1.4.0" @@ -2412,9 +2633,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.141" +version = "0.2.154" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3304a64d199bb964be99741b7a14d26972741915b3649639149b2479bb46f4b5" +checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" [[package]] name = "libloading" @@ -2438,9 +2659,9 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.6" +version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "348108ab3fba42ec82ff6e9564fc4ca0247bdccdc68dd8af9764bbc79c3c8ffb" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libredox" @@ -2499,6 +2720,18 @@ version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" +[[package]] +name = "linux-raw-sys" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" + +[[package]] +name = "linux-raw-sys" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0b5399f6804fbab912acbd8878ed3532d506b7c951b8f9f164ef90fef39e3f4" + [[package]] name = "lock_api" version = "0.4.9" @@ -2511,18 +2744,15 @@ dependencies = [ [[package]] name = "log" -version = "0.4.17" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "lru" -version = "0.11.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a83fb7698b3643a0e34f9ae6f2e8f0178c0fd42f8b59d493aa271ff3a5bf21" +checksum = "d3262e75e648fce39813cb56ac41f3c3e3f65217ebf3844d818d1f9398cfb0dc" dependencies = [ "hashbrown 0.14.0", ] @@ -2614,31 +2844,22 @@ checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" [[package]] name = "memmap2" -version = "0.5.10" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83faa42c0a078c393f6b29d5db232d8be22776a891f8f56e5284faee4a20b327" +checksum = "43a5a03cefb0d953ec0be133036f14e109412fa594edc2f77227249db66cc3ed" dependencies = [ "libc", ] [[package]] name = "memmap2" -version = "0.6.2" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d28bba84adfe6646737845bc5ebbfa2c08424eb1c37e94a1fd2a82adb56a872" +checksum = "fe751422e4a8caa417e13c3ea66452215d7d63e19e604f4980461212f3ae1322" dependencies = [ "libc", ] -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - [[package]] name = "memoffset" version = "0.7.1" @@ -2659,16 +2880,17 @@ dependencies = [ [[package]] name = "metal" -version = "0.24.0" +version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de11355d1f6781482d027a3b4d4de7825dcedb197bf573e0596d00008402d060" +checksum = "c43f73953f8cbe511f021b58f18c3ce1c3d1ae13fe953293e13345bf83217f25" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "block", "core-graphics-types", - "foreign-types", + "foreign-types 0.5.0", "log", "objc", + "paste", ] [[package]] @@ -2754,15 +2976,15 @@ checksum = "16cf681a23b4d0a43fc35024c176437f9dcd818db34e0f42ab456a0ee5ad497b" [[package]] name = "naga" -version = "0.12.3" +version = "0.19.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbcc2e0513220fd2b598e6068608d4462db20322c0e77e47f6f488dfcfc279cb" +checksum = "50e3524642f53d9af419ab5e8dd29d3ba155708267667c2f3f06c88c9e130843" dependencies = [ "bit-set", - "bitflags 1.3.2", + "bitflags 2.4.2", "codespan-reporting", "hexf-parse", - "indexmap 1.9.3", + "indexmap 2.0.0", "log", "num-traits", "rustc-hash", @@ -2783,14 +3005,15 @@ dependencies = [ [[package]] name = "ndk" -version = "0.7.0" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "451422b7e4718271c8b5b3aadf5adedba43dc76312454b387e98fae0fc951aa0" +checksum = "2076a31b7010b17a38c01907c45b945e8f11495ee4dd588309718901b1f7a5b7" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "jni-sys", + "log", "ndk-sys", - "num_enum 0.5.11", + "num_enum", "raw-window-handle", "thiserror", ] @@ -2803,26 +3026,13 @@ checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" [[package]] name = "ndk-sys" -version = "0.4.1+23.1.7779620" +version = "0.5.0+25.2.9519653" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3cf2aae958bd232cac5069850591667ad422d263686d75b52a065f9badeee5a3" +checksum = "8c196769dd60fd4f363e11d948139556a344e79d451aeb2fa2fd040738ef7691" dependencies = [ "jni-sys", ] -[[package]] -name = "nix" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4916f159ed8e5de0082076562152a76b7a1f64a01fd9d1e0fea002c37624faf" -dependencies = [ - "bitflags 1.3.2", - "cc", - "cfg-if", - "libc", - "memoffset 0.6.5", -] - [[package]] name = "nix" version = "0.24.3" @@ -2832,20 +3042,6 @@ dependencies = [ "bitflags 1.3.2", "cfg-if", "libc", - "memoffset 0.6.5", -] - -[[package]] -name = "nix" -version = "0.25.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f346ff70e7dbfd675fe90590b92d59ef2de15a8779ae305ebcbfd3f0caf59be4" -dependencies = [ - "autocfg", - "bitflags 1.3.2", - "cfg-if", - "libc", - "memoffset 0.6.5", ] [[package]] @@ -2966,44 +3162,23 @@ dependencies = [ [[package]] name = "num_enum" -version = "0.5.11" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" +checksum = "02339744ee7253741199f897151b38e72257d13802d4ee837285cc2990a90845" dependencies = [ - "num_enum_derive 0.5.11", -] - -[[package]] -name = "num_enum" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a015b430d3c108a207fd776d2e2196aaf8b1cf8cf93253e3a097ff3085076a1" -dependencies = [ - "num_enum_derive 0.6.1", + "num_enum_derive", ] [[package]] name = "num_enum_derive" -version = "0.5.11" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" +checksum = "681030a937600a36906c185595136d26abfebb4aa9c65701cefcaf8578bb982b" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", -] - -[[package]] -name = "num_enum_derive" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -3029,29 +3204,25 @@ dependencies = [ [[package]] name = "objc-sys" -version = "0.2.0-beta.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df3b9834c1e95694a05a828b59f55fa2afec6288359cda67146126b3f90a55d7" +checksum = "da284c198fb9b7b0603f8635185e85fbd5b64ee154b1ed406d489077de2d6d60" [[package]] name = "objc2" -version = "0.3.0-beta.3.patch-leaks.3" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e01640f9f2cb1220bbe80325e179e532cb3379ebcd1bf2279d703c19fe3a468" +checksum = "559c5a40fdd30eb5e344fbceacf7595a81e242529fb4e21cf5f43fb4f11ff98d" dependencies = [ - "block2", "objc-sys", "objc2-encode", ] [[package]] name = "objc2-encode" -version = "2.0.0-pre.2" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abfcac41015b00a120608fdaa6938c44cb983fee294351cc4bac7638b4e50512" -dependencies = [ - "objc-sys", -] +checksum = "d079845b37af429bfe5dfa76e6d087d788031045b25cfc6fd898486fd9847666" [[package]] name = "objc_exception" @@ -3113,9 +3284,9 @@ dependencies = [ [[package]] name = "ouroboros" -version = "0.17.2" +version = "0.18.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2ba07320d39dfea882faa70554b4bd342a5f273ed59ba7c1c6b4c840492c954" +checksum = "97b7be5a8a3462b752f4be3ff2b2bf2f7f1d00834902e46be2a4d68b87b0573c" dependencies = [ "aliasable", "ouroboros_macro", @@ -3124,15 +3295,16 @@ dependencies = [ [[package]] name = "ouroboros_macro" -version = "0.17.2" +version = "0.18.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec4c6225c69b4ca778c0aea097321a64c421cf4577b331c61b229267edabb6f8" +checksum = "b645dcde5f119c2c454a92d0dfa271a2a3b205da92e4292a68ead4bdbfde1f33" dependencies = [ "heck", - "proc-macro-error", + "itertools 0.12.1", "proc-macro2", + "proc-macro2-diagnostics", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -3170,7 +3342,7 @@ checksum = "e05d1c929301fee6830dafa764341118829b2535c216b0571e3821ecac5c885b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -3221,6 +3393,12 @@ dependencies = [ "windows-sys 0.45.0", ] +[[package]] +name = "paste" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" + [[package]] name = "percent-encoding" version = "2.2.0" @@ -3351,6 +3529,21 @@ dependencies = [ "miniz_oxide", ] +[[package]] +name = "polling" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "645493cf344456ef24219d02a768cf1fb92ddf8c92161679ae3d91b91a637be3" +dependencies = [ + "cfg-if", + "concurrent-queue", + "hermit-abi 0.3.9", + "pin-project-lite", + "rustix 0.38.34", + "tracing", + "windows-sys 0.52.0", +] + [[package]] name = "poly1305" version = "0.8.0" @@ -3380,6 +3573,12 @@ version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +[[package]] +name = "presser" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8cf8e6a8aa66ce33f63993ffc4ea4271eb5b0530a9002db8455ea6050c77bfa" + [[package]] name = "prettyplease" version = "0.1.25" @@ -3400,30 +3599,6 @@ dependencies = [ "toml_edit", ] -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - [[package]] name = "proc-macro-hack" version = "0.5.20+deprecated" @@ -3432,13 +3607,26 @@ checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" [[package]] name = "proc-macro2" -version = "1.0.69" +version = "1.0.81" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" +checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" dependencies = [ "unicode-ident", ] +[[package]] +name = "proc-macro2-diagnostics" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.60", + "version_check", + "yansi", +] + [[package]] name = "profiling" version = "1.0.7" @@ -3473,7 +3661,7 @@ checksum = "119533552c9a7ffacc21e099c24a0ac8bb19c2a2a3f363de84cd9b844feab270" dependencies = [ "bytes", "heck", - "itertools", + "itertools 0.10.5", "lazy_static", "log", "multimap", @@ -3494,7 +3682,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4" dependencies = [ "anyhow", - "itertools", + "itertools 0.10.5", "proc-macro2", "quote", "syn 1.0.109", @@ -3507,10 +3695,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "065717a5dfaca4a83d2fe57db3487b311365200000551d7a364e715dbf4346bc" dependencies = [ "anyhow", - "itertools", + "itertools 0.10.5", "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -3533,27 +3721,24 @@ dependencies = [ [[package]] name = "qrcode" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16d2f1455f3630c6e5107b4f2b94e74d76dea80736de0981fd27644216cff57f" -dependencies = [ - "checked_int_cast", -] +checksum = "166f136dfdb199f98186f3649cf7a0536534a61417a1a30221b492b4fb60ce3f" [[package]] name = "quick-xml" -version = "0.28.2" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce5e73202a820a31f8a0ee32ada5e21029c81fd9e3ebf668a40832e4219d9d1" +checksum = "1004a344b30a54e2ee58d66a71b32d2db2feb0a31f9a2d302bf0536f15de2a33" dependencies = [ "memchr", ] [[package]] name = "quote" -version = "1.0.33" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -3602,9 +3787,9 @@ checksum = "795915a3930a5d6bafd9053d37602fea3e61be2e5d4d788983a8ba9654c1c6f2" [[package]] name = "raw-window-handle" -version = "0.5.2" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2ff9a1f06a88b01621b7ae906ef0211290d1c8a168a15542486a8f61c0833b9" +checksum = "8cc3bcbdb1ddfc11e700e62968e6b4cc9c75bb466464ad28fb61c5b2c964418b" [[package]] name = "rayon" @@ -3679,6 +3864,15 @@ dependencies = [ "bitflags 1.3.2", ] +[[package]] +name = "redox_syscall" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "469052894dcb553421e483e4209ee581a45100d31b4018de03e5a7ad86374a7e" +dependencies = [ + "bitflags 2.4.2", +] + [[package]] name = "redox_users" version = "0.4.3" @@ -3754,9 +3948,9 @@ dependencies = [ [[package]] name = "resvg" -version = "0.35.0" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6554f47c38eca56827eea7f285c2a3018b4e12e0e195cc105833c008be338f1" +checksum = "cc7980f653f9a7db31acff916a262c3b78c562919263edea29bf41a056e20497" dependencies = [ "gif", "jpeg-decoder", @@ -3765,7 +3959,7 @@ dependencies = [ "png", "rgb", "svgtypes", - "tiny-skia 0.10.0", + "tiny-skia", "usvg", ] @@ -3867,10 +4061,23 @@ dependencies = [ "errno", "io-lifetimes", "libc", - "linux-raw-sys", + "linux-raw-sys 0.3.8", "windows-sys 0.48.0", ] +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.4.2", + "errno", + "libc", + "linux-raw-sys 0.4.13", + "windows-sys 0.52.0", +] + [[package]] name = "rustls" version = "0.21.6" @@ -3904,34 +4111,34 @@ dependencies = [ [[package]] name = "rustybuzz" -version = "0.7.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "162bdf42e261bee271b3957691018634488084ef577dddeb6420a9684cab2a6a" +checksum = "71cd15fef9112a1f94ac64b58d1e4628192631ad6af4dc69997f995459c874e7" dependencies = [ "bitflags 1.3.2", "bytemuck", "smallvec", - "ttf-parser 0.18.1", + "ttf-parser 0.19.2", "unicode-bidi-mirroring", "unicode-ccc", - "unicode-general-category", + "unicode-properties", "unicode-script", ] [[package]] name = "rustybuzz" -version = "0.8.0" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82eea22c8f56965eeaf3a209b3d24508256c7b920fb3b6211b8ba0f7c0583250" +checksum = "2ee8fe2a8461a0854a37101fe7a1b13998d0cfa987e43248e81d2a5f4570f6fa" dependencies = [ "bitflags 1.3.2", "bytemuck", "libm", "smallvec", - "ttf-parser 0.19.2", + "ttf-parser 0.20.0", "unicode-bidi-mirroring", "unicode-ccc", - "unicode-general-category", + "unicode-properties", "unicode-script", ] @@ -3941,6 +4148,15 @@ version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + [[package]] name = "scoped-tls" version = "1.0.1" @@ -3971,15 +4187,15 @@ dependencies = [ [[package]] name = "sctk-adwaita" -version = "0.5.4" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cda4e97be1fd174ccc2aae81c8b694e803fa99b34e8fd0f057a9d70698e3ed09" +checksum = "82b2eaf3a5b264a521b988b2e73042e742df700c4f962cde845d1541adb46550" dependencies = [ "ab_glyph", "log", - "memmap2 0.5.10", + "memmap2 0.9.4", "smithay-client-toolkit", - "tiny-skia 0.8.4", + "tiny-skia", ] [[package]] @@ -4016,6 +4232,12 @@ dependencies = [ "cc", ] +[[package]] +name = "self_cell" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58bf37232d3bb9a2c4e641ca2a11d83b5062066f88df7fed36c28772046d65ba" + [[package]] name = "semver" version = "1.0.18" @@ -4039,7 +4261,7 @@ checksum = "5ad697f7e0b65af4983a4ce8f56ed5b357e8d3c36651bf6a7e13639c17b8e670" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -4168,31 +4390,47 @@ checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" [[package]] name = "smithay-client-toolkit" -version = "0.16.0" +version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f307c47d32d2715eb2e0ece5589057820e0e5e70d07c247d1063e844e107f454" +checksum = "922fd3eeab3bd820d76537ce8f582b1cf951eceb5475c28500c7457d9d17f53a" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "calloop", - "dlib", - "lazy_static", + "calloop-wayland-source", + "cursor-icon", + "libc", "log", - "memmap2 0.5.10", - "nix 0.24.3", - "pkg-config", - "wayland-client 0.29.5", + "memmap2 0.9.4", + "rustix 0.38.34", + "thiserror", + "wayland-backend", + "wayland-client", + "wayland-csd-frame", "wayland-cursor", "wayland-protocols", + "wayland-protocols-wlr", + "wayland-scanner", + "xkeysym", ] [[package]] name = "smithay-clipboard" -version = "0.6.6" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a345c870a1fae0b1b779085e81b51e614767c239e93503588e54c5b17f4b0e8" +checksum = "c091e7354ea8059d6ad99eace06dd13ddeedbb0ac72d40a9a6e7ff790525882d" dependencies = [ + "libc", "smithay-client-toolkit", - "wayland-client 0.29.5", + "wayland-backend", +] + +[[package]] +name = "smol_str" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6845563ada680337a52d43bb0b29f396f2d911616f6573012645b9e3d048a49" +dependencies = [ + "serde", ] [[package]] @@ -4229,30 +4467,33 @@ dependencies = [ [[package]] name = "softbuffer" -version = "0.2.1" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2b953f6ba7285f0af131eb748aabd8ddaf53e0b81dda3ba5d803b0847d6559f" +checksum = "61d5d17f23326fe0d9b0af282f73f3af666699420fd5f42629efd9c6e7dc166f" dependencies = [ + "as-raw-xcb-connection", "bytemuck", - "cfg_aliases", + "cfg_aliases 0.2.0", "cocoa", "core-graphics", - "fastrand", - "foreign-types", + "drm", + "fastrand 2.1.0", + "foreign-types 0.5.0", + "js-sys", "log", - "nix 0.26.2", + "memmap2 0.9.4", "objc", "raw-window-handle", - "redox_syscall 0.3.5", - "thiserror", + "redox_syscall 0.5.1", + "rustix 0.38.34", + "tiny-xlib", "wasm-bindgen", "wayland-backend", - "wayland-client 0.30.2", - "wayland-sys 0.30.1", + "wayland-client", + "wayland-sys", "web-sys", - "windows-sys 0.48.0", - "x11-dl", - "x11rb 0.11.1", + "windows-sys 0.52.0", + "x11rb", ] [[package]] @@ -4272,12 +4513,11 @@ dependencies = [ [[package]] name = "spirv" -version = "0.2.0+1.5.4" +version = "0.3.0+sdk-1.3.268.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "246bfa38fe3db3f1dfc8ca5a2cdeb7348c78be2112740cc0ec8ef18b6d94f830" +checksum = "eda41003dc44290527a59b13432d4a0379379fa074b70174882adfbdfd917844" dependencies = [ - "bitflags 1.3.2", - "num-traits", + "bitflags 2.4.2", ] [[package]] @@ -4296,12 +4536,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "str-buf" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e08d8363704e6c71fc928674353e6b7c23dcea9d82d7012c8faf2a3a025f8d0" - [[package]] name = "strict-num" version = "0.1.1" @@ -4325,11 +4559,11 @@ checksum = "8fb1df15f412ee2e9dfc1c504260fa695c1c3f10fe9f4a6ee2d2184d7d6450e2" [[package]] name = "svgtypes" -version = "0.11.0" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed4b0611e7f3277f68c0fa18e385d9e2d26923691379690039548f867cef02a7" +checksum = "d71499ff2d42f59d26edb21369a308ede691421f79ebc0f001e2b1fd3a7c9e52" dependencies = [ - "kurbo", + "kurbo 0.9.4", "siphasher", ] @@ -4357,9 +4591,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.43" +version = "2.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee659fb5f3d355364e1f3e5bc10fb82068efbf824a1e9d1c9504244a6469ad53" +checksum = "909518bc7b1c9b779f1bbf07f2929d35af9f0f37e47c6e9ef7f9dddc1e1821f3" dependencies = [ "proc-macro2", "quote", @@ -4393,39 +4627,39 @@ checksum = "31c0432476357e58790aaa47a8efb0c5138f137343f3b5f23bd36a27e3b0a6d6" dependencies = [ "autocfg", "cfg-if", - "fastrand", + "fastrand 1.9.0", "redox_syscall 0.3.5", - "rustix", + "rustix 0.37.13", "windows-sys 0.48.0", ] [[package]] name = "termcolor" -version = "1.2.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be55cf8942feac5c765c2c993422806843c9a9a45d4d5c407ad6dd2ea95eb9b6" +checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" dependencies = [ "winapi-util", ] [[package]] name = "thiserror" -version = "1.0.40" +version = "1.0.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" +checksum = "f0126ad08bff79f29fc3ae6a55cc72352056dfff61e3ff8bb7129476d44b23aa" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.40" +version = "1.0.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" +checksum = "d1cd413b5d558b4c5bf3680e324a6fa5014e7b7c067a51e69dbdf47eb7148b66" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -4471,23 +4705,9 @@ dependencies = [ [[package]] name = "tiny-skia" -version = "0.8.4" +version = "0.11.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df8493a203431061e901613751931f047d1971337153f96d0e5e363d6dbf6a67" -dependencies = [ - "arrayref", - "arrayvec", - "bytemuck", - "cfg-if", - "png", - "tiny-skia-path 0.8.4", -] - -[[package]] -name = "tiny-skia" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7db11798945fa5c3e5490c794ccca7c6de86d3afdd54b4eb324109939c6f37bc" +checksum = "83d13394d44dae3207b52a326c0c85a8bf87f1541f23b0d143811088497b09ab" dependencies = [ "arrayref", "arrayvec", @@ -4495,14 +4715,14 @@ dependencies = [ "cfg-if", "log", "png", - "tiny-skia-path 0.10.0", + "tiny-skia-path", ] [[package]] name = "tiny-skia-path" -version = "0.8.4" +version = "0.11.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adbfb5d3f3dd57a0e11d12f4f13d4ebbbc1b5c15b7ab0a156d030b21da5f677c" +checksum = "9c9e7fc0c2e86a30b117d0462aa261b72b7a99b7ebd7deb3a14ceda95c5bdc93" dependencies = [ "arrayref", "bytemuck", @@ -4510,14 +4730,15 @@ dependencies = [ ] [[package]] -name = "tiny-skia-path" -version = "0.10.0" +name = "tiny-xlib" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f60aa35c89ac2687ace1a2556eaaea68e8c0d47408a2e3e7f5c98a489e7281c" +checksum = "d4098d49269baa034a8d1eae9bd63e9fa532148d772121dace3bcd6a6c98eb6d" dependencies = [ - "arrayref", - "bytemuck", - "strict-num", + "as-raw-xcb-connection", + "ctor", + "libloading 0.8.1", + "tracing", ] [[package]] @@ -4561,7 +4782,7 @@ checksum = "61a573bdc87985e9d6ddeed1b3d864e8a302c847e40d647746df2f1de209d1ce" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -4710,15 +4931,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49d64318d8311fc2668e48b63969f4343e0a85c4a109aa8460d6672e364b8bd1" [[package]] -name = "twox-hash" -version = "1.6.3" +name = "ttf-parser" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" -dependencies = [ - "cfg-if", - "rand", - "static_assertions", -] +checksum = "17f77d76d837a7830fe1d4f12b7b4ba4192c1888001c7164257e4bc6d21d96b4" [[package]] name = "typenum" @@ -4744,12 +4960,6 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cc2520efa644f8268dce4dcd3050eaa7fc044fca03961e9998ac7e2e92b77cf1" -[[package]] -name = "unicode-general-category" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2281c8c1d221438e373249e065ca4989c4c36952c211ff21a0ee91c44a3869e7" - [[package]] name = "unicode-ident" version = "1.0.8" @@ -4771,6 +4981,12 @@ dependencies = [ "tinyvec", ] +[[package]] +name = "unicode-properties" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4259d9d4425d9f0661581b804cb85fe66a4c631cadd8f490d1c13a35d5d9291" + [[package]] name = "unicode-script" version = "0.5.5" @@ -4830,9 +5046,9 @@ dependencies = [ [[package]] name = "usvg" -version = "0.35.0" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14d09ddfb0d93bf84824c09336d32e42f80961a9d1680832eb24fdf249ce11e6" +checksum = "c51daa774fe9ee5efcf7b4fec13019b8119cda764d9a8b5b06df02bb1445c656" dependencies = [ "base64 0.21.6", "log", @@ -4845,14 +5061,14 @@ dependencies = [ [[package]] name = "usvg-parser" -version = "0.35.0" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d19bf93d230813599927d88557014e0908ecc3531666d47c634c6838bc8db408" +checksum = "45c88a5ffaa338f0e978ecf3d4e00d8f9f493e29bed0752e1a808a1db16afc40" dependencies = [ "data-url", "flate2", "imagesize", - "kurbo", + "kurbo 0.9.4", "log", "roxmltree", "simplecss", @@ -4863,14 +5079,14 @@ dependencies = [ [[package]] name = "usvg-text-layout" -version = "0.35.0" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "035044604e89652c0a2959b8b356946997a52649ba6cade45928c2842376feb4" +checksum = "4d2374378cb7a3fb8f33894e0fdb8625e1bbc4f25312db8d91f862130b541593" dependencies = [ "fontdb", - "kurbo", + "kurbo 0.9.4", "log", - "rustybuzz 0.7.0", + "rustybuzz 0.10.0", "unicode-bidi", "unicode-script", "unicode-vo", @@ -4879,14 +5095,14 @@ dependencies = [ [[package]] name = "usvg-tree" -version = "0.35.0" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7939a7e4ed21cadb5d311d6339730681c3e24c3e81d60065be80e485d3fc8b92" +checksum = "6cacb0c5edeaf3e80e5afcf5b0d4004cc1d36318befc9a7c6606507e5d0f4062" dependencies = [ "rctree", "strict-num", "svgtypes", - "tiny-skia-path 0.10.0", + "tiny-skia-path", ] [[package]] @@ -4901,18 +5117,22 @@ version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" -[[package]] -name = "vec_map" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191" - [[package]] name = "version_check" version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + [[package]] name = "want" version = "0.3.1" @@ -4936,9 +5156,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.87" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -4946,24 +5166,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.87" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.37" +version = "0.4.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" dependencies = [ "cfg-if", "js-sys", @@ -4973,9 +5193,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.87" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -4983,22 +5203,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.87" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.87" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-timer" @@ -5017,98 +5237,95 @@ dependencies = [ [[package]] name = "wayland-backend" -version = "0.1.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41b48e27457e8da3b2260ac60d0a94512f5cba36448679f3747c0865b7893ed8" +checksum = "9d50fa61ce90d76474c87f5fc002828d81b32677340112b4ef08079a9d459a40" dependencies = [ "cc", "downcast-rs", - "io-lifetimes", - "nix 0.26.2", + "rustix 0.38.34", "scoped-tls", "smallvec", - "wayland-sys 0.30.1", + "wayland-sys", ] [[package]] name = "wayland-client" -version = "0.29.5" +version = "0.31.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f3b068c05a039c9f755f881dc50f01732214f5685e379829759088967c46715" +checksum = "82fb96ee935c2cea6668ccb470fb7771f6215d1691746c2d896b447a00ad3f1f" dependencies = [ - "bitflags 1.3.2", - "downcast-rs", - "libc", - "nix 0.24.3", - "scoped-tls", - "wayland-commons", - "wayland-scanner 0.29.5", - "wayland-sys 0.29.5", -] - -[[package]] -name = "wayland-client" -version = "0.30.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "489c9654770f674fc7e266b3c579f4053d7551df0ceb392f153adb1f9ed06ac8" -dependencies = [ - "bitflags 1.3.2", - "nix 0.26.2", + "bitflags 2.4.2", + "rustix 0.38.34", "wayland-backend", - "wayland-scanner 0.30.1", + "wayland-scanner", ] [[package]] -name = "wayland-commons" -version = "0.29.5" +name = "wayland-csd-frame" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8691f134d584a33a6606d9d717b95c4fa20065605f798a3f350d78dced02a902" +checksum = "625c5029dbd43d25e6aa9615e88b829a5cad13b2819c4ae129fdbb7c31ab4c7e" dependencies = [ - "nix 0.24.3", - "once_cell", - "smallvec", - "wayland-sys 0.29.5", + "bitflags 2.4.2", + "cursor-icon", + "wayland-backend", ] [[package]] name = "wayland-cursor" -version = "0.29.5" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6865c6b66f13d6257bef1cd40cbfe8ef2f150fb8ebbdb1e8e873455931377661" +checksum = "71ce5fa868dd13d11a0d04c5e2e65726d0897be8de247c0c5a65886e283231ba" dependencies = [ - "nix 0.24.3", - "wayland-client 0.29.5", + "rustix 0.38.34", + "wayland-client", "xcursor", ] [[package]] name = "wayland-protocols" -version = "0.29.5" +version = "0.31.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b950621f9354b322ee817a23474e479b34be96c2e909c14f7bc0100e9a970bc6" +checksum = "8f81f365b8b4a97f422ac0e8737c438024b5951734506b0e1d775c73030561f4" dependencies = [ - "bitflags 1.3.2", - "wayland-client 0.29.5", - "wayland-commons", - "wayland-scanner 0.29.5", + "bitflags 2.4.2", + "wayland-backend", + "wayland-client", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-plasma" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23803551115ff9ea9bce586860c5c5a971e360825a0309264102a9495a5ff479" +dependencies = [ + "bitflags 2.4.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-wlr" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad1f61b76b6c2d8742e10f9ba5c3737f6530b4c243132c2a2ccc8aa96fe25cd6" +dependencies = [ + "bitflags 2.4.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", ] [[package]] name = "wayland-scanner" -version = "0.29.5" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f4303d8fa22ab852f789e75a967f0a2cdc430a607751c0499bada3e451cbd53" -dependencies = [ - "proc-macro2", - "quote", - "xml-rs", -] - -[[package]] -name = "wayland-scanner" -version = "0.30.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9b873b257fbc32ec909c0eb80dea312076a67014e65e245f5eb69a6b8ab330e" +checksum = "63b3a62929287001986fb58c789dce9b67604a397c15c611ad9f747300b6c283" dependencies = [ "proc-macro2", "quick-xml", @@ -5117,32 +5334,31 @@ dependencies = [ [[package]] name = "wayland-sys" -version = "0.29.5" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be12ce1a3c39ec7dba25594b97b42cb3195d54953ddb9d3d95a7c3902bc6e9d4" +checksum = "15a0c8eaff5216d07f226cb7a549159267f3467b289d9a2e52fd3ef5aae2b7af" dependencies = [ "dlib", - "lazy_static", - "pkg-config", -] - -[[package]] -name = "wayland-sys" -version = "0.30.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96b2a02ac608e07132978689a6f9bf4214949c85998c247abadd4f4129b1aa06" -dependencies = [ - "dlib", - "lazy_static", "log", + "once_cell", "pkg-config", ] [[package]] name = "web-sys" -version = "0.3.61" +version = "0.3.67" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" +checksum = "58cd2333b6e0be7a39605f0e255892fd7418a682d8da8fe042fe25128794d2ed" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web-time" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa30049b1c872b72c89866d458eae9f20380ab280ffd1b1e18df2d3e2d98cfe0" dependencies = [ "js-sys", "wasm-bindgen", @@ -5162,12 +5378,13 @@ checksum = "9193164d4de03a926d909d3bc7c30543cecb35400c02114792c2cae20d5e2dbb" [[package]] name = "wgpu" -version = "0.16.3" +version = "0.19.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "480c965c9306872eb6255fa55e4b4953be55a8b64d57e61d7ff840d3dcc051cd" +checksum = "cbd7311dbd2abcfebaabf1841a2824ed7c8be443a0f29166e5d3c6a53a762c01" dependencies = [ "arrayvec", "cfg-if", + "cfg_aliases 0.1.1", "js-sys", "log", "naga", @@ -5186,16 +5403,19 @@ dependencies = [ [[package]] name = "wgpu-core" -version = "0.16.1" +version = "0.19.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f478237b4bf0d5b70a39898a66fa67ca3a007d79f2520485b8b0c3dfc46f8c2" +checksum = "28b94525fc99ba9e5c9a9e24764f2bc29bad0911a7446c12f446a8277369bf3a" dependencies = [ "arrayvec", "bit-vec", "bitflags 2.4.2", + "cfg_aliases 0.1.1", "codespan-reporting", + "indexmap 2.0.0", "log", "naga", + "once_cell", "parking_lot 0.12.1", "profiling", "raw-window-handle", @@ -5209,9 +5429,9 @@ dependencies = [ [[package]] name = "wgpu-hal" -version = "0.16.2" +version = "0.19.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ecb3258078e936deee14fd4e0febe1cfe9bbb5ffef165cb60218d2ee5eb4448" +checksum = "fc1a4924366df7ab41a5d8546d6534f1f33231aa5b3f72b9930e300f254e39c3" dependencies = [ "android_system_properties", "arrayvec", @@ -5219,10 +5439,11 @@ dependencies = [ "bit-set", "bitflags 2.4.2", "block", + "cfg_aliases 0.1.1", "core-graphics-types", "d3d12", - "foreign-types", "glow", + "glutin_wgl_sys", "gpu-alloc", "gpu-allocator", "gpu-descriptor", @@ -5234,7 +5455,9 @@ dependencies = [ "log", "metal", "naga", + "ndk-sys", "objc", + "once_cell", "parking_lot 0.12.1", "profiling", "range-alloc", @@ -5251,9 +5474,9 @@ dependencies = [ [[package]] name = "wgpu-types" -version = "0.16.1" +version = "0.19.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0c153280bb108c2979eb5c7391cb18c56642dd3c072e55f52065e13e2a1252a" +checksum = "b671ff9fb03f78b46ff176494ee1ebe7d603393f42664be55b64dc8d53969805" dependencies = [ "bitflags 2.4.2", "js-sys", @@ -5302,15 +5525,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "winapi-wsapoll" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44c17110f57155602a80dca10be03852116403c9ff3cd25b079d666f2aa3df6e" -dependencies = [ - "winapi", -] - [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" @@ -5319,9 +5533,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "window_clipboard" -version = "0.3.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63287c9c4396ccf5346d035a9b0fcaead9e18377637f5eaa78b7ac65c873ff7d" +checksum = "f6d692d46038c433f9daee7ad8757e002a4248c20b0a3fbc991d99521d3bcb6d" dependencies = [ "clipboard-win", "clipboard_macos", @@ -5331,15 +5545,6 @@ dependencies = [ "thiserror", ] -[[package]] -name = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-targets 0.42.2", -] - [[package]] name = "windows" version = "0.48.0" @@ -5349,6 +5554,25 @@ dependencies = [ "windows-targets 0.48.0", ] +[[package]] +name = "windows" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e48a53791691ab099e5e2ad123536d0fff50652600abaf43bbf952894110d0be" +dependencies = [ + "windows-core", + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-core" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9" +dependencies = [ + "windows-targets 0.52.5", +] + [[package]] name = "windows-sys" version = "0.45.0" @@ -5367,6 +5591,15 @@ dependencies = [ "windows-targets 0.48.0", ] +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + [[package]] name = "windows-targets" version = "0.42.2" @@ -5397,6 +5630,22 @@ dependencies = [ "windows_x86_64_msvc 0.48.0", ] +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + [[package]] name = "windows_aarch64_gnullvm" version = "0.42.2" @@ -5409,6 +5658,12 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + [[package]] name = "windows_aarch64_msvc" version = "0.42.2" @@ -5421,6 +5676,12 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + [[package]] name = "windows_i686_gnu" version = "0.42.2" @@ -5433,6 +5694,18 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + [[package]] name = "windows_i686_msvc" version = "0.42.2" @@ -5445,6 +5718,12 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + [[package]] name = "windows_x86_64_gnu" version = "0.42.2" @@ -5457,6 +5736,12 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + [[package]] name = "windows_x86_64_gnullvm" version = "0.42.2" @@ -5469,6 +5754,12 @@ version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + [[package]] name = "windows_x86_64_msvc" version = "0.42.2" @@ -5482,38 +5773,57 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" [[package]] -name = "winit" -version = "0.28.7" +name = "windows_x86_64_msvc" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9596d90b45384f5281384ab204224876e8e8bf7d58366d9b795ad99aa9894b94" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winit" +version = "0.29.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d59ad965a635657faf09c8f062badd885748428933dad8e8bdd64064d92e5ca" dependencies = [ + "ahash 0.8.11", "android-activity", - "bitflags 1.3.2", - "cfg_aliases", + "atomic-waker", + "bitflags 2.4.2", + "bytemuck", + "calloop", + "cfg_aliases 0.1.1", "core-foundation", "core-graphics", - "dispatch", - "instant", + "cursor-icon", + "icrate", + "js-sys", "libc", "log", - "mio", + "memmap2 0.9.4", "ndk", + "ndk-sys", "objc2", "once_cell", "orbclient", "percent-encoding", "raw-window-handle", "redox_syscall 0.3.5", + "rustix 0.38.34", "sctk-adwaita", "smithay-client-toolkit", + "smol_str", + "unicode-segmentation", "wasm-bindgen", - "wayland-client 0.29.5", - "wayland-commons", + "wasm-bindgen-futures", + "wayland-backend", + "wayland-client", "wayland-protocols", - "wayland-scanner 0.29.5", + "wayland-protocols-plasma", "web-sys", - "windows-sys 0.45.0", + "web-time", + "windows-sys 0.48.0", "x11-dl", + "x11rb", + "xkbcommon-dl", ] [[package]] @@ -5548,40 +5858,24 @@ dependencies = [ [[package]] name = "x11rb" -version = "0.9.0" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e99be55648b3ae2a52342f9a870c0e138709a3493261ce9b469afe6e4df6d8a" -dependencies = [ - "gethostname", - "nix 0.22.3", - "winapi", - "winapi-wsapoll", -] - -[[package]] -name = "x11rb" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdf3c79412dd91bae7a7366b8ad1565a85e35dd049affc3a6a2c549e97419617" +checksum = "5d91ffca73ee7f68ce055750bf9f6eca0780b8c85eff9bc046a3b0da41755e12" dependencies = [ + "as-raw-xcb-connection", "gethostname", "libc", - "libloading 0.7.4", - "nix 0.25.1", + "libloading 0.8.1", "once_cell", - "winapi", - "winapi-wsapoll", + "rustix 0.38.34", "x11rb-protocol", ] [[package]] name = "x11rb-protocol" -version = "0.11.1" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0b1513b141123073ce54d5bb1d33f801f17508fbd61e02060b1214e96d39c56" -dependencies = [ - "nix 0.25.1", -] +checksum = "ec107c4503ea0b4a98ef47356329af139c0a4f7750e621cf2973cd3385ebcb3d" [[package]] name = "x25519-dalek" @@ -5603,6 +5897,25 @@ dependencies = [ "nom", ] +[[package]] +name = "xkbcommon-dl" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d039de8032a9a8856a6be89cea3e5d12fdd82306ab7c94d74e6deab2460651c5" +dependencies = [ + "bitflags 2.4.2", + "dlib", + "log", + "once_cell", + "xkeysym", +] + +[[package]] +name = "xkeysym" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "054a8e68b76250b253f671d1268cb7f1ae089ec35e195b2efb2a4e9a836d0621" + [[package]] name = "xml-rs" version = "0.8.4" @@ -5621,6 +5934,18 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec7a2a501ed189703dba8b08142f057e887dfc4b2cc4db2d343ac6376ba3e0b9" +[[package]] +name = "xxhash-rust" +version = "0.8.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "927da81e25be1e1a2901d59b81b37dd2efd1fc9c9345a55007f09bf5a2d3ee03" + +[[package]] +name = "yansi" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" + [[package]] name = "yazi" version = "0.1.6" @@ -5650,7 +5975,7 @@ checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] @@ -5670,7 +5995,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.43", + "syn 2.0.60", ] [[package]] diff --git a/gui/Cargo.toml b/gui/Cargo.toml index 9a81707b..87dce873 100644 --- a/gui/Cargo.toml +++ b/gui/Cargo.toml @@ -21,8 +21,8 @@ liana_ui = { path = "ui" } backtrace = "0.3" hex = "0.4.3" -iced = { version = "0.10", default-features = false, features = ["tokio", "svg", "qr_code", "image", "lazy", "wgpu"] } -iced_runtime = "0.1.1" +iced = { version = "0.12.1", default-features = false, features = ["tokio", "svg", "qr_code", "image", "lazy", "webgl"] } +iced_runtime = "0.12.1" tokio = {version = "1.21.0", features = ["signal"]} serde = { version = "1.0", features = ["derive"] } @@ -47,6 +47,12 @@ bitcoin_hashes = "0.12" reqwest = { version = "0.11", default-features=false, features = ["rustls-tls"] } rust-ini = "0.19.0" + +[patch.crates-io] +iced_style = { git = "https://github.com/edouardparis/iced", branch = "patch-0.12.3"} +iced_winit = { git = "https://github.com/edouardparis/iced", branch = "patch-0.12.3"} +iced_futures = { git = "https://github.com/edouardparis/iced", branch = "patch-0.12.3"} + [target.'cfg(windows)'.dependencies] zip = { version = "0.6", default-features=false, features = ["bzip2", "deflate"] } diff --git a/gui/src/app/state/receive.rs b/gui/src/app/state/receive.rs index 4387937d..17ef1780 100644 --- a/gui/src/app/state/receive.rs +++ b/gui/src/app/state/receive.rs @@ -302,13 +302,13 @@ impl VerifyAddressModal { } pub struct ShowQrCodeModal { - qr_code: qr_code::State, + qr_code: qr_code::Data, address: String, } impl ShowQrCodeModal { pub fn new(address: &Address, index: ChildNumber) -> Option { - qr_code::State::new(format!("bitcoin:{}?index={}", address, index)) + qr_code::Data::new(format!("bitcoin:{}?index={}", address, index)) .ok() .map(|qr_code| Self { qr_code, diff --git a/gui/src/app/view/coins.rs b/gui/src/app/view/coins.rs index c4ef4209..797b6633 100644 --- a/gui/src/app/view/coins.rs +++ b/gui/src/app/view/coins.rs @@ -6,7 +6,6 @@ use liana_ui::{ color, component::{amount::*, badge, button, form, text::*}, icon, theme, - util::Collection, widget::*, }; diff --git a/gui/src/app/view/home.rs b/gui/src/app/view/home.rs index 14bd9bc8..7714aa70 100644 --- a/gui/src/app/view/home.rs +++ b/gui/src/app/view/home.rs @@ -8,7 +8,6 @@ use liana_ui::{ color, component::{amount::*, button, card, event, form, text::*}, icon, theme, - util::Collection, widget::*, }; diff --git a/gui/src/app/view/mod.rs b/gui/src/app/view/mod.rs index e760f58b..181e7b5a 100644 --- a/gui/src/app/view/mod.rs +++ b/gui/src/app/view/mod.rs @@ -29,7 +29,6 @@ use liana_ui::{ }, image::*, theme, - util::Collection, widget::*, }; diff --git a/gui/src/app/view/psbt.rs b/gui/src/app/view/psbt.rs index 7a22afd0..5cb6bbe2 100644 --- a/gui/src/app/view/psbt.rs +++ b/gui/src/app/view/psbt.rs @@ -23,7 +23,6 @@ use liana_ui::{ text::{self, *}, }, icon, theme, - util::Collection, widget::*, }; @@ -426,7 +425,7 @@ pub fn signatures<'a>( Container::new(text(alias)) .padding(10) .style(theme::Container::Pill(theme::Pill::Simple)), - value.to_string(), + liana_ui::widget::Text::new(value.to_string()), tooltip::Position::Bottom, ) .style(theme::Container::Card(theme::Card::Simple)), @@ -522,7 +521,7 @@ fn container_from_fg( Container::new(text(alias)) .padding(10) .style(theme::Container::Pill(theme::Pill::Simple)), - fg.to_string(), + liana_ui::widget::Text::new(fg.to_string()), tooltip::Position::Bottom, ) .style(theme::Container::Card(theme::Card::Simple)), diff --git a/gui/src/app/view/psbts.rs b/gui/src/app/view/psbts.rs index 3bc28d8b..dc06c406 100644 --- a/gui/src/app/view/psbts.rs +++ b/gui/src/app/view/psbts.rs @@ -4,7 +4,6 @@ use liana_ui::{ color, component::{amount::*, badge, button, card, form, text::*}, icon, theme, - util::Collection, widget::*, }; diff --git a/gui/src/app/view/receive.rs b/gui/src/app/view/receive.rs index 8b710ce3..45d582d6 100644 --- a/gui/src/app/view/receive.rs +++ b/gui/src/app/view/receive.rs @@ -21,7 +21,6 @@ use liana_ui::{ text::{self, *}, }, icon, theme, - util::Collection, widget::*, }; @@ -216,13 +215,13 @@ pub fn verify_address_modal<'a>( .into() } -pub fn qr_modal<'a>(qr: &'a qr_code::State, address: &'a String) -> Element<'a, Message> { +pub fn qr_modal<'a>(qr: &'a qr_code::Data, address: &'a String) -> Element<'a, Message> { Column::new() .push( Row::new() .push(Space::with_width(Length::Fill)) .push( - Container::new(QRCode::new(qr).cell_size(8)) + Container::new(QRCode::::new(qr).cell_size(8)) .padding(10) .style(theme::Container::QrCode), ) diff --git a/gui/src/app/view/recovery.rs b/gui/src/app/view/recovery.rs index 52e435c2..6a5f39f2 100644 --- a/gui/src/app/view/recovery.rs +++ b/gui/src/app/view/recovery.rs @@ -13,7 +13,6 @@ use liana::miniscript::bitcoin::{ use liana_ui::{ component::{amount::*, button, form, text::*}, icon, theme, - util::*, widget::*, }; @@ -144,9 +143,10 @@ pub fn recovery_path_view<'a>( selected: bool, ) -> Element<'a, Message> { Row::new() - .push(checkbox("", selected, move |_| { - Message::CreateSpend(CreateSpendMessage::SelectPath(index)) - })) + .push( + checkbox("", selected) + .on_toggle(move |_| Message::CreateSpend(CreateSpendMessage::SelectPath(index))), + ) .push( Column::new() .push( @@ -170,7 +170,7 @@ pub fn recovery_path_view<'a>( Container::new(text(alias)) .padding(5) .style(theme::Container::Pill(theme::Pill::Simple)), - fg.to_string(), + liana_ui::widget::Text::new(fg.to_string()), tooltip::Position::Bottom, ) .style(theme::Container::Card(theme::Card::Simple)), diff --git a/gui/src/app/view/settings.rs b/gui/src/app/view/settings.rs index 670e3f2e..6c5583b6 100644 --- a/gui/src/app/view/settings.rs +++ b/gui/src/app/view/settings.rs @@ -18,7 +18,6 @@ use liana_ui::{ color, component::{badge, button, card, form, separation, text::*, tooltip::tooltip}, icon, theme, - util::Collection, widget::*, }; diff --git a/gui/src/app/view/spend/mod.rs b/gui/src/app/view/spend/mod.rs index 3dcfafae..e760ed68 100644 --- a/gui/src/app/view/spend/mod.rs +++ b/gui/src/app/view/spend/mod.rs @@ -15,7 +15,6 @@ use liana_ui::{ color, component::{amount::*, badge, button, form, text::*}, icon, theme, - util::Collection, widget::*, }; @@ -405,9 +404,8 @@ pub fn recipient_view<'a>( None }) .push(tooltip::Tooltip::new( - checkbox("MAX", is_max_selected, move |_| { - CreateSpendMessage::SendMaxToRecipient(index) - }), + checkbox("MAX", is_max_selected) + .on_toggle(move |_| CreateSpendMessage::SendMaxToRecipient(index)), // Add spaces at end so that text is padded at screen edge. "Total amount remaining after paying fee and any other recipients ", tooltip::Position::Bottom, @@ -431,9 +429,11 @@ fn coin_list_view<'a>( Row::new() .push( Row::new() - .push(checkbox("", selected, move |_| { - Message::CreateSpend(CreateSpendMessage::SelectCoin(i)) - })) + .push( + checkbox("", selected).on_toggle(move |_| { + Message::CreateSpend(CreateSpendMessage::SelectCoin(i)) + }), + ) .push( if let Some(label) = coins_labels.get(&coin.outpoint.to_string()) { Container::new(p1_regular(label)).width(Length::Fill) diff --git a/gui/src/app/view/transactions.rs b/gui/src/app/view/transactions.rs index 86c75b52..cab1064c 100644 --- a/gui/src/app/view/transactions.rs +++ b/gui/src/app/view/transactions.rs @@ -7,7 +7,6 @@ use liana_ui::{ color, component::{amount::*, badge, button, card, form, text::*}, icon, theme, - util::Collection, widget::*, }; diff --git a/gui/src/installer/view.rs b/gui/src/installer/view.rs index b5a936fa..aa71e077 100644 --- a/gui/src/installer/view.rs +++ b/gui/src/installer/view.rs @@ -18,7 +18,6 @@ use liana_ui::{ tooltip, }, icon, image, theme, - util::Collection, widget::*, }; @@ -720,11 +719,10 @@ pub fn participate_xpub<'a>( .push(signer) .width(Length::Fill), ) - .push(checkbox( - "I have shared my extended public key", - shared, - Message::UserActionDone, - )) + .push( + checkbox("I have shared my extended public key", shared) + .on_toggle(Message::UserActionDone), + ) .push(if shared && network_valid { button::primary(None, "Next") .width(Length::Fixed(200.0)) @@ -807,8 +805,7 @@ pub fn register_descriptor<'a>( .push_maybe(created_desc.then_some(checkbox( "I have registered the descriptor on my device(s)", done, - Message::UserActionDone, - ))) + ).on_toggle(Message::UserActionDone))) .push(if !created_desc || (done && !processing) { button::primary(None, "Next") .on_press(Message::Next) @@ -872,11 +869,9 @@ pub fn backup_descriptor<'a>( .spacing(10) .max_width(1000), )) - .push(checkbox( - "I have backed up my descriptor", - done, - Message::UserActionDone, - )) + .push( + checkbox("I have backed up my descriptor", done).on_toggle(Message::UserActionDone), + ) .push(if done { button::primary(None, "Next") .on_press(Message::Next) @@ -1678,7 +1673,7 @@ pub fn edit_sequence_modal<'a>(sequence: &form::Value) -> Element<'a, Me message::SequenceModal::SequenceEdited(v.to_string()), )) }) - .step(144), // 144 blocks per day + .step(144_u16), // 144 blocks per day ) .width(Length::Fixed(500.0)), ); @@ -1821,11 +1816,7 @@ pub fn backup_mnemonic<'a>( ) }), ) - .push(checkbox( - "I have backed up my mnemonic", - done, - Message::UserActionDone, - )) + .push(checkbox("I have backed up my mnemonic", done).on_toggle(Message::UserActionDone)) .push(if done { button::primary(None, "Next") .on_press(Message::Next) @@ -2041,7 +2032,7 @@ mod threshsold_input { } } - impl Component> for ThresholdInput { + impl Component for ThresholdInput { type State = (); type Event = Event; diff --git a/gui/src/launcher.rs b/gui/src/launcher.rs index 78190151..f2dc329d 100644 --- a/gui/src/launcher.rs +++ b/gui/src/launcher.rs @@ -11,7 +11,6 @@ use liana_ui::{ color, component::{badge, button, card, modal::Modal, notification, text::*}, icon, image, theme, - util::*, widget::*, }; diff --git a/gui/src/loader.rs b/gui/src/loader.rs index 8efcd107..db221b59 100644 --- a/gui/src/loader.rs +++ b/gui/src/loader.rs @@ -19,7 +19,6 @@ use liana_ui::{ color, component::{button, notification, text::*}, icon, - util::Collection, widget::*, }; diff --git a/gui/src/main.rs b/gui/src/main.rs index b7013489..84a2b712 100644 --- a/gui/src/main.rs +++ b/gui/src/main.rs @@ -5,9 +5,9 @@ use std::{error::Error, io::Write, path::PathBuf, process, str::FromStr}; use iced::{ event::{self, Event}, executor, - keyboard::{self, KeyCode}, - subscription, + keyboard::{self}, widget::{focus_next, focus_previous}, + window::settings::PlatformSpecific, Application, Command, Settings, Subscription, }; use tracing::{error, info}; @@ -180,14 +180,14 @@ impl Application for GUI { fn update(&mut self, message: Self::Message) -> Command { match (&mut self.state, message) { (_, Message::CtrlC) - | (_, Message::Event(iced::Event::Window(iced::window::Event::CloseRequested))) => { + | (_, Message::Event(iced::Event::Window(_, iced::window::Event::CloseRequested))) => { match &mut self.state { State::Loader(s) => s.stop(), State::Launcher(s) => s.stop(), State::Installer(s) => s.stop(), State::App(s) => s.stop(), }; - iced::window::close() + iced::window::close(iced::window::Id::MAIN) } (_, Message::KeyPressed(Key::Tab(shift))) => { log::debug!("Tab pressed!"); @@ -286,22 +286,29 @@ impl Application for GUI { State::App(v) => v.subscription().map(|msg| Message::Run(Box::new(msg))), State::Launcher(v) => v.subscription().map(|msg| Message::Launch(Box::new(msg))), }, - subscription::events_with(|event, status| match (&event, status) { + iced::event::listen_with(|event, status| match (&event, status) { ( Event::Keyboard(keyboard::Event::KeyPressed { - key_code: KeyCode::Tab, + key: iced::keyboard::Key::Named(iced::keyboard::key::Named::Tab), modifiers, .. }), event::Status::Ignored, ) => Some(Message::KeyPressed(Key::Tab(modifiers.shift()))), ( - iced::Event::Window(iced::window::Event::CloseRequested), + iced::Event::Window(_, iced::window::Event::CloseRequested), event::Status::Ignored, ) => Some(Message::Event(event)), _ => None, }), ]) + .with_filter(|event| { + matches!( + event, + iced::Event::Window(_, iced::window::Event::CloseRequested) + | iced::Event::Keyboard(_) + ) + }) } fn view(&self) -> Element { @@ -436,13 +443,13 @@ fn main() -> Result<(), Box> { settings.window.icon = Some(image::liana_app_icon()); settings.default_text_size = text::P1_SIZE.into(); settings.default_font = liana_ui::font::REGULAR; - settings.exit_on_close_request = false; + settings.window.exit_on_close_request = false; settings.id = Some("Liana".to_string()); #[cfg(target_os = "linux")] { - settings.window.platform_specific = iced::window::PlatformSpecific { + settings.window.platform_specific = PlatformSpecific { application_id: "Liana".to_string(), }; } diff --git a/gui/ui/Cargo.toml b/gui/ui/Cargo.toml index 86552c9f..badfe0eb 100644 --- a/gui/ui/Cargo.toml +++ b/gui/ui/Cargo.toml @@ -6,6 +6,6 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -iced = { version = "0.10", default-features = false, features = ["svg", "image", "lazy", "advanced"] } +iced = { version = "0.12.1", default-features = false, features = ["svg", "image", "lazy", "qr_code", "advanced", "webgl"] } bitcoin = "0.31" chrono = "0.4" diff --git a/gui/ui/src/component/amount.rs b/gui/ui/src/component/amount.rs index 1c780e8d..172a1363 100644 --- a/gui/ui/src/component/amount.rs +++ b/gui/ui/src/component/amount.rs @@ -1,6 +1,6 @@ pub use bitcoin::Amount; -use crate::{color, component::text::*, util::Collection, widget::*}; +use crate::{color, component::text::*, widget::*}; pub fn amount<'a, T: 'a>(a: &Amount) -> Row<'a, T> { amount_with_size(a, P1_SIZE) diff --git a/gui/ui/src/component/card.rs b/gui/ui/src/component/card.rs index 7b6e8500..d15b7b82 100644 --- a/gui/ui/src/component/card.rs +++ b/gui/ui/src/component/card.rs @@ -34,7 +34,7 @@ pub fn error<'a, T: 'a>(message: &'static str, error: String) -> Container<'a, T .align_items(iced::Alignment::Center) .push(icon::warning_icon().style(color::RED)) .push(text(message).style(color::RED)), - error, + Text::new(error), iced::widget::tooltip::Position::Bottom, ) .style(theme::Container::Card(theme::Card::Error)), diff --git a/gui/ui/src/component/collapse.rs b/gui/ui/src/component/collapse.rs index 0c04aeee..9fff5036 100644 --- a/gui/ui/src/component/collapse.rs +++ b/gui/ui/src/component/collapse.rs @@ -1,5 +1,8 @@ -use crate::widget::*; -use iced::widget::{column, component, Component}; +use iced::{ + advanced, + widget::{column, component, Button, Component}, + Element, +}; use std::marker::PhantomData; pub struct Collapse<'a, M, H, F, C> { @@ -9,13 +12,15 @@ pub struct Collapse<'a, M, H, F, C> { phantom: PhantomData<&'a M>, } -impl<'a, Message, T, H, F, C> Collapse<'a, Message, H, F, C> +impl<'a, Message, T, H, F, C, Theme, Renderer> Collapse<'a, Message, H, F, C> where + Renderer: advanced::Renderer, + Theme: iced::widget::button::StyleSheet, Message: 'a, T: Into + Clone + 'a, - H: Fn() -> Button<'a, Event> + 'a, - F: Fn() -> Button<'a, Event> + 'a, - C: Fn() -> Element<'a, T> + 'a, + H: Fn() -> Button<'a, Event, Theme, Renderer> + 'a, + F: Fn() -> Button<'a, Event, Theme, Renderer> + 'a, + C: Fn() -> Element<'a, T, Theme, Renderer> + 'a, { pub fn new(before: H, after: F, content: C) -> Self { Collapse { @@ -33,13 +38,15 @@ pub enum Event { Collapse(bool), } -impl<'a, Message, T, H, F, C> Component> +impl<'a, Message, T, H, F, C, Theme, Renderer> Component for Collapse<'a, Message, H, F, C> where T: Into + Clone + 'a, - H: Fn() -> Button<'a, Event>, - F: Fn() -> Button<'a, Event>, - C: Fn() -> Element<'a, T>, + H: Fn() -> Button<'a, Event, Theme, Renderer>, + F: Fn() -> Button<'a, Event, Theme, Renderer>, + C: Fn() -> Element<'a, T, Theme, Renderer>, + Renderer: 'a + advanced::Renderer, + Theme: 'a + iced::widget::button::StyleSheet, { type State = bool; type Event = Event; @@ -54,7 +61,7 @@ where } } - fn view(&self, state: &Self::State) -> Element { + fn view(&self, state: &Self::State) -> Element { if *state { column![ (self.after)().on_press(Event::Collapse(false)), @@ -67,14 +74,16 @@ where } } -impl<'a, Message, T, H: 'a, F: 'a, C: 'a> From> - for Element<'a, Message> +impl<'a, Message, T, H: 'a, F: 'a, C: 'a, Theme, Renderer> From> + for Element<'a, Message, Theme, Renderer> where Message: 'a, + Renderer: 'a + advanced::Renderer, + Theme: 'a + iced::widget::button::StyleSheet, T: Into + Clone + 'a, - H: Fn() -> Button<'a, Event>, - F: Fn() -> Button<'a, Event>, - C: Fn() -> Element<'a, T>, + H: Fn() -> Button<'a, Event, Theme, Renderer>, + F: Fn() -> Button<'a, Event, Theme, Renderer>, + C: Fn() -> Element<'a, T, Theme, Renderer>, { fn from(c: Collapse<'a, Message, H, F, C>) -> Self { component(c) diff --git a/gui/ui/src/component/event.rs b/gui/ui/src/component/event.rs index 2544996e..1ee62995 100644 --- a/gui/ui/src/component/event.rs +++ b/gui/ui/src/component/event.rs @@ -2,7 +2,6 @@ use crate::{ color, component::{amount, badge, text}, theme, - util::Collection, widget::*, }; use bitcoin::Amount; @@ -12,7 +11,7 @@ use iced::{ }; pub fn unconfirmed_outgoing_event<'a, T: Clone + 'a>( - label: Option>>, + label: Option>, amount: &Amount, msg: T, ) -> Container<'a, T> { @@ -39,7 +38,7 @@ pub fn unconfirmed_outgoing_event<'a, T: Clone + 'a>( } pub fn confirmed_outgoing_event<'a, T: Clone + 'a>( - label: Option>>, + label: Option>, date: chrono::NaiveDateTime, amount: &Amount, msg: T, @@ -72,7 +71,7 @@ pub fn confirmed_outgoing_event<'a, T: Clone + 'a>( } pub fn unconfirmed_incoming_event<'a, T: Clone + 'a>( - label: Option>>, + label: Option>, amount: &Amount, msg: T, ) -> Container<'a, T> { @@ -99,7 +98,7 @@ pub fn unconfirmed_incoming_event<'a, T: Clone + 'a>( } pub fn confirmed_incoming_event<'a, T: Clone + 'a>( - label: Option>>, + label: Option>, date: chrono::NaiveDateTime, amount: &Amount, msg: T, diff --git a/gui/ui/src/component/form.rs b/gui/ui/src/component/form.rs index 1ff274c5..b2017be0 100644 --- a/gui/ui/src/component/form.rs +++ b/gui/ui/src/component/form.rs @@ -1,7 +1,7 @@ use bitcoin::Denomination; use iced::{widget::text_input, Length}; -use crate::{color, component::text, theme, util::Collection, widget::*}; +use crate::{color, component::text, theme, widget::*}; #[derive(Debug, Clone)] pub struct Value { @@ -19,7 +19,7 @@ impl std::default::Default for Value { } pub struct Form<'a, Message> { - input: text_input::TextInput<'a, Message, iced::Renderer>, + input: TextInput<'a, Message>, warning: Option<&'a str>, valid: bool, } diff --git a/gui/ui/src/component/hw.rs b/gui/ui/src/component/hw.rs index 534d4872..d2b9978e 100644 --- a/gui/ui/src/component/hw.rs +++ b/gui/ui/src/component/hw.rs @@ -1,4 +1,4 @@ -use crate::{color, component::text, icon, image, theme, util::*, widget::*}; +use crate::{color, component::text, icon, image, theme, widget::*}; use iced::{ widget::{column, container, row, tooltip}, Alignment, Length, diff --git a/gui/ui/src/component/modal.rs b/gui/ui/src/component/modal.rs index 56592b04..cb0b823e 100644 --- a/gui/ui/src/component/modal.rs +++ b/gui/ui/src/component/modal.rs @@ -7,20 +7,20 @@ use iced::advanced::{self, Clipboard, Shell}; use iced::alignment::Alignment; use iced::event; use iced::mouse; -use iced::{Color, Element, Event, Length, Point, Rectangle, Size}; +use iced::{Color, Element, Event, Length, Point, Rectangle, Size, Vector}; /// A widget that centers a modal element over some base element -pub struct Modal<'a, Message, Renderer> { - base: Element<'a, Message, Renderer>, - modal: Element<'a, Message, Renderer>, +pub struct Modal<'a, Message, Theme, Renderer> { + base: Element<'a, Message, Theme, Renderer>, + modal: Element<'a, Message, Theme, Renderer>, on_blur: Option, } -impl<'a, Message, Renderer> Modal<'a, Message, Renderer> { +impl<'a, Message, Theme, Renderer> Modal<'a, Message, Theme, Renderer> { /// Returns a new [`Modal`] pub fn new( - base: impl Into>, - modal: impl Into>, + base: impl Into>, + modal: impl Into>, ) -> Self { Self { base: base.into(), @@ -36,7 +36,8 @@ impl<'a, Message, Renderer> Modal<'a, Message, Renderer> { } } -impl<'a, Message, Renderer> Widget for Modal<'a, Message, Renderer> +impl<'a, Message, Theme, Renderer> Widget + for Modal<'a, Message, Theme, Renderer> where Renderer: advanced::Renderer, Message: Clone, @@ -49,16 +50,19 @@ where tree.diff_children(&[&self.base, &self.modal]); } - fn width(&self) -> Length { - self.base.as_widget().width() + fn size(&self) -> Size { + self.base.as_widget().size() } - fn height(&self) -> Length { - self.base.as_widget().height() - } - - fn layout(&self, renderer: &Renderer, limits: &layout::Limits) -> layout::Node { - self.base.as_widget().layout(renderer, limits) + fn layout( + &self, + tree: &mut widget::Tree, + renderer: &Renderer, + limits: &layout::Limits, + ) -> layout::Node { + self.base + .as_widget() + .layout(&mut tree.children[0], renderer, limits) } fn on_event( @@ -88,7 +92,7 @@ where &self, state: &widget::Tree, renderer: &mut Renderer, - theme: &::Theme, + theme: &Theme, style: &renderer::Style, layout: Layout<'_>, cursor: mouse::Cursor, @@ -110,16 +114,15 @@ where state: &'b mut Tree, layout: Layout<'_>, _renderer: &Renderer, - ) -> Option> { - Some(overlay::Element::new( - layout.position(), - Box::new(Overlay { - content: &mut self.modal, - tree: &mut state.children[1], - size: layout.bounds().size(), - on_blur: self.on_blur.clone(), - }), - )) + translation: Vector, + ) -> Option> { + Some(overlay::Element::new(Box::new(Overlay { + position: layout.position() + translation, + content: &mut self.modal, + tree: &mut state.children[1], + size: layout.bounds().size(), + on_blur: self.on_blur.clone(), + }))) } fn mouse_interaction( @@ -152,31 +155,32 @@ where } } -struct Overlay<'a, 'b, Message, Renderer> { - content: &'b mut Element<'a, Message, Renderer>, +struct Overlay<'a, 'b, Message, Theme, Renderer> { + position: Point, + content: &'b mut Element<'a, Message, Theme, Renderer>, tree: &'b mut Tree, size: Size, on_blur: Option, } -impl<'a, 'b, Message, Renderer> overlay::Overlay - for Overlay<'a, 'b, Message, Renderer> +impl<'a, 'b, Message, Theme, Renderer> overlay::Overlay + for Overlay<'a, 'b, Message, Theme, Renderer> where Renderer: advanced::Renderer, Message: Clone, { - fn layout(&self, renderer: &Renderer, _bounds: Size, position: Point) -> layout::Node { + fn layout(&mut self, renderer: &Renderer, _bounds: Size) -> layout::Node { let limits = layout::Limits::new(Size::ZERO, self.size) .width(Length::Fill) .height(Length::Fill); - let mut child = self.content.as_widget().layout(renderer, &limits); - child.align(Alignment::Center, Alignment::Center, limits.max()); + let child = self + .content + .as_widget() + .layout(self.tree, renderer, &limits) + .align(Alignment::Center, Alignment::Center, limits.max()); - let mut node = layout::Node::with_children(self.size, vec![child]); - node.move_to(position); - - node + layout::Node::with_children(self.size, vec![child]).move_to(self.position) } fn on_event( @@ -214,7 +218,7 @@ where fn draw( &self, renderer: &mut Renderer, - theme: &Renderer::Theme, + theme: &Theme, style: &renderer::Style, layout: Layout<'_>, cursor: mouse::Cursor, @@ -222,9 +226,7 @@ where renderer.fill_quad( renderer::Quad { bounds: layout.bounds(), - border_radius: Default::default(), - border_width: 0.0, - border_color: Color::TRANSPARENT, + ..renderer::Quad::default() }, Color { a: 0.80, @@ -277,19 +279,24 @@ where &'c mut self, layout: Layout<'_>, renderer: &Renderer, - ) -> Option> { - self.content - .as_widget_mut() - .overlay(self.tree, layout.children().next().unwrap(), renderer) + ) -> Option> { + self.content.as_widget_mut().overlay( + self.tree, + layout.children().next().unwrap(), + renderer, + Vector::ZERO, + ) } } -impl<'a, Message, Renderer> From> for Element<'a, Message, Renderer> +impl<'a, Message, Theme, Renderer> From> + for Element<'a, Message, Theme, Renderer> where Renderer: 'a + advanced::Renderer, Message: 'a + Clone, + Theme: 'a, { - fn from(modal: Modal<'a, Message, Renderer>) -> Self { + fn from(modal: Modal<'a, Message, Theme, Renderer>) -> Self { Element::new(modal) } } diff --git a/gui/ui/src/component/notification.rs b/gui/ui/src/component/notification.rs index ed6b5794..dff32e87 100644 --- a/gui/ui/src/component/notification.rs +++ b/gui/ui/src/component/notification.rs @@ -5,7 +5,6 @@ use crate::{ color, component::{collapse, text}, icon, theme, - util::*, widget::*, }; use iced::{ diff --git a/gui/ui/src/component/text.rs b/gui/ui/src/component/text.rs index 7fe71479..b5df3a6c 100644 --- a/gui/ui/src/component/text.rs +++ b/gui/ui/src/component/text.rs @@ -18,105 +18,85 @@ pub const P2_SIZE: u16 = 17; // 12 * 1.2 pub const CAPTION_SIZE: u16 = 15; -pub fn h1<'a>(content: impl Into>) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h1<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::BOLD) .size(H1_SIZE) } -pub fn h2<'a>(content: impl Into>) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h2<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::BOLD) .size(H2_SIZE) } -pub fn h3<'a>(content: impl Into>) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h3<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::BOLD) .size(H3_SIZE) } -pub fn h4_bold<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h4_bold<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::BOLD) .size(H4_SIZE) } -pub fn h4_regular<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h4_regular<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::REGULAR) .size(H4_SIZE) } -pub fn h5_medium<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h5_medium<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::MEDIUM) .size(H5_SIZE) } -pub fn h5_regular<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn h5_regular<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::REGULAR) .size(H5_SIZE) } -pub fn p1_bold<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn p1_bold<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::BOLD) .size(P1_SIZE) } -pub fn p1_medium<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn p1_medium<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::MEDIUM) .size(P1_SIZE) } -pub fn p1_regular<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn p1_regular<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::REGULAR) .size(P1_SIZE) } -pub fn p2_medium<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn p2_medium<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::MEDIUM) .size(P2_SIZE) } -pub fn p2_regular<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn p2_regular<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::REGULAR) .size(P2_SIZE) } -pub fn caption<'a>( - content: impl Into>, -) -> iced::widget::Text<'a, iced::Renderer> { +pub fn caption<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { iced::widget::Text::new(content) .font(font::REGULAR) .size(CAPTION_SIZE) } -pub fn text<'a>(content: impl Into>) -> iced::widget::Text<'a, iced::Renderer> { +pub fn text<'a>(content: impl Into>) -> iced::widget::Text<'a, Theme> { p1_regular(content) } @@ -125,7 +105,7 @@ pub trait Text { fn small(self) -> Self; } -impl Text for iced::widget::Text<'_, iced::Renderer> { +impl Text for iced::widget::Text<'_, Theme> { fn bold(self) -> Self { self.font(font::BOLD) } diff --git a/gui/ui/src/component/toast.rs b/gui/ui/src/component/toast.rs index d6dca6a5..7da518cf 100644 --- a/gui/ui/src/component/toast.rs +++ b/gui/ui/src/component/toast.rs @@ -1,7 +1,5 @@ use std::time::Instant; -use super::theme::Theme; - use iced::advanced::widget::{Operation, Tree}; use iced::advanced::{layout, mouse, overlay, renderer}; use iced::advanced::{Clipboard, Layout, Shell, Widget}; @@ -13,18 +11,18 @@ pub trait Toast { fn body(&self) -> &str; } -pub struct Manager<'a, Message, Renderer> { - content: Element<'a, Message, Renderer>, - toasts: Vec>, +pub struct Manager<'a, Message, Theme, Renderer> { + content: Element<'a, Message, Theme, Renderer>, + toasts: Vec>, } -impl<'a, Message> Manager<'a, Message, iced::Renderer> +impl<'a, Message, Theme> Manager<'a, Message, Theme, iced::Renderer> where Message: 'a + Clone, { pub fn new( - content: impl Into>>, - toasts: Vec>>, + content: impl Into>, + toasts: Vec>, ) -> Self { Self { content: content.into(), @@ -33,20 +31,24 @@ where } } -impl<'a, Message, Renderer> Widget for Manager<'a, Message, Renderer> +impl<'a, Message, Theme, Renderer> Widget + for Manager<'a, Message, Theme, Renderer> where Renderer: iced::advanced::Renderer, { - fn width(&self) -> Length { - self.content.as_widget().width() + fn size(&self) -> Size { + self.content.as_widget().size() } - fn height(&self) -> Length { - self.content.as_widget().height() - } - - fn layout(&self, renderer: &Renderer, limits: &layout::Limits) -> layout::Node { - self.content.as_widget().layout(renderer, limits) + fn layout( + &self, + tree: &mut Tree, + renderer: &Renderer, + limits: &layout::Limits, + ) -> layout::Node { + self.content + .as_widget() + .layout(&mut tree.children[0], renderer, limits) } fn tag(&self) -> iced::advanced::widget::tree::Tag { @@ -130,7 +132,7 @@ where &self, state: &Tree, renderer: &mut Renderer, - theme: &::Theme, + theme: &Theme, style: &renderer::Style, layout: Layout<'_>, cursor_position: iced::mouse::Cursor, @@ -169,25 +171,26 @@ where state: &'b mut Tree, layout: Layout<'_>, renderer: &Renderer, - ) -> Option> { + translation: Vector, + ) -> Option> { let instants = state.state.downcast_mut::>>(); let (content_state, toasts_state) = state.children.split_at_mut(1); - let content = self - .content - .as_widget_mut() - .overlay(&mut content_state[0], layout, renderer); + let content = self.content.as_widget_mut().overlay( + &mut content_state[0], + layout, + renderer, + translation, + ); let toasts = (!self.toasts.is_empty()).then(|| { - overlay::Element::new( - layout.bounds().position(), - Box::new(Overlay { - toasts: &mut self.toasts, - state: toasts_state, - instants, - }), - ) + overlay::Element::new(Box::new(Overlay { + position: layout.bounds().position() + translation, + toasts: &mut self.toasts, + state: toasts_state, + instants, + })) }); let overlays = content.into_iter().chain(toasts).collect::>(); @@ -195,18 +198,19 @@ where } } -struct Overlay<'a, 'b, Message, Renderer> { - toasts: &'b mut [Element<'a, Message, Renderer>], +struct Overlay<'a, 'b, Message, Theme, Renderer> { + position: Point, + toasts: &'b mut [Element<'a, Message, Theme, Renderer>], state: &'b mut [Tree], instants: &'b mut [Option], } -impl<'a, 'b, Message, Renderer> overlay::Overlay - for Overlay<'a, 'b, Message, Renderer> +impl<'a, 'b, Message, Theme, Renderer> overlay::Overlay + for Overlay<'a, 'b, Message, Theme, Renderer> where Renderer: iced::advanced::Renderer, { - fn layout(&self, renderer: &Renderer, bounds: Size, position: Point) -> layout::Node { + fn layout(&mut self, renderer: &Renderer, bounds: Size) -> layout::Node { let limits = layout::Limits::new(Size::ZERO, bounds) .width(Length::Fill) .height(Length::Fill); @@ -215,12 +219,15 @@ where layout::flex::Axis::Vertical, renderer, &limits, + Length::Fill, + Length::Fill, 10.into(), 10.0, Alignment::End, self.toasts, + self.state, ) - .translate(Vector::new(position.x, position.y)) + .translate(Vector::new(self.position.x, self.position.y)) } fn on_event( @@ -267,7 +274,7 @@ where fn draw( &self, renderer: &mut Renderer, - theme: &::Theme, + theme: &Theme, style: &renderer::Style, layout: Layout<'_>, cursor_position: iced::mouse::Cursor, @@ -342,12 +349,14 @@ where } } -impl<'a, Message, Renderer> From> for Element<'a, Message, Renderer> +impl<'a, Message, Theme, Renderer> From> + for Element<'a, Message, Theme, Renderer> where Renderer: 'a + iced::advanced::Renderer, Message: 'a, + Theme: 'a, { - fn from(manager: Manager<'a, Message, Renderer>) -> Self { + fn from(manager: Manager<'a, Message, Theme, Renderer>) -> Self { Element::new(manager) } } diff --git a/gui/ui/src/font.rs b/gui/ui/src/font.rs index f055ebce..c06fd76e 100644 --- a/gui/ui/src/font.rs +++ b/gui/ui/src/font.rs @@ -6,14 +6,14 @@ use iced::{ pub const BOLD: Font = Font { family: Family::Name("IBM Plex Sans"), weight: Weight::Bold, - monospaced: false, + style: iced::font::Style::Normal, stretch: Stretch::Normal, }; pub const MEDIUM: Font = Font { family: Family::Name("IBM Plex Sans"), weight: Weight::Medium, - monospaced: false, + style: iced::font::Style::Normal, stretch: Stretch::Normal, }; diff --git a/gui/ui/src/lib.rs b/gui/ui/src/lib.rs index 213df10f..b6fa8392 100644 --- a/gui/ui/src/lib.rs +++ b/gui/ui/src/lib.rs @@ -4,22 +4,24 @@ pub mod font; pub mod icon; pub mod image; pub mod theme; -pub mod util; pub mod widget { #![allow(dead_code)] use crate::theme::Theme; - pub type Renderer = iced::Renderer; - pub type Element<'a, Message> = iced::Element<'a, Message, Renderer>; - pub type Container<'a, Message> = iced::widget::Container<'a, Message, Renderer>; - pub type Column<'a, Message> = iced::widget::Column<'a, Message, Renderer>; - pub type Row<'a, Message> = iced::widget::Row<'a, Message, Renderer>; - pub type Button<'a, Message> = iced::widget::Button<'a, Message, Renderer>; - pub type Text<'a> = iced::widget::Text<'a, Renderer>; - pub type Tooltip<'a> = iced::widget::Tooltip<'a, Renderer>; - pub type ProgressBar = iced::widget::ProgressBar; - pub type PickList<'a, Message> = iced::widget::PickList<'a, Message, Renderer>; - pub type Scrollable<'a, Message> = iced::widget::Scrollable<'a, Message, Renderer>; - pub type Svg = iced::widget::Svg; + pub type Renderer = iced::Renderer; + pub type Element<'a, Message> = iced::Element<'a, Message, Theme, Renderer>; + pub type Container<'a, Message> = iced::widget::Container<'a, Message, Theme, Renderer>; + pub type Column<'a, Message> = iced::widget::Column<'a, Message, Theme, Renderer>; + pub type Row<'a, Message> = iced::widget::Row<'a, Message, Theme, Renderer>; + pub type Button<'a, Message> = iced::widget::Button<'a, Message, Theme, Renderer>; + pub type CheckBox<'a, Message> = iced::widget::Checkbox<'a, Message, Theme, Renderer>; + pub type Text<'a> = iced::widget::Text<'a, Theme, Renderer>; + pub type TextInput<'a, Message> = iced::widget::TextInput<'a, Message, Theme, Renderer>; + pub type Tooltip<'a> = iced::widget::Tooltip<'a, Theme, Renderer>; + pub type ProgressBar = iced::widget::ProgressBar; + pub type PickList<'a, T, L, V, Message> = + iced::widget::PickList<'a, T, L, V, Message, Theme, Renderer>; + pub type Scrollable<'a, Message> = iced::widget::Scrollable<'a, Message, Theme, Renderer>; + pub type Svg = iced::widget::Svg; } diff --git a/gui/ui/src/theme.rs b/gui/ui/src/theme.rs index 998cd2da..746dd951 100644 --- a/gui/ui/src/theme.rs +++ b/gui/ui/src/theme.rs @@ -1,8 +1,8 @@ use iced::{ application, widget::{ - button, checkbox, container, pick_list, progress_bar, radio, scrollable, slider, svg, text, - text_input, + button, checkbox, container, pick_list, progress_bar, qr_code, radio, scrollable, slider, + svg, text, text_input, }, }; @@ -44,9 +44,11 @@ impl iced::overlay::menu::StyleSheet for Theme { iced::overlay::menu::Appearance { text_color: color::GREY_2, background: color::GREY_6.into(), - border_width: 0.0, - border_radius: 25.0.into(), - border_color: color::GREY_2, + border: iced::Border { + color: color::GREY_2, + width: 0.0, + radius: 25.0.into(), + }, selected_text_color: color::LIGHT_BLACK, selected_background: color::GREEN.into(), } @@ -116,8 +118,11 @@ impl container::StyleSheet for Theme { }, Container::Border => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_width: 1.0, - border_color: color::LIGHT_BLACK, + border: iced::Border { + color: color::LIGHT_BLACK, + width: 1.0, + radius: 0.0.into(), + }, ..container::Appearance::default() }, Container::Card(c) => c.appearance(self), @@ -130,7 +135,11 @@ impl container::StyleSheet for Theme { }, Container::QrCode => container::Appearance { background: Some(color::WHITE.into()), - border_radius: 25.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, ..container::Appearance::default() }, }, @@ -149,8 +158,11 @@ impl container::StyleSheet for Theme { }, Container::Border => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_width: 1.0, - border_color: color::GREY_3, + border: iced::Border { + color: color::GREY_3, + width: 1.0, + radius: 0.0.into(), + }, ..container::Appearance::default() }, Container::Card(c) => c.appearance(self), @@ -163,7 +175,11 @@ impl container::StyleSheet for Theme { }, Container::QrCode => container::Appearance { background: Some(color::WHITE.into()), - border_radius: 25.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, ..container::Appearance::default() }, }, @@ -203,32 +219,44 @@ impl Notification { Self::Pending => container::Appearance { background: Some(iced::Background::Color(color::GREEN)), text_color: color::LIGHT_BLACK.into(), - border_width: 1.0, - border_color: color::GREEN, - border_radius: 25.0.into(), + border: iced::Border { + color: color::GREEN, + width: 1.0, + radius: 25.0.into(), + }, + ..container::Appearance::default() }, Self::Error => container::Appearance { background: Some(iced::Background::Color(color::ORANGE)), text_color: color::LIGHT_BLACK.into(), - border_width: 1.0, - border_color: color::ORANGE, - border_radius: 25.0.into(), + border: iced::Border { + color: color::ORANGE, + width: 1.0, + radius: 25.0.into(), + }, + ..container::Appearance::default() }, }, Theme::Dark => match self { Self::Pending => container::Appearance { background: Some(iced::Background::Color(color::GREEN)), text_color: color::LIGHT_BLACK.into(), - border_width: 1.0, - border_color: color::GREEN, - border_radius: 25.0.into(), + border: iced::Border { + color: color::GREEN, + width: 1.0, + radius: 25.0.into(), + }, + ..container::Appearance::default() }, Self::Error => container::Appearance { background: Some(iced::Background::Color(color::ORANGE)), text_color: color::LIGHT_BLACK.into(), - border_width: 1.0, - border_color: color::ORANGE, - border_radius: 25.0.into(), + border: iced::Border { + color: color::ORANGE, + width: 1.0, + radius: 25.0.into(), + }, + ..container::Appearance::default() }, }, } @@ -255,23 +283,31 @@ impl Card { }, Card::Border => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 10.0.into(), - border_color: color::GREY_2, - border_width: 1.0, + border: iced::Border { + color: color::GREY_2, + width: 1.0, + radius: 10.0.into(), + }, ..container::Appearance::default() }, Card::Invalid => container::Appearance { background: Some(color::GREY_2.into()), text_color: color::BLACK.into(), - border_width: 1.0, - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 0.0.into(), + }, ..container::Appearance::default() }, Card::Error => container::Appearance { background: Some(color::GREY_2.into()), text_color: color::RED.into(), - border_width: 1.0, - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 0.0.into(), + }, ..container::Appearance::default() }, Card::Warning => container::Appearance { @@ -283,28 +319,40 @@ impl Card { Theme::Dark => match self { Card::Simple => container::Appearance { background: Some(color::GREY_6.into()), - border_radius: 25.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, ..container::Appearance::default() }, Card::Border => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_color: color::GREY_5, - border_width: 1.0, + border: iced::Border { + color: color::GREY_5, + width: 1.0, + radius: 25.0.into(), + }, ..container::Appearance::default() }, Card::Invalid => container::Appearance { background: Some(color::LIGHT_BLACK.into()), text_color: color::RED.into(), - border_width: 1.0, - border_radius: 25.0.into(), - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, + ..container::Appearance::default() }, Card::Error => container::Appearance { background: Some(color::LIGHT_BLACK.into()), text_color: color::RED.into(), - border_width: 1.0, - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, ..container::Appearance::default() }, Card::Warning => container::Appearance { @@ -328,12 +376,20 @@ impl Badge { fn appearance(&self, _theme: &Theme) -> iced::widget::container::Appearance { match self { Self::Standard => container::Appearance { - border_radius: 40.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 40.0.into(), + }, background: Some(color::GREY_4.into()), ..container::Appearance::default() }, Self::Bitcoin => container::Appearance { - border_radius: 40.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 40.0.into(), + }, background: Some(color::ORANGE.into()), text_color: iced::Color::WHITE.into(), ..container::Appearance::default() @@ -356,29 +412,43 @@ impl Pill { match self { Self::Primary => container::Appearance { background: Some(color::GREEN.into()), - border_radius: 25.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, text_color: color::LIGHT_BLACK.into(), ..container::Appearance::default() }, Self::Success => container::Appearance { background: Some(color::GREEN.into()), - border_radius: 25.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, text_color: color::LIGHT_BLACK.into(), ..container::Appearance::default() }, Self::Simple => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::GREY_3, + border: iced::Border { + color: color::GREY_3, + width: 1.0, + radius: 25.0.into(), + }, text_color: color::GREY_3.into(), + ..container::Appearance::default() }, Self::Warning => container::Appearance { background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, text_color: color::RED.into(), + ..container::Appearance::default() }, } } @@ -415,24 +485,32 @@ pub struct Scrollable {} impl scrollable::StyleSheet for Theme { type Style = Scrollable; - fn active(&self, _style: &Self::Style) -> scrollable::Scrollbar { - scrollable::Scrollbar { - background: None, - border_width: 0.0, - border_color: color::GREY_7, - border_radius: 10.0.into(), - scroller: scrollable::Scroller { - color: color::GREY_7, - border_radius: 10.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, + fn active(&self, _style: &Self::Style) -> scrollable::Appearance { + scrollable::Appearance { + gap: None, + container: container::Appearance::default(), + scrollbar: scrollable::Scrollbar { + background: None, + border: iced::Border { + color: color::GREY_3, + width: 0.0, + radius: 10.0.into(), + }, + scroller: scrollable::Scroller { + color: color::GREY_7, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 10.0.into(), + }, + }, }, } } - fn hovered(&self, style: &Self::Style, _is_hovered: bool) -> scrollable::Scrollbar { + fn hovered(&self, style: &Self::Style, _is_hovered: bool) -> scrollable::Appearance { let active = self.active(style); - scrollable::Scrollbar { ..active } + scrollable::Appearance { ..active } } } @@ -452,27 +530,33 @@ impl pick_list::StyleSheet for Theme { placeholder_color: color::GREY_6, handle_color: color::GREY_6, background: color::GREEN.into(), - border_width: 1.0, - border_color: color::GREY_7, - border_radius: 25.0.into(), + border: iced::Border { + color: color::GREY_7, + width: 1.0, + radius: 25.0.into(), + }, text_color: iced::Color::BLACK, }, PickList::Invalid => pick_list::Appearance { placeholder_color: color::GREY_6, handle_color: color::GREY_6, background: color::GREY_6.into(), - border_width: 1.0, - border_color: color::RED, - border_radius: 25.0.into(), + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, text_color: color::RED, }, PickList::Secondary => pick_list::Appearance { placeholder_color: color::GREY_3, handle_color: color::GREY_3, background: color::TRANSPARENT.into(), - border_width: 1.0, - border_color: color::GREY_3, - border_radius: 25.0.into(), + border: iced::Border { + color: color::GREY_3, + width: 1.0, + radius: 25.0.into(), + }, text_color: color::GREY_2, }, } @@ -493,20 +577,24 @@ impl checkbox::StyleSheet for Theme { if is_selected { checkbox::Appearance { background: color::GREEN.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, icon_color: color::GREY_4, text_color: None, - border_radius: 4.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 1.0, + radius: 4.0.into(), + }, } } else { checkbox::Appearance { background: color::GREY_4.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, icon_color: color::GREEN, text_color: None, - border_radius: 4.0.into(), + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 4.0.into(), + }, } } } @@ -539,63 +627,84 @@ impl button::StyleSheet for Theme { Button::Primary => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::GREY_7, text_color: color::GREY_2, + border: iced::Border { + color: color::GREY_7, + width: 1.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Secondary | Button::SecondaryDestructive | Button::Border => { button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::GREY_7, text_color: color::GREY_2, + border: iced::Border { + color: color::GREY_7, + width: 1.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() } } Button::Destructive => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::RED, text_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Transparent => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::GREY_2, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::TransparentBorder => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::WHITE, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Menu(active) => { if *active { button::Appearance { shadow_offset: iced::Vector::default(), background: Some(color::LIGHT_BLACK.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::WHITE, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() } } else { button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::WHITE, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() } } } @@ -610,50 +719,68 @@ impl button::StyleSheet for Theme { Button::Primary => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(color::GREEN.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::LIGHT_BLACK, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Secondary => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(color::GREEN.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::LIGHT_BLACK, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Destructive | Button::SecondaryDestructive => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(color::RED.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::LIGHT_BLACK, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Transparent => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::GREY_2, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::TransparentBorder | Button::Border => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(iced::Color::TRANSPARENT.into()), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::GREEN, text_color: color::WHITE, + border: iced::Border { + color: color::GREEN, + width: 1.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, Button::Menu(_) => button::Appearance { shadow_offset: iced::Vector::default(), background: Some(color::LIGHT_BLACK.into()), - border_radius: 25.0.into(), - border_width: 0.0, - border_color: iced::Color::TRANSPARENT, text_color: color::WHITE, + border: iced::Border { + color: color::TRANSPARENT, + width: 0.0, + radius: 25.0.into(), + }, + ..button::Appearance::default() }, }, } @@ -674,16 +801,20 @@ impl text_input::StyleSheet for Theme { Form::Simple => text_input::Appearance { icon_color: color::GREY_7, background: iced::Background::Color(iced::Color::TRANSPARENT), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::GREY_7, + border: iced::Border { + color: color::GREY_7, + width: 1.0, + radius: 25.0.into(), + }, }, Form::Invalid => text_input::Appearance { icon_color: color::GREY_7, background: iced::Background::Color(iced::Color::TRANSPARENT), - border_radius: 25.0.into(), - border_width: 1.0, - border_color: color::RED, + border: iced::Border { + color: color::RED, + width: 1.0, + radius: 25.0.into(), + }, }, } } @@ -813,3 +944,13 @@ impl svg::StyleSheet for Theme { svg::Appearance::default() } } + +impl qr_code::StyleSheet for Theme { + type Style = (); + fn appearance(&self, _style: &Self::Style) -> qr_code::Appearance { + qr_code::Appearance { + cell: color::BLACK, + background: color::WHITE, + } + } +} diff --git a/gui/ui/src/util.rs b/gui/ui/src/util.rs deleted file mode 100644 index 2553c2c9..00000000 --- a/gui/ui/src/util.rs +++ /dev/null @@ -1,25 +0,0 @@ -/// from hecjr idea on Discord -use crate::widget::*; - -pub trait Collection<'a, Message>: Sized { - fn push(self, element: impl Into>) -> Self; - - fn push_maybe(self, element: Option>>) -> Self { - match element { - Some(element) => self.push(element), - None => self, - } - } -} - -impl<'a, Message> Collection<'a, Message> for Column<'a, Message> { - fn push(self, element: impl Into>) -> Self { - Self::push(self, element) - } -} - -impl<'a, Message> Collection<'a, Message> for Row<'a, Message> { - fn push(self, element: impl Into>) -> Self { - Self::push(self, element) - } -}