Skip to main content

eval_math_arg

Function eval_math_arg 

Source
fn eval_math_arg(a: &str, containing_width: i32, font_px: f32) -> Option<f32>
Expand description

数式関数の引数 1 個を評価する。従来どおり関数・単一トークンは eval_length_token_with_font(途中を整数へ 丸める)で、それで読めない式(NaN * 1px・10px + 5px など)は + - * / の式として評価する。