mirror of
https://github.com/servo/servo.git
synced 2025-08-16 02:45:36 +01:00
Fix match_refs and let_returns in layout, address review changes
This commit is contained in:
parent
5c24da3e2d
commit
8e2c37a542
12 changed files with 54 additions and 62 deletions
|
@ -156,15 +156,14 @@ impl<'a> Iterator for CharacterSliceIterator<'a> {
|
|||
impl<'a> TextRun {
|
||||
pub fn new(font: &mut Font, text: String, options: &ShapingOptions, bidi_level: u8) -> TextRun {
|
||||
let glyphs = TextRun::break_and_shape(font, &text, options);
|
||||
let run = TextRun {
|
||||
TextRun {
|
||||
text: Arc::new(text),
|
||||
font_metrics: font.metrics.clone(),
|
||||
font_template: font.handle.template(),
|
||||
actual_pt_size: font.actual_pt_size,
|
||||
glyphs: Arc::new(glyphs),
|
||||
bidi_level: bidi_level,
|
||||
};
|
||||
run
|
||||
}
|
||||
}
|
||||
|
||||
pub fn break_and_shape(font: &mut Font, text: &str, options: &ShapingOptions)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue