mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-12 05:15:00 +00:00
Trim pending underline when text runs don't cover the whole line
This commit is contained in:
parent
8cf16c6ecc
commit
cf68ad3a82
1 changed files with 11 additions and 0 deletions
|
@ -293,6 +293,17 @@ impl Line {
|
||||||
} else {
|
} else {
|
||||||
run_end = self.layout.len;
|
run_end = self.layout.len;
|
||||||
color = Color::black();
|
color = Color::black();
|
||||||
|
if let Some(underline_origin) = underline_start.take() {
|
||||||
|
cx.scene.push_underline(scene::Quad {
|
||||||
|
bounds: RectF::from_points(
|
||||||
|
underline_origin,
|
||||||
|
glyph_origin + vec2f(0., 1.),
|
||||||
|
),
|
||||||
|
background: Some(color),
|
||||||
|
border: Default::default(),
|
||||||
|
corner_radius: 0.,
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue