class
Tessell::Text::StubMeasurer
- Tessell::Text::StubMeasurer
- Tessell::Text::Measurer
- Reference
- Object
Overview
确定性桩:width = chars * size * 0.6,height = size * 1.2,尊重 max_width 换行 仅用于布局与单测;不得当真实度量
Defined in:
tessell/text/measurer.crInstance Method Summary
-
#measure(text : String, font_id : Int32, size : Float32, max_width : Float32) : Size
主接口:按文本内容、字体、字号、可用宽测量
Instance methods inherited from class Tessell::Text::Measurer
font_metrics(font_id : Int32, size : Float32) : FontMetrics
font_metrics,
measure(text : String, font_id : Int32, size : Float32, max_width : Float32) : Sizemeasure(key : MeasureKey) : Size measure, shape_run(text : String, font_id : Int32, size : Float32) : ShapeRun | Nil shape_run
Instance Method Detail
Description copied from class Tessell::Text::Measurer
主接口:按文本内容、字体、字号、可用宽测量