Skip to content

Update skrifa to 0.42#118

Open
rhysd wants to merge 1 commit into
dfrg:mainfrom
rhysd:skrifa-0.42
Open

Update skrifa to 0.42#118
rhysd wants to merge 1 commit into
dfrg:mainfrom
rhysd:skrifa-0.42

Conversation

@rhysd
Copy link
Copy Markdown

@rhysd rhysd commented May 28, 2026

This PR upgrades skrifa dependency to 0.42. I'm using swash with harfrust. However harfrust depends on more recent version of read-fonts.

  • swash 0.2.7 → skrifa 0.40 → read-fonts 0.37
  • harfrust 0.7.0 → read-fonts 0.39

This caused a conflict in my app so I could not upgrade harfrust to the latest version and I needed to stick with harfrust 0.5.2. This PR aims to unlock the harfrust version upgrade.

All tests passed. I tried this branch with my app and I didn't find any issues.

The non-trivial change in this branch is that skrifa added OutlineGlyphFormat::Varc at 0.41.

https://docs.rs/skrifa/0.41.0/skrifa/outline/enum.OutlineGlyphFormat.html

OutlineGlyphFormat::Glyf => &mut self.glyf_entries,
OutlineGlyphFormat::Cff | OutlineGlyphFormat::Cff2 => &mut self.cff_entries,
#[allow(unreachable_patterns)]
_ => &mut self.other_entries,
Copy link
Copy Markdown
Author

@rhysd rhysd May 28, 2026

Choose a reason for hiding this comment

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

To keep compatibility with older versions of skrifa OutlineGlyphFormat::Varc variant is not available in this arm and #[allow(unreachable_patterns)] is necessary.

If we can upgrade the lower bound of the skrifa version to >=0.41, <=0.42, this arm can be improved. Please let me know if this is preferred.

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.

1 participant