Commit cab2cacb authored by Akihiro Sagawa's avatar Akihiro Sagawa Committed by Alexandre Julliard

gdi32: Adjust fake bold outline font metrics.

parent b6666014
......@@ -7330,8 +7330,11 @@ static BOOL get_outline_text_metrics(GdiFont *font)
}
TM.tmMaxCharWidth = SCALE_X(ft_face->bbox.xMax - ft_face->bbox.xMin);
TM.tmWeight = FW_REGULAR;
if (font->fake_bold)
if (font->fake_bold) {
TM.tmAveCharWidth++;
TM.tmMaxCharWidth++;
TM.tmWeight = FW_BOLD;
}
else
{
if (ft_face->style_flags & FT_STYLE_FLAG_BOLD)
......
......@@ -5693,9 +5693,9 @@ static void test_fake_bold_font(void)
ok(tm[0].tmHeight == tm[1].tmHeight, "expected %d, got %d\n", tm[0].tmHeight, tm[1].tmHeight);
ok(tm[0].tmAscent == tm[1].tmAscent, "expected %d, got %d\n", tm[0].tmAscent, tm[1].tmAscent);
ok(tm[0].tmDescent == tm[1].tmDescent, "expected %d, got %d\n", tm[0].tmDescent, tm[1].tmDescent);
todo_wine ok((tm[0].tmAveCharWidth + 1) == tm[1].tmAveCharWidth,
ok((tm[0].tmAveCharWidth + 1) == tm[1].tmAveCharWidth,
"expected %d, got %d\n", tm[0].tmAveCharWidth + 1, tm[1].tmAveCharWidth);
todo_wine ok((tm[0].tmMaxCharWidth + 1) == tm[1].tmMaxCharWidth,
ok((tm[0].tmMaxCharWidth + 1) == tm[1].tmMaxCharWidth,
"expected %d, got %d\n", tm[0].tmMaxCharWidth + 1, tm[1].tmMaxCharWidth);
ok(tm[0].tmOverhang == tm[1].tmOverhang, "expected %d, got %d\n", tm[0].tmOverhang, tm[1].tmOverhang);
w[0] = abc[0].abcA + abc[0].abcB + abc[0].abcC;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment