Skip to content

Commit

Permalink
修复垂直布局字体参数
Browse files Browse the repository at this point in the history
  • Loading branch information
TakWolf committed Jul 20, 2024
1 parent eab59ab commit 239875c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/services/font_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ def _create_builder(self, width_mode: WidthMode, language_flavor: LanguageFlavor
builder.font_metric.horizontal_layout.ascent = layout_param.ascent
builder.font_metric.horizontal_layout.descent = layout_param.descent
builder.font_metric.vertical_layout.ascent = math.ceil(layout_param.line_height / 2)
builder.font_metric.vertical_layout.descent = math.floor(layout_param.line_height / 2)
builder.font_metric.vertical_layout.descent = -math.floor(layout_param.line_height / 2)
builder.font_metric.x_height = layout_param.x_height
builder.font_metric.cap_height = layout_param.cap_height

Expand Down

0 comments on commit 239875c

Please sign in to comment.