|
|
@ -66,16 +66,14 @@ impl Cursor {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
pub fn foreground(&self, default_colors: &Colors) -> Color4f {
|
|
|
|
pub fn foreground(&self, default_colors: &Colors) -> Color4f {
|
|
|
|
self
|
|
|
|
self.style
|
|
|
|
.style
|
|
|
|
|
|
|
|
.as_ref()
|
|
|
|
.as_ref()
|
|
|
|
.and_then(|s| s.colors.foreground)
|
|
|
|
.and_then(|s| s.colors.foreground)
|
|
|
|
.unwrap_or(default_colors.background.unwrap())
|
|
|
|
.unwrap_or(default_colors.background.unwrap())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
pub fn background(&self, default_colors: &Colors) -> Color4f {
|
|
|
|
pub fn background(&self, default_colors: &Colors) -> Color4f {
|
|
|
|
self
|
|
|
|
self.style
|
|
|
|
.style
|
|
|
|
|
|
|
|
.as_ref()
|
|
|
|
.as_ref()
|
|
|
|
.and_then(|s| s.colors.background)
|
|
|
|
.and_then(|s| s.colors.background)
|
|
|
|
.unwrap_or(default_colors.foreground.unwrap())
|
|
|
|
.unwrap_or(default_colors.foreground.unwrap())
|
|
|
|