mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-22 08:58:13 +08:00
Clean up text input (#506)
* Fix firefox text input * Fix descenders below bounding box * Fix chromium empty text * Descenders back below baseline * Fix trailing newline on chromium * Reinstate correct baseline height * Fix highlighted new line on empty text * Add comment for trailing new line removal * Extract cleanupTextInput to a separate file * Function import simplification Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
committed by
Keavon Chambers
co-authored by
Keavon Chambers
parent
dd36339605
commit
376f4da480
@@ -74,7 +74,7 @@ pub fn to_kurbo(str: &str, buzz_face: rustybuzz::Face, font_size: f64, line_widt
|
||||
path: BezPath::new(),
|
||||
pos: Point::ZERO,
|
||||
offset: Vec2::ZERO,
|
||||
ascender: buzz_face.ascender() as f64,
|
||||
ascender: (buzz_face.ascender() as f64 / buzz_face.height() as f64) * font_size / scale,
|
||||
scale,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user