Run cargo fmt

This commit is contained in:
Héctor Ramón Jiménez 2025-02-21 01:22:56 +01:00
parent 28caeccf22
commit 9ceb467e6e
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
59 changed files with 100 additions and 98 deletions

View file

@ -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)]

View file

@ -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;

View file

@ -1,6 +1,6 @@
use crate::SmolStr;
use crate::keyboard::key;
use crate::keyboard::{Key, Location, Modifiers};
use crate::SmolStr;
/// A keyboard event.
///

View file

@ -1,6 +1,6 @@
use crate::InputMethod;
use crate::event;
use crate::window;
use crate::InputMethod;
/// A connection to the state of a shell.
///

View file

@ -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;

View file

@ -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 {

View file

@ -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 {

View file

@ -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;