commit
f1ed99cb47
155 changed files with 225 additions and 241 deletions
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
|
|
@ -8,7 +8,7 @@ jobs:
|
|||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macOS-latest]
|
||||
rust: [stable, beta, "1.82"]
|
||||
rust: [stable, beta, "1.85"]
|
||||
steps:
|
||||
- uses: hecrj/setup-rust-action@v2
|
||||
with:
|
||||
|
|
|
|||
|
|
@ -122,13 +122,13 @@ members = [
|
|||
[workspace.package]
|
||||
version = "0.14.0-dev"
|
||||
authors = ["Héctor Ramón Jiménez <hector@hecrj.dev>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
license = "MIT"
|
||||
repository = "https://github.com/iced-rs/iced"
|
||||
homepage = "https://iced.rs"
|
||||
categories = ["gui"]
|
||||
keywords = ["gui", "ui", "graphics", "interface", "widgets"]
|
||||
rust-version = "1.82"
|
||||
rust-version = "1.85"
|
||||
|
||||
[workspace.dependencies]
|
||||
iced = { version = "0.14.0-dev", path = "." }
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
#![allow(missing_docs)]
|
||||
use criterion::{criterion_group, criterion_main, Bencher, Criterion};
|
||||
use criterion::{Bencher, Criterion, criterion_group, criterion_main};
|
||||
|
||||
use iced::alignment;
|
||||
use iced::mouse;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use crate::gradient::{self, Gradient};
|
||||
use crate::Color;
|
||||
use crate::gradient::{self, Gradient};
|
||||
|
||||
/// The background of some element.
|
||||
#[derive(Debug, Clone, Copy, PartialEq)]
|
||||
|
|
|
|||
|
|
@ -227,12 +227,8 @@ macro_rules! color {
|
|||
($r:expr, $g:expr, $b:expr) => {
|
||||
$crate::Color::from_rgb8($r, $g, $b)
|
||||
};
|
||||
($r:expr, $g:expr, $b:expr, $a:expr) => {{
|
||||
$crate::Color::from_rgba8($r, $g, $b, $a)
|
||||
}};
|
||||
($hex:expr) => {{
|
||||
$crate::color!($hex, 1.0)
|
||||
}};
|
||||
($r:expr, $g:expr, $b:expr, $a:expr) => {{ $crate::Color::from_rgba8($r, $g, $b, $a) }};
|
||||
($hex:expr) => {{ $crate::color!($hex, 1.0) }};
|
||||
($hex:expr, $a:expr) => {{
|
||||
let hex = $hex as u32;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use crate::SmolStr;
|
||||
use crate::keyboard::key;
|
||||
use crate::keyboard::{Key, Location, Modifiers};
|
||||
use crate::SmolStr;
|
||||
|
||||
/// A keyboard event.
|
||||
///
|
||||
|
|
|
|||
|
|
@ -1252,7 +1252,7 @@ impl PartialEq<Code> for Physical {
|
|||
#[inline]
|
||||
fn eq(&self, rhs: &Code) -> bool {
|
||||
match self {
|
||||
Physical::Code(ref code) => code == rhs,
|
||||
Physical::Code(code) => code == rhs,
|
||||
Physical::Unidentified(_) => false,
|
||||
}
|
||||
}
|
||||
|
|
@ -1269,7 +1269,7 @@ impl PartialEq<NativeCode> for Physical {
|
|||
#[inline]
|
||||
fn eq(&self, rhs: &NativeCode) -> bool {
|
||||
match self {
|
||||
Physical::Unidentified(ref code) => code == rhs,
|
||||
Physical::Unidentified(code) => code == rhs,
|
||||
Physical::Code(_) => false,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use crate::InputMethod;
|
||||
use crate::event;
|
||||
use crate::window;
|
||||
use crate::InputMethod;
|
||||
|
||||
/// A connection to the state of a shell.
|
||||
///
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//! Define the colors of a theme.
|
||||
use crate::{color, Color};
|
||||
use crate::{Color, color};
|
||||
|
||||
use palette::color_difference::Wcag21RelativeContrast;
|
||||
use palette::rgb::Rgb;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
//! Operate on widgets that can be focused.
|
||||
use crate::widget::operation::{self, Operation, Outcome};
|
||||
use crate::widget::Id;
|
||||
use crate::Rectangle;
|
||||
use crate::widget::Id;
|
||||
use crate::widget::operation::{self, Operation, Outcome};
|
||||
|
||||
/// The internal state of a widget that can be focused.
|
||||
pub trait Focusable {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
//! Operate on widgets that have text input.
|
||||
use crate::widget::operation::Operation;
|
||||
use crate::widget::Id;
|
||||
use crate::Rectangle;
|
||||
use crate::widget::Id;
|
||||
use crate::widget::operation::Operation;
|
||||
|
||||
/// The internal state of a widget that has text input.
|
||||
pub trait TextInput {
|
||||
|
|
|
|||
|
|
@ -304,7 +304,7 @@ where
|
|||
let size = size.unwrap_or_else(|| renderer.default_size());
|
||||
let font = font.unwrap_or_else(|| renderer.default_font());
|
||||
|
||||
let State(ref mut paragraph) = state;
|
||||
let State(paragraph) = state;
|
||||
|
||||
paragraph.update(text::Text {
|
||||
content,
|
||||
|
|
|
|||
|
|
@ -24,8 +24,8 @@ mod platform;
|
|||
#[path = "settings/other.rs"]
|
||||
mod platform;
|
||||
|
||||
use crate::window::{Icon, Level, Position};
|
||||
use crate::Size;
|
||||
use crate::window::{Icon, Level, Position};
|
||||
|
||||
pub use platform::PlatformSpecific;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "arc"
|
||||
version = "0.1.0"
|
||||
authors = ["ThatsNoMoon <git@thatsnomoon.dev>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ use std::{f32::consts::PI, time::Instant};
|
|||
|
||||
use iced::mouse;
|
||||
use iced::widget::canvas::{
|
||||
self, stroke, Cache, Canvas, Geometry, Path, Stroke,
|
||||
self, Cache, Canvas, Geometry, Path, Stroke, stroke,
|
||||
};
|
||||
use iced::window;
|
||||
use iced::{Element, Fill, Point, Rectangle, Renderer, Subscription, Theme};
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "bezier_tool"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "changelog"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[lints.clippy]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "checkbox"
|
||||
version = "0.1.0"
|
||||
authors = ["Casper Rogild Storm<casper@rogildstorm.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "clock"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
use iced::alignment;
|
||||
use iced::mouse;
|
||||
use iced::time::{self, milliseconds};
|
||||
use iced::widget::canvas::{stroke, Cache, Geometry, LineCap, Path, Stroke};
|
||||
use iced::widget::canvas::{Cache, Geometry, LineCap, Path, Stroke, stroke};
|
||||
use iced::widget::{canvas, container};
|
||||
use iced::{alignment, Radians};
|
||||
use iced::{
|
||||
Degrees, Element, Fill, Font, Point, Rectangle, Renderer, Size,
|
||||
Degrees, Element, Fill, Font, Point, Radians, Rectangle, Renderer, Size,
|
||||
Subscription, Theme, Vector,
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "color_palette"
|
||||
version = "0.1.0"
|
||||
authors = ["Clark Moody <clark@clarkmoody.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
use iced::alignment;
|
||||
use iced::mouse;
|
||||
use iced::widget::canvas::{self, Canvas, Frame, Geometry, Path};
|
||||
use iced::widget::{column, row, text, Slider};
|
||||
use iced::widget::{Slider, column, row, text};
|
||||
use iced::{
|
||||
Center, Color, Element, Fill, Font, Pixels, Point, Rectangle, Renderer,
|
||||
Size, Vector,
|
||||
};
|
||||
use palette::{convert::FromColor, rgb::Rgb, Darken, Hsl, Lighten, ShiftHue};
|
||||
use palette::{Darken, Hsl, Lighten, ShiftHue, convert::FromColor, rgb::Rgb};
|
||||
use std::marker::PhantomData;
|
||||
use std::ops::RangeInclusive;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "combo_box"
|
||||
version = "0.1.0"
|
||||
authors = ["Joao Freitas <jhff.15@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "counter"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::widget::{button, column, text, Column};
|
||||
use iced::Center;
|
||||
use iced::widget::{Column, button, column, text};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
iced::run("A cool counter", Counter::update, Counter::view)
|
||||
|
|
@ -43,7 +43,7 @@ impl Counter {
|
|||
mod tests {
|
||||
use super::*;
|
||||
use iced_test::selector::text;
|
||||
use iced_test::{simulator, Error};
|
||||
use iced_test::{Error, simulator};
|
||||
|
||||
#[test]
|
||||
fn it_counts() -> Result<(), Error> {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "custom_quad"
|
||||
version = "0.1.0"
|
||||
authors = ["Robert Krahn"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "custom_shader"
|
||||
version = "0.1.0"
|
||||
authors = ["Bingus <shankern@protonmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
iced.workspace = true
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use crate::scene::pipeline::Vertex;
|
||||
use crate::wgpu;
|
||||
|
||||
use glam::{vec2, vec3, Vec3};
|
||||
use rand::{thread_rng, Rng};
|
||||
use glam::{Vec3, vec2, vec3};
|
||||
use rand::{Rng, thread_rng};
|
||||
|
||||
/// A single instance of a cube.
|
||||
#[derive(Debug, Clone)]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "custom_widget"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "download_progress"
|
||||
version = "0.1.0"
|
||||
authors = ["Songtronix <contact@songtronix.com>", "Folyd <lyshuhow@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
use iced::futures::StreamExt;
|
||||
use iced::task::{sipper, Straw};
|
||||
use iced::task::{Straw, sipper};
|
||||
|
||||
use std::sync::Arc;
|
||||
|
||||
pub fn download(url: impl AsRef<str>) -> impl Straw<(), Progress, Error> {
|
||||
sipper(move |mut progress| async move {
|
||||
sipper(async move |mut progress| {
|
||||
let response = reqwest::get(url.as_ref()).await?;
|
||||
let total = response.content_length().ok_or(Error::NoContentLength)?;
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ mod download;
|
|||
use download::download;
|
||||
|
||||
use iced::task;
|
||||
use iced::widget::{button, center, column, progress_bar, text, Column};
|
||||
use iced::widget::{Column, button, center, column, progress_bar, text};
|
||||
use iced::{Center, Element, Function, Right, Task};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "editor"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector@hecrj.dev>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "events"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::event::{self, Event};
|
||||
use iced::widget::{button, center, checkbox, text, Column};
|
||||
use iced::widget::{Column, button, center, checkbox, text};
|
||||
use iced::window;
|
||||
use iced::{Center, Element, Fill, Subscription, Task};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
[package]
|
||||
name = "exit"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "ferris"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "gallery"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use bytes::Bytes;
|
||||
use serde::Deserialize;
|
||||
use sipper::{sipper, Straw};
|
||||
use sipper::{Straw, sipper};
|
||||
use tokio::task;
|
||||
|
||||
use std::fmt;
|
||||
|
|
@ -62,7 +62,7 @@ impl Image {
|
|||
}
|
||||
|
||||
pub fn download(self, size: Size) -> impl Straw<Rgba, Blurhash, Error> {
|
||||
sipper(move |mut sender| async move {
|
||||
sipper(async move |mut sender| {
|
||||
let client = reqwest::Client::new();
|
||||
|
||||
if let Size::Thumbnail { width, height } = size {
|
||||
|
|
|
|||
|
|
@ -7,15 +7,15 @@ mod civitai;
|
|||
use crate::civitai::{Error, Id, Image, Rgba, Size};
|
||||
|
||||
use iced::animation;
|
||||
use iced::time::{milliseconds, Instant};
|
||||
use iced::time::{Instant, milliseconds};
|
||||
use iced::widget::{
|
||||
button, center_x, container, horizontal_space, image, mouse_area, opaque,
|
||||
pop, row, scrollable, stack,
|
||||
};
|
||||
use iced::window;
|
||||
use iced::{
|
||||
color, Animation, ContentFit, Element, Fill, Function, Subscription, Task,
|
||||
Theme,
|
||||
Animation, ContentFit, Element, Fill, Function, Subscription, Task, Theme,
|
||||
color,
|
||||
};
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "game_of_life"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -196,7 +196,6 @@ mod grid {
|
|||
Color, Element, Fill, Point, Rectangle, Renderer, Size, Theme, Vector,
|
||||
};
|
||||
use rustc_hash::{FxHashMap, FxHashSet};
|
||||
use std::future::Future;
|
||||
use std::ops::RangeInclusive;
|
||||
|
||||
pub struct Grid {
|
||||
|
|
@ -261,7 +260,7 @@ mod grid {
|
|||
pub fn tick(
|
||||
&mut self,
|
||||
amount: usize,
|
||||
) -> Option<impl Future<Output = Message>> {
|
||||
) -> Option<impl Future<Output = Message> + use<>> {
|
||||
let tick = self.state.tick(amount)?;
|
||||
|
||||
self.last_queued_ticks = amount;
|
||||
|
|
@ -722,7 +721,8 @@ mod grid {
|
|||
fn tick(
|
||||
&mut self,
|
||||
amount: usize,
|
||||
) -> Option<impl Future<Output = Result<Life, TickError>>> {
|
||||
) -> Option<impl Future<Output = Result<Life, TickError>> + use<>>
|
||||
{
|
||||
if self.is_ticking {
|
||||
return None;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "geometry"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -47,10 +47,10 @@ mod rainbow {
|
|||
cursor: mouse::Cursor,
|
||||
_viewport: &Rectangle,
|
||||
) {
|
||||
use iced::advanced::Renderer as _;
|
||||
use iced::advanced::graphics::mesh::{
|
||||
self, Mesh, Renderer as _, SolidVertex2D,
|
||||
};
|
||||
use iced::advanced::Renderer as _;
|
||||
|
||||
let bounds = layout.bounds();
|
||||
|
||||
|
|
@ -152,8 +152,8 @@ mod rainbow {
|
|||
}
|
||||
}
|
||||
|
||||
use iced::widget::{center_x, center_y, column, scrollable};
|
||||
use iced::Element;
|
||||
use iced::widget::{center_x, center_y, column, scrollable};
|
||||
use rainbow::rainbow;
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
[package]
|
||||
name = "gradient"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ use iced::theme;
|
|||
use iced::widget::{
|
||||
checkbox, column, container, horizontal_space, row, slider, text,
|
||||
};
|
||||
use iced::{color, Center, Color, Element, Fill, Radians, Theme};
|
||||
use iced::{Center, Color, Element, Fill, Radians, Theme, color};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
tracing_subscriber::fmt::init();
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "integration"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -5,16 +5,16 @@ use controls::Controls;
|
|||
use scene::Scene;
|
||||
|
||||
use iced_wgpu::graphics::Viewport;
|
||||
use iced_wgpu::{wgpu, Engine, Renderer};
|
||||
use iced_wgpu::{Engine, Renderer, wgpu};
|
||||
use iced_winit::Clipboard;
|
||||
use iced_winit::conversion;
|
||||
use iced_winit::core::mouse;
|
||||
use iced_winit::core::renderer;
|
||||
use iced_winit::core::{Color, Font, Pixels, Size, Theme};
|
||||
use iced_winit::futures;
|
||||
use iced_winit::runtime::program;
|
||||
use iced_winit::runtime::Debug;
|
||||
use iced_winit::runtime::program;
|
||||
use iced_winit::winit;
|
||||
use iced_winit::Clipboard;
|
||||
|
||||
use winit::{
|
||||
event::WindowEvent,
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "layout"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -7,8 +7,8 @@ use iced::widget::{
|
|||
text, vertical_rule,
|
||||
};
|
||||
use iced::{
|
||||
color, Center, Element, Fill, Font, Length, Point, Rectangle, Renderer,
|
||||
Shrink, Subscription, Theme,
|
||||
Center, Element, Fill, Font, Length, Point, Rectangle, Renderer, Shrink,
|
||||
Subscription, Theme, color,
|
||||
};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "lazy"
|
||||
version = "0.1.0"
|
||||
authors = ["Nick Senger <dev@nsenger.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "loading_spinners"
|
||||
version = "0.1.0"
|
||||
authors = ["Nick Senger <dev@nsenger.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use iced::Point;
|
||||
|
||||
use lyon_algorithms::measure::PathMeasurements;
|
||||
use lyon_algorithms::path::{builder::NoAttributes, path::BuilderImpl, Path};
|
||||
use lyon_algorithms::path::{Path, builder::NoAttributes, path::BuilderImpl};
|
||||
|
||||
use std::sync::LazyLock;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "loupe"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -46,10 +46,10 @@ impl Loupe {
|
|||
}
|
||||
|
||||
mod loupe {
|
||||
use iced::advanced::Renderer as _;
|
||||
use iced::advanced::layout::{self, Layout};
|
||||
use iced::advanced::renderer;
|
||||
use iced::advanced::widget::{self, Widget};
|
||||
use iced::advanced::Renderer as _;
|
||||
use iced::mouse;
|
||||
use iced::{
|
||||
Color, Element, Length, Rectangle, Renderer, Size, Theme,
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "markdown"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
// Generated automatically by iced_fontello at build time.
|
||||
// Do not edit manually. Source: ../fonts/markdown-icons.toml
|
||||
// dcd2f0c969d603e2ee9237a4b70fa86b1a6e84d86f4689046d8fdd10440b06b9
|
||||
use iced::widget::{text, Text};
|
||||
use iced::Font;
|
||||
use iced::widget::{Text, text};
|
||||
|
||||
pub const FONT: &[u8] = include_bytes!("../fonts/markdown-icons.ttf");
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ mod icon;
|
|||
use iced::animation;
|
||||
use iced::clipboard;
|
||||
use iced::highlighter;
|
||||
use iced::time::{self, milliseconds, Instant};
|
||||
use iced::time::{self, Instant, milliseconds};
|
||||
use iced::widget::{
|
||||
self, button, center_x, container, horizontal_space, hover, image,
|
||||
markdown, pop, right, row, scrollable, text_editor, toggler,
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "modal"
|
||||
version = "0.1.0"
|
||||
authors = ["tarkah <admin@tarkah.dev>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "multi_window"
|
||||
version = "0.1.0"
|
||||
authors = ["Bingus <shankern@protonmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "multitouch"
|
||||
version = "0.1.0"
|
||||
authors = ["Artur Sapek <artur@kraken.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "pane_grid"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "pick_list"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "pokedex"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "progress_bar"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use iced::Element;
|
||||
use iced::widget::{
|
||||
center, center_x, checkbox, column, progress_bar, row, slider,
|
||||
vertical_slider,
|
||||
};
|
||||
use iced::Element;
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
iced::run("Progress Bar - Iced", Progress::update, Progress::view)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "qr_code"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "screenshot"
|
||||
version = "0.1.0"
|
||||
authors = ["Bingus <shankern@protonmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "scrollable"
|
||||
version = "0.1.0"
|
||||
authors = ["Clark Moody <clark@clarkmoody.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "slider"
|
||||
version = "0.1.0"
|
||||
authors = ["Casper Rogild Storm<casper@rogildstorm.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "solar_system"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "stopwatch"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::keyboard;
|
||||
use iced::time::{self, milliseconds, Duration, Instant};
|
||||
use iced::time::{self, Duration, Instant, milliseconds};
|
||||
use iced::widget::{button, center, column, row, text};
|
||||
use iced::{Center, Element, Subscription, Theme};
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "styling"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "svg"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::widget::{center, center_x, checkbox, column, svg};
|
||||
use iced::{color, Element, Fill};
|
||||
use iced::{Element, Fill, color};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
iced::run("SVG - Iced", Tiger::update, Tiger::view)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "system_information"
|
||||
version = "0.1.0"
|
||||
authors = ["Richard <richardsoncusto@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::widget::{button, center, column, text};
|
||||
use iced::{system, Element, Task};
|
||||
use iced::{Element, Task, system};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
iced::application(
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "the_matrix"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use iced::mouse;
|
||||
use iced::time::{self, milliseconds, Instant};
|
||||
use iced::time::{self, Instant, milliseconds};
|
||||
use iced::widget::canvas;
|
||||
use iced::{
|
||||
Color, Element, Fill, Font, Point, Rectangle, Renderer, Subscription, Theme,
|
||||
|
|
@ -55,8 +55,8 @@ impl<Message> canvas::Program<Message> for TheMatrix {
|
|||
bounds: Rectangle,
|
||||
_cursor: mouse::Cursor,
|
||||
) -> Vec<canvas::Geometry> {
|
||||
use rand::distributions::Distribution;
|
||||
use rand::Rng;
|
||||
use rand::distributions::Distribution;
|
||||
|
||||
const CELL_SIZE: f32 = 10.0;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "toast"
|
||||
version = "0.1.0"
|
||||
authors = ["tarkah <admin@tarkah.dev>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "todos"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use iced::keyboard;
|
||||
use iced::widget::{
|
||||
self, button, center, center_x, checkbox, column, keyed_column, row,
|
||||
scrollable, text, text_input, Text,
|
||||
self, Text, button, center, center_x, checkbox, column, keyed_column, row,
|
||||
scrollable, text, text_input,
|
||||
};
|
||||
use iced::window;
|
||||
use iced::{
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "tooltip"
|
||||
version = "0.1.0"
|
||||
authors = ["Yusuf Bera Ertan <y.bera003.06@protonmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use iced::Element;
|
||||
use iced::widget::tooltip::Position;
|
||||
use iced::widget::{button, center, container, tooltip};
|
||||
use iced::Element;
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
iced::run("Tooltip - Iced", Tooltip::update, Tooltip::view)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "tour"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use iced::widget::{Button, Column, Container, Slider};
|
||||
use iced::widget::{
|
||||
button, center_x, center_y, checkbox, column, horizontal_space, image,
|
||||
radio, row, scrollable, slider, text, text_input, toggler, vertical_space,
|
||||
};
|
||||
use iced::widget::{Button, Column, Container, Slider};
|
||||
use iced::{Center, Color, Element, Fill, Font, Pixels};
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "url_handler"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "vectorial_text"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "visible_bounds"
|
||||
version = "0.1.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
name = "websocket"
|
||||
version = "1.0.0"
|
||||
authors = ["Héctor Ramón Jiménez <hector0193@gmail.com>"]
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
pub mod server;
|
||||
|
||||
use iced::futures;
|
||||
use iced::task::{sipper, Never, Sipper};
|
||||
use iced::task::{Never, Sipper, sipper};
|
||||
use iced::widget::text;
|
||||
|
||||
use futures::channel::mpsc;
|
||||
|
|
@ -12,7 +12,7 @@ use async_tungstenite::tungstenite;
|
|||
use std::fmt;
|
||||
|
||||
pub fn connect() -> impl Sipper<Never, Event> {
|
||||
sipper(|mut output| async move {
|
||||
sipper(async |mut output| {
|
||||
loop {
|
||||
const ECHO_SERVER: &str = "ws://127.0.0.1:3030";
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ use iced::futures;
|
|||
|
||||
use futures::channel::mpsc;
|
||||
use futures::{SinkExt, StreamExt};
|
||||
use warp::ws::WebSocket;
|
||||
use warp::Filter;
|
||||
use warp::ws::WebSocket;
|
||||
|
||||
// Basic WebSocket echo server adapted from:
|
||||
// https://github.com/seanmonstar/warp/blob/3ff2eaf41eb5ac9321620e5a6434d5b5ec6f313f/examples/websockets_chat.rs
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ mod echo;
|
|||
use iced::widget::{
|
||||
self, button, center, column, row, scrollable, text, text_input,
|
||||
};
|
||||
use iced::{color, Center, Element, Fill, Subscription, Task};
|
||||
use iced::{Center, Element, Fill, Subscription, Task, color};
|
||||
use std::sync::LazyLock;
|
||||
|
||||
pub fn main() -> iced::Result {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
//! An `async-std` backend.
|
||||
use futures::Future;
|
||||
|
||||
/// An `async-std` executor.
|
||||
#[derive(Debug)]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
//! A `smol` backend.
|
||||
use futures::Future;
|
||||
|
||||
/// A `smol` executor.
|
||||
#[derive(Debug)]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
//! A `ThreadPool` backend.
|
||||
use futures::Future;
|
||||
|
||||
/// A thread pool executor for futures.
|
||||
pub type Executor = futures::executor::ThreadPool;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
//! A `tokio` backend.
|
||||
use futures::Future;
|
||||
|
||||
/// A `tokio` executor.
|
||||
pub type Executor = tokio::runtime::Runtime;
|
||||
|
|
@ -22,12 +21,11 @@ impl crate::Executor for Executor {
|
|||
|
||||
pub mod time {
|
||||
//! Listen and react to time.
|
||||
use crate::MaybeSend;
|
||||
use crate::core::time::{Duration, Instant};
|
||||
use crate::subscription::Subscription;
|
||||
use crate::MaybeSend;
|
||||
|
||||
use futures::stream;
|
||||
use std::future::Future;
|
||||
|
||||
/// Returns a [`Subscription`] that produces messages at a set interval.
|
||||
///
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
//! A backend that does nothing!
|
||||
use futures::Future;
|
||||
|
||||
/// An executor that drops all the futures, instead of spawning them.
|
||||
#[derive(Debug)]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
//! Listen to runtime events.
|
||||
use crate::MaybeSend;
|
||||
use crate::core::event::{self, Event};
|
||||
use crate::core::window;
|
||||
use crate::subscription::{self, Subscription};
|
||||
use crate::MaybeSend;
|
||||
|
||||
/// Returns a [`Subscription`] to all the ignored runtime events.
|
||||
///
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue