mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Replace Skia font macros with enums. (flutter/engine#8920)
This mechanically replaces kXXX_SkTextEncoding with SkTextEncoding::kXXX and kXXX_SkFontHinting with SkFontHinting::kXXX. This will allow Skia to remove these old macro constants and get everyone on the new enums.
This commit is contained in:
parent
696cb532e2
commit
ead69ba45a
@ -24,7 +24,7 @@ void DrawStatisticsText(SkCanvas& canvas,
|
||||
font.setSize(15);
|
||||
SkPaint paint;
|
||||
paint.setColor(SK_ColorGRAY);
|
||||
canvas.drawSimpleText(string.c_str(), string.size(), kUTF8_SkTextEncoding, x,
|
||||
canvas.drawSimpleText(string.c_str(), string.size(), SkTextEncoding::kUTF8, x,
|
||||
y, font, paint);
|
||||
}
|
||||
|
||||
|
||||
@ -497,7 +497,7 @@ void Paragraph::Layout(double width, bool force) {
|
||||
SkFont font;
|
||||
font.setEdging(SkFont::Edging::kAntiAlias);
|
||||
font.setSubpixel(true);
|
||||
font.setHinting(kSlight_SkFontHinting);
|
||||
font.setHinting(SkFontHinting::kSlight);
|
||||
|
||||
records_.clear();
|
||||
line_heights_.clear();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user