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

Handle space characters in fontFamily within TTML Parsing #251

Merged
merged 3 commits into from
Dec 22, 2023

Conversation

mattjuggins
Copy link
Contributor

Closes #250
Similar to #245, the default generic font family was not being correctly mapped to monospaceSerif if there were stray spacing characters on either side of the word, i.e. default.
A solution similar to #246 is implemented using trim() and a unit test is provided for sanity checking.

@palemieux
Copy link
Contributor

@mattjuggins Ready for review?

@palemieux palemieux self-requested a review December 19, 2023 19:27
@mattjuggins
Copy link
Contributor Author

@palemieux yep, all ready. I don't believe there's anything more to it.

<body>
<div>
<p tts:fontFamily="default">Maps 'default' generic family name to 'monospaceSerif' correctly.</p>
<p tts:fontFamily="Arial,default">Maps 'default' value used as a fallback to 'monospaceSerif' correctly.</p>
Copy link
Contributor

Choose a reason for hiding this comment

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

Please align the <p> elements

@palemieux
Copy link
Contributor

@mattjuggins Looks great. Just one minor nit to fix if you do not mind.

@palemieux palemieux closed this Dec 21, 2023
@palemieux palemieux reopened this Dec 21, 2023
@mattjuggins
Copy link
Contributor Author

@palemieux no problem. That should be sorted now.

@palemieux palemieux merged commit 2c939c8 into sandflow:master Dec 22, 2023
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.

FontFamily default name mapping missing
2 participants