Reset PathEffect for GetTextPaint to prevent unnecessary text shaping by erikvdv1 · Pull Request #2171 · oxyplot/oxyplot · GitHub
Skip to content

Reset PathEffect for GetTextPaint to prevent unnecessary text shaping - #2171

Open
erikvdv1 wants to merge 1 commit into
oxyplot:developfrom
erikvdv1:develop
Open

erikvdv1 wants to merge 1 commit into
oxyplot:developfrom
erikvdv1:develop

Conversation

@erikvdv1

@erikvdv1 erikvdv1 commented Sep 16, 2026 •

Copy link
Copy Markdown

Fixes unnecessary text shaping when exporting plot to SVG using OxyPlot.SkiaSharp.SvgExporter. When drawing the legend below, the PathEffect leaks through the second/third/fourth DrawText call, because it is used when drawing the legend symbol. This causes Skia to render the text as SVG <path> element instead of SVG <text> element. This results in slightly different rendering (semi bold) and the shaped text cannot be selected by the user.

image

Checklist

  • I have included examples or tests
  • I have updated the change log
  • I am listed in the CONTRIBUTORS file
  • I have cleaned up the commit history (use rebase and squash)

Changes proposed in this pull request:

  • Reset PathEffect for GetTextPaint to prevent unnecessary text shaping

@oxyplot/admins

@objorke objorke left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @erikvdv1!
this looks good to me
could it be covered by automated test? otherwise visual review - I understand that is included in the PR description.

@erikvdv1

Copy link
Copy Markdown
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants