Skip to content

[Port .NET 6 ] Fixes rounding error while glyphrun serialization - #6555

Merged
dipeshmsft merged 1 commit into
release/6.0from
glyphrun-issue-net6
May 10, 2022
Merged

dipeshmsft merged 1 commit into
release/6.0from
glyphrun-issue-net6

Conversation

@dipeshmsft

@dipeshmsft dipeshmsft commented May 9, 2022 •

Copy link
Copy Markdown
Member

Fixes # #6525

Main PR #6295

Description

When we serialize a GlyphRun to an XPS file, the advance widths for each glyph are rounded to an integer separately, thus producing a significant difference between the rendered output in the file and on the screen. This PR fixes the rounding, by taking into account the cumulative rounding error from the previous glyphs while rounding the current glyph.

Customer Impact

Affects the visual fidelity of WPF Applications.

Regression

No

Testing

Ad-Hoc testing. Tried with different sample apps.

Risk

Less

Microsoft Reviewers: Open in CodeFlow

@dipeshmsft
dipeshmsft requested a review from a team as a code owner May 9, 2022 06:25
@ghost ghost assigned dipeshmsft May 9, 2022
@ghost ghost added the PR metadata: Label to tag PRs, to facilitate with triage label May 9, 2022
@ghost
ghost requested review from SamBent and singhashish-wpf May 9, 2022 06:25
@ghost

ghost commented May 9, 2022

Copy link
Copy Markdown

Hi @dipeshmsft. Please make sure you've updated the PR description to use the Shiproom Template. Also, make sure this PR is not marked as a draft and is ready-to-merge.

To learn more about how to prepare a servicing PR click here.

@dipeshmsft
dipeshmsft merged commit e820887 into release/6.0 May 10, 2022
@dipeshmsft
dipeshmsft deleted the glyphrun-issue-net6 branch May 10, 2022 06:20
@ghost ghost locked as resolved and limited conversation to collaborators Jun 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

PR metadata: Label to tag PRs, to facilitate with triage Servicing-approved

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants