@@ -1068,6 +1068,7 @@ bool RenderTextInCanvas(const std::shared_ptr<Context>& context,
1068
1068
1069
1069
TEST_P (AiksTest, CanRenderTextFrame) {
1070
1070
Canvas canvas;
1071
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1071
1072
ASSERT_TRUE (RenderTextInCanvas (
1072
1073
GetContext (), canvas, " the quick brown fox jumped over the lazy dog!.?" ,
1073
1074
" Roboto-Regular.ttf" ));
@@ -1119,6 +1120,8 @@ TEST_P(AiksTest, TextFrameSubpixelAlignment) {
1119
1120
1120
1121
TEST_P (AiksTest, CanRenderItalicizedText) {
1121
1122
Canvas canvas;
1123
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1124
+
1122
1125
ASSERT_TRUE (RenderTextInCanvas (
1123
1126
GetContext (), canvas, " the quick brown fox jumped over the lazy dog!.?" ,
1124
1127
" HomemadeApple.ttf" ));
@@ -1127,6 +1130,8 @@ TEST_P(AiksTest, CanRenderItalicizedText) {
1127
1130
1128
1131
TEST_P (AiksTest, CanRenderEmojiTextFrame) {
1129
1132
Canvas canvas;
1133
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1134
+
1130
1135
ASSERT_TRUE (RenderTextInCanvas (GetContext (), canvas,
1131
1136
" 😀 😃 😄 😁 😆 😅 😂 🤣 🥲 😊" ,
1132
1137
#if FML_OS_MACOSX
@@ -1139,6 +1144,8 @@ TEST_P(AiksTest, CanRenderEmojiTextFrame) {
1139
1144
1140
1145
TEST_P (AiksTest, CanRenderEmojiTextFrameWithAlpha) {
1141
1146
Canvas canvas;
1147
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1148
+
1142
1149
ASSERT_TRUE (RenderTextInCanvas (GetContext (), canvas,
1143
1150
" 😀 😃 😄 😁 😆 😅 😂 🤣 🥲 😊" ,
1144
1151
#if FML_OS_MACOSX
@@ -1152,7 +1159,8 @@ TEST_P(AiksTest, CanRenderEmojiTextFrameWithAlpha) {
1152
1159
1153
1160
TEST_P (AiksTest, CanRenderTextInSaveLayer) {
1154
1161
Canvas canvas;
1155
- canvas.DrawPaint ({.color = Color::White ()});
1162
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1163
+
1156
1164
canvas.Translate ({100 , 100 });
1157
1165
canvas.Scale (Vector2{0.5 , 0.5 });
1158
1166
@@ -1211,12 +1219,7 @@ TEST_P(AiksTest, CanRenderTextOutsideBoundaries) {
1211
1219
TEST_P (AiksTest, TextRotated) {
1212
1220
Canvas canvas;
1213
1221
canvas.Scale (GetContentScale ());
1214
-
1215
- Paint paint;
1216
- paint.color = Color (0.1 , 0.1 , 0.1 , 1.0 );
1217
- canvas.DrawRect (
1218
- Rect::MakeLTRB (0 , 0 , GetWindowSize ().width , GetWindowSize ().height ),
1219
- paint);
1222
+ canvas.DrawPaint ({.color = Color (0.1 , 0.1 , 0.1 , 1.0 )});
1220
1223
1221
1224
canvas.Transform (Matrix (0.25 , -0.3 , 0 , -0.002 , //
1222
1225
0 , 0.5 , 0 , 0 , //
0 commit comments