mirror of
https://gitee.com/openharmony/graphic_graphic_2d
synced 2024-11-27 09:10:54 +00:00
高对比度文字加入抗锯齿,描边禁用提亮功能
Signed-off-by: lili(@lili-lili-lili) <lili304@h-partners.com>
This commit is contained in:
parent
7013dedaf8
commit
7faf9af0b0
@ -1630,7 +1630,8 @@ void DrawTextBlobOpItem::DrawHighContrast(Canvas* canvas, bool offScreen) const
|
||||
// draw outline stroke with pen
|
||||
Drawing::Pen outlinePen;
|
||||
outlinePen.SetColor(flag ? Color::COLOR_WHITE : Color::COLOR_BLACK);
|
||||
outlinePen.SetAntiAlias(false);
|
||||
outlinePen.SetAntiAlias(true);
|
||||
outlinePen.SetBlenderEnabled(false);
|
||||
canvas->AttachPen(outlinePen);
|
||||
offScreen ? canvas->DrawTextBlob(textBlob_.get(), 0, 0) : canvas->DrawTextBlob(textBlob_.get(), x_, y_);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user