parent
afecc0f367
commit
7a86900a45
11 changed files with 16 additions and 16 deletions
|
|
@ -203,7 +203,7 @@ pub enum Named {
|
||||||
Standby,
|
Standby,
|
||||||
/// The WakeUp key. (`KEYCODE_WAKEUP`)
|
/// The WakeUp key. (`KEYCODE_WAKEUP`)
|
||||||
WakeUp,
|
WakeUp,
|
||||||
/// Initate the multi-candidate mode.
|
/// Initiate the multi-candidate mode.
|
||||||
AllCandidates,
|
AllCandidates,
|
||||||
Alphanumeric,
|
Alphanumeric,
|
||||||
/// Initiate the Code Input mode to allow characters to be entered by
|
/// Initiate the Code Input mode to allow characters to be entered by
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ impl Modifiers {
|
||||||
/// This is normally the main modifier to be used for hotkeys.
|
/// This is normally the main modifier to be used for hotkeys.
|
||||||
///
|
///
|
||||||
/// On macOS, this is equivalent to `Self::LOGO`.
|
/// On macOS, this is equivalent to `Self::LOGO`.
|
||||||
/// Ohterwise, this is equivalent to `Self::CTRL`.
|
/// Otherwise, this is equivalent to `Self::CTRL`.
|
||||||
pub const COMMAND: Self = if cfg!(target_os = "macos") {
|
pub const COMMAND: Self = if cfg!(target_os = "macos") {
|
||||||
Self::LOGO
|
Self::LOGO
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -411,13 +411,13 @@ impl<'a, Link, Font> Span<'a, Link, Font> {
|
||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets whether the [`Span`] shoud be underlined or not.
|
/// Sets whether the [`Span`] should be underlined or not.
|
||||||
pub fn underline(mut self, underline: bool) -> Self {
|
pub fn underline(mut self, underline: bool) -> Self {
|
||||||
self.underline = underline;
|
self.underline = underline;
|
||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets whether the [`Span`] shoud be struck through or not.
|
/// Sets whether the [`Span`] should be struck through or not.
|
||||||
pub fn strikethrough(mut self, strikethrough: bool) -> Self {
|
pub fn strikethrough(mut self, strikethrough: bool) -> Self {
|
||||||
self.strikethrough = strikethrough;
|
self.strikethrough = strikethrough;
|
||||||
self
|
self
|
||||||
|
|
|
||||||
|
|
@ -155,7 +155,7 @@ impl Compositor for () {
|
||||||
async fn with_backend<W: Window + Clone>(
|
async fn with_backend<W: Window + Clone>(
|
||||||
_settings: Settings,
|
_settings: Settings,
|
||||||
_compatible_window: W,
|
_compatible_window: W,
|
||||||
_preffered_backend: Option<&str>,
|
_preferred_backend: Option<&str>,
|
||||||
) -> Result<Self, Error> {
|
) -> Result<Self, Error> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ pub enum Action {
|
||||||
QueryInformation(oneshot::Sender<Information>),
|
QueryInformation(oneshot::Sender<Information>),
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Contains informations about the system (e.g. system name, processor, memory, graphics adapter).
|
/// Contains information about the system (e.g. system name, processor, memory, graphics adapter).
|
||||||
#[derive(Clone, Debug)]
|
#[derive(Clone, Debug)]
|
||||||
pub struct Information {
|
pub struct Information {
|
||||||
/// The operating system name
|
/// The operating system name
|
||||||
|
|
|
||||||
|
|
@ -220,7 +220,7 @@ pub fn resize_events() -> Subscription<(Id, Size)> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Subscribes to all [`Event::CloseRequested`] occurences in the running application.
|
/// Subscribes to all [`Event::CloseRequested`] occurrences in the running application.
|
||||||
pub fn close_requests() -> Subscription<Id> {
|
pub fn close_requests() -> Subscription<Id> {
|
||||||
event::listen_with(|event, _status, id| {
|
event::listen_with(|event, _status, id| {
|
||||||
if let crate::core::Event::Window(Event::CloseRequested) = event {
|
if let crate::core::Event::Window(Event::CloseRequested) = event {
|
||||||
|
|
|
||||||
|
|
@ -477,9 +477,9 @@ pub struct Style {
|
||||||
pub background: Option<Background>,
|
pub background: Option<Background>,
|
||||||
/// The text [`Color`] of the button.
|
/// The text [`Color`] of the button.
|
||||||
pub text_color: Color,
|
pub text_color: Color,
|
||||||
/// The [`Border`] of the buton.
|
/// The [`Border`] of the button.
|
||||||
pub border: Border,
|
pub border: Border,
|
||||||
/// The [`Shadow`] of the butoon.
|
/// The [`Shadow`] of the button.
|
||||||
pub shadow: Shadow,
|
pub shadow: Shadow,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -487,7 +487,7 @@ pub struct Style {
|
||||||
pub background: Background,
|
pub background: Background,
|
||||||
/// The icon [`Color`] of the checkbox.
|
/// The icon [`Color`] of the checkbox.
|
||||||
pub icon_color: Color,
|
pub icon_color: Color,
|
||||||
/// The [`Border`] of hte checkbox.
|
/// The [`Border`] of the checkbox.
|
||||||
pub border: Border,
|
pub border: Border,
|
||||||
/// The text [`Color`] of the checkbox.
|
/// The text [`Color`] of the checkbox.
|
||||||
pub text_color: Option<Color>,
|
pub text_color: Option<Color>,
|
||||||
|
|
@ -600,7 +600,7 @@ pub fn success(theme: &Theme, status: Status) -> Style {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A danger checkbox; denoting a negaive toggle.
|
/// A danger checkbox; denoting a negative toggle.
|
||||||
pub fn danger(theme: &Theme, status: Status) -> Style {
|
pub fn danger(theme: &Theme, status: Status) -> Style {
|
||||||
let palette = theme.extended_palette();
|
let palette = theme.extended_palette();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -608,8 +608,8 @@ where
|
||||||
..
|
..
|
||||||
}) = event
|
}) = event
|
||||||
{
|
{
|
||||||
let shift_modifer = modifiers.shift();
|
let shift_modifier = modifiers.shift();
|
||||||
match (named_key, shift_modifer) {
|
match (named_key, shift_modifier) {
|
||||||
(key::Named::Enter, _) => {
|
(key::Named::Enter, _) => {
|
||||||
if let Some(index) = &menu.hovered_option {
|
if let Some(index) = &menu.hovered_option {
|
||||||
if let Some(option) =
|
if let Some(option) =
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
//! Markdown widgets can parse and display Markdown.
|
//! Markdown widgets can parse and display Markdown.
|
||||||
//!
|
//!
|
||||||
//! You can enable the `highlighter` feature for syntax highligting
|
//! You can enable the `highlighter` feature for syntax highlighting
|
||||||
//! in code blocks.
|
//! in code blocks.
|
||||||
//!
|
//!
|
||||||
//! Only the variants of [`Item`] are currently supported.
|
//! Only the variants of [`Item`] are currently supported.
|
||||||
|
|
@ -72,7 +72,7 @@ pub enum Item {
|
||||||
Paragraph(Text),
|
Paragraph(Text),
|
||||||
/// A code block.
|
/// A code block.
|
||||||
///
|
///
|
||||||
/// You can enable the `highlighter` feature for syntax highligting.
|
/// You can enable the `highlighter` feature for syntax highlighting.
|
||||||
CodeBlock(Text),
|
CodeBlock(Text),
|
||||||
/// A list.
|
/// A list.
|
||||||
List {
|
List {
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ where
|
||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets the defualt [`LineHeight`] of the [`Rich`] text.
|
/// Sets the default [`LineHeight`] of the [`Rich`] text.
|
||||||
pub fn line_height(mut self, line_height: impl Into<LineHeight>) -> Self {
|
pub fn line_height(mut self, line_height: impl Into<LineHeight>) -> Self {
|
||||||
self.line_height = line_height.into();
|
self.line_height = line_height.into();
|
||||||
self
|
self
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue