Bug 1269971 - Part 4. Add text stroke into text mask;
MozReview-Commit-ID: IkaLMEX5q0T
--- a/layout/generic/nsTextFrame.cpp
+++ b/layout/generic/nsTextFrame.cpp
@@ -6608,17 +6608,19 @@ nsTextFrame::PaintText(const PaintTextPa
? NS_RGBA(0, 0, 0, 255)
: textPaintStyle.GetTextColor();
if (aOpacity != 1.0f) {
gfx::Color gfxColor = gfx::Color::FromABGR(foregroundColor);
gfxColor.a *= aOpacity;
foregroundColor = gfxColor.ToABGR();
}
- nscolor textStrokeColor = textPaintStyle.GetWebkitTextStrokeColor();
+ nscolor textStrokeColor = aParams.generateTextMask
+ ? NS_RGBA(0, 0, 0, 255)
+ : textPaintStyle.GetWebkitTextStrokeColor();
if (aOpacity != 1.0f) {
gfx::Color gfxColor = gfx::Color::FromABGR(textStrokeColor);
gfxColor.a *= aOpacity;
textStrokeColor = gfxColor.ToABGR();
}
range = Range(startOffset, startOffset + maxLength);
if (!aParams.callbacks) {