Skip to content

Implement canvas measure strategy #3449

@Tyriar

Description

@Tyriar

I have seen some reports like this:

image

I had a debug session with someone and there were some interesting findings:

  • It happened with monospace, Courier New, Consolas, Cascasia Code but not Arial (at least it wasn't obvious)
  • Switching fontSize (forcing the char atlas to get refreshed) did not fix the issue
  • Increasing the letter spacing mostly worked around the issue

Still not entirely sure why it's happening, but I believe handling this TODO will probably solve the issue and I can get it retested after we've done it:

// TODO: For supporting browsers we should also provide a CanvasCharDimensionsProvider that uses ctx.measureText

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions