gfx: Instantiate the CTFont corresponding to a Mac font on demand.

This avoids panics in multiprocess mode.
This commit is contained in:
Patrick Walton 2015-07-27 14:18:50 -07:00
parent 1ff7a51f0a
commit e9ec9289d6
3 changed files with 18 additions and 8 deletions

View file

@ -64,7 +64,7 @@ impl FontHandleMethods for FontHandle {
Some(s) => s.to_f64_px(),
None => 0.0
};
match *template.ctfont {
match template.ctfont() {
Some(ref ctfont) => {
Ok(FontHandle {
font_data: template.clone(),