mirror of
https://github.com/zed-industries/zed.git
synced 2026-12-01 21:10:37 +01:00
Position underlines at a distance proportional to the line descent
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
@@ -272,7 +272,13 @@ impl Line {
|
||||
}
|
||||
}
|
||||
if let Some(run_underline) = run_underline {
|
||||
underline.get_or_insert((glyph_origin, *run_underline));
|
||||
underline.get_or_insert((
|
||||
vec2f(
|
||||
glyph_origin.x(),
|
||||
origin.y() + baseline_offset.y() + 0.618 * self.layout.descent,
|
||||
),
|
||||
*run_underline,
|
||||
));
|
||||
}
|
||||
|
||||
run_end += *run_len as usize;
|
||||
|
||||
Reference in New Issue
Block a user