pub struct Theme {Show 22 fields
pub foreground: Color,
pub muted: Color,
pub document_title: Color,
pub heading: Color,
pub link: Color,
pub list: Color,
pub code: Color,
pub table: Color,
pub image: Color,
pub form: Color,
pub quote: Color,
pub region: Color,
pub bold: Color,
pub italic: Color,
pub error: Color,
pub warning: Color,
pub success: Color,
pub info: Color,
pub current_line: Color,
pub accent: Color,
pub prompt: Color,
pub status: Color,
}Expand description
Terminal theme colors.
Fields§
§foreground: ColorPrimary text color.
muted: ColorSecondary text color.
document_title: ColorDocument title color.
heading: ColorHeading color.
link: ColorLink color.
list: ColorList marker color.
code: ColorCode block color.
table: ColorTable row color.
image: ColorImage proxy color.
form: ColorForm color.
quote: ColorQuote color.
region: ColorSemantic page region marker color.
bold: ColorBold inline text color.
italic: ColorItalic inline text color.
error: ColorError color.
warning: ColorWarning color.
success: ColorSuccess color.
info: ColorInfo color.
current_line: ColorMild current-line background color.
accent: ColorHighlight color.
prompt: ColorAlways-visible command prompt color.
status: ColorStatus bar foreground color.
Implementations§
Source§impl Theme
impl Theme
Sourcepub fn for_profile(profile: ReaderProfile) -> Self
pub fn for_profile(profile: ReaderProfile) -> Self
Builds the default deterministic theme for a reader profile.
Sourcepub fn for_profile_with_capabilities(
profile: ReaderProfile,
capabilities: TerminalCapabilities,
) -> Self
pub fn for_profile_with_capabilities( profile: ReaderProfile, capabilities: TerminalCapabilities, ) -> Self
Builds a deterministic theme for a reader profile and terminal capability set.
Trait Implementations§
impl Copy for Theme
impl Eq for Theme
impl StructuralPartialEq for Theme
Auto Trait Implementations§
impl Freeze for Theme
impl RefUnwindSafe for Theme
impl Send for Theme
impl Sync for Theme
impl Unpin for Theme
impl UnsafeUnpin for Theme
impl UnwindSafe for Theme
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more