summaryrefslogtreecommitdiff
path: root/src/exec/state.rs
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2021-07-08 22:33:44 +0200
committerLaurenz <laurmaedje@gmail.com>2021-07-08 22:33:44 +0200
commitfd0b89a1d8e4f811fcf3517d321a327a0cf72edf (patch)
tree75d247866f5db1a0ad32909da6e0fdaafa479592 /src/exec/state.rs
parent7e2c217cbc3805c4cae613baf4149cc82e10d503 (diff)
Rename Fill to Paint
Diffstat (limited to 'src/exec/state.rs')
-rw-r--r--src/exec/state.rs14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/exec/state.rs b/src/exec/state.rs
index 24e4b9f3..cbd65622 100644
--- a/src/exec/state.rs
+++ b/src/exec/state.rs
@@ -4,7 +4,7 @@ use std::rc::Rc;
use crate::color::{Color, RgbaColor};
use crate::font::{FontStretch, FontStyle, FontVariant, FontWeight, VerticalFontMetric};
use crate::geom::*;
-use crate::layout::Fill;
+use crate::layout::Paint;
use crate::paper::{Paper, PaperClass, PAPER_A4};
/// The execution state.
@@ -117,8 +117,8 @@ pub struct FontState {
pub top_edge: VerticalFontMetric,
/// The bottom end of the text bounding box.
pub bottom_edge: VerticalFontMetric,
- /// The glyph fill color / texture.
- pub fill: Fill,
+ /// Glyph color.
+ pub fill: Paint,
/// Whether the strong toggle is active or inactive. This determines
/// whether the next `*` adds or removes font weight.
pub strong: bool,
@@ -152,7 +152,7 @@ impl Default for FontState {
size: Length::pt(11.0),
top_edge: VerticalFontMetric::CapHeight,
bottom_edge: VerticalFontMetric::Baseline,
- fill: Fill::Color(Color::Rgba(RgbaColor::BLACK)),
+ fill: Paint::Color(Color::Rgba(RgbaColor::BLACK)),
strong: false,
emph: false,
strikethrough: None,
@@ -165,8 +165,10 @@ impl Default for FontState {
/// Describes a line that could be positioned over, under or on top of text.
#[derive(Debug, Copy, Clone, PartialEq, Hash)]
pub struct LineState {
- /// Stroke color of the line. Defaults to the text color if `None`.
- pub stroke: Option<Fill>,
+ /// Stroke color of the line.
+ ///
+ /// Defaults to the text color if `None`.
+ pub stroke: Option<Paint>,
/// Thickness of the line's stroke. Calling functions should attempt to
/// read this value from the appropriate font tables if this is `None`.
pub thickness: Option<Linear>,