Remove Mutex from FontSystem
This commit is contained in:
parent
46e9ef0246
commit
384c5c1fdc
16 changed files with 109 additions and 96 deletions
|
|
@ -99,7 +99,7 @@ fn shape_fallback(
|
|||
}
|
||||
|
||||
fn shape_run(
|
||||
font_system: &FontSystem,
|
||||
font_system: &mut FontSystem,
|
||||
line: &str,
|
||||
attrs_list: &AttrsList,
|
||||
start_run: usize,
|
||||
|
|
@ -273,7 +273,7 @@ pub struct ShapeWord {
|
|||
|
||||
impl ShapeWord {
|
||||
pub fn new(
|
||||
font_system: &FontSystem,
|
||||
font_system: &mut FontSystem,
|
||||
line: &str,
|
||||
attrs_list: &AttrsList,
|
||||
word_range: Range<usize>,
|
||||
|
|
@ -347,7 +347,7 @@ pub struct ShapeSpan {
|
|||
|
||||
impl ShapeSpan {
|
||||
pub fn new(
|
||||
font_system: &FontSystem,
|
||||
font_system: &mut FontSystem,
|
||||
line: &str,
|
||||
attrs_list: &AttrsList,
|
||||
span_range: Range<usize>,
|
||||
|
|
@ -431,7 +431,7 @@ impl ShapeLine {
|
|||
/// # Panics
|
||||
///
|
||||
/// Will panic if `line` contains more than one paragraph.
|
||||
pub fn new(font_system: &FontSystem, line: &str, attrs_list: &AttrsList) -> Self {
|
||||
pub fn new(font_system: &mut FontSystem, line: &str, attrs_list: &AttrsList) -> Self {
|
||||
let mut spans = Vec::new();
|
||||
|
||||
let bidi = unicode_bidi::BidiInfo::new(line, None);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue