Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IsAntialias should also control the Edging #1802

Merged
merged 1 commit into from
Sep 8, 2021
Merged

Conversation

mattleibow
Copy link
Contributor

@mattleibow mattleibow commented Sep 8, 2021

Description of Change

@mattleibow

This is for compatibility and consistency. Before 2.80, the anti-aliasing flag would also affect the font edging. After 2.80, the properties were separate and now we have to make sure the paint updates the edging based on what the anti-aliasing and LCD rendering indicate.

Bugs Fixed

1.68.x 2.80.x PR
image image image
cnv.Clear(SKColors.White);

var paint = new SKPaint();
paint.TextSize = 40;

paint.IsAntialias = false;
paint.LcdRenderText = false;
cnv.DrawText("Hello World!", 20, 50, paint);

paint.IsAntialias = true;
paint.LcdRenderText = false;
cnv.DrawText("Hello World!", 20, 100, paint);

paint.IsAntialias = false;
paint.LcdRenderText = true;
cnv.DrawText("Hello World!", 20, 150, paint);

paint.IsAntialias = true;
paint.LcdRenderText = true;
cnv.DrawText("Hello World!", 20, 200, paint);

API Changes

Behavioral Changes

PR Checklist

  • Has tests (if omitted, state reason in description)
  • Rebased on top of main at time of PR
  • Changes adhere to coding standard
  • Updated documentation

This is for compatibility and consistency. Before 2.80, the anti-aliasing flag would also affect the font edging. After 2.80, the properties were separate and now we have to make sure the paint updates the edging based on what the anti-aliasing and LCD rendering indicate.
@mattleibow mattleibow merged commit 5ab62b5 into patch/v2.80.4 Sep 8, 2021
@mattleibow mattleibow deleted the dev/aa branch September 8, 2021 21:34
@mattleibow mattleibow added this to the v2.80.4 milestone May 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

1 participant