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

Vertical Writing Modes in Canvas Formatted Text #372

Closed
travisleithead opened this issue Aug 4, 2020 · 4 comments
Closed

Vertical Writing Modes in Canvas Formatted Text #372

travisleithead opened this issue Aug 4, 2020 · 4 comments
Assignees

Comments

@travisleithead
Copy link
Contributor

Text drawing needs to be aware of vertical writing mode to rotate glyphs in some fonts / languages while rendering a line.

The topic needs further investigation.

  • Should metrics be flipped automatically? Are new APIs needed?

(Note existing text APIs in Canvas do not handle this scenario either--a solution would ideally be comprehensive.)

@Malvoz
Copy link
Contributor

Malvoz commented Sep 10, 2020

/cc @bdon

@kojiishi
Copy link

Would it make sense for this to match what CSS renders, by making Canvas aware of writing-mode and text-orientation properties?

@travisleithead
Copy link
Contributor Author

I think finding a way to incorporate those properties into the input to this feature is likely the best way to achieve vertical writing mode.

Currently some values, e.g., "width", and "height" would need to be generalized to make sense in vertical writing modes. I like the idea of reusing some of the terminology in CSS Layout API to do this (as well as aligning on a few other concepts as well).

@travisleithead
Copy link
Contributor Author

Closing as this is tracked in the corresponding WICG issue now.

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

No branches or pull requests

4 participants