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

Add the ability to filter glyphs to be processed #127

Merged
merged 3 commits into from
Mar 6, 2023
Merged

Conversation

rsheeter
Copy link
Contributor

@rsheeter rsheeter commented Mar 3, 2023

Very handy when trying to track down issues with specific glyphs.

Skip features when a glyph filter is active.

Base automatically changed from new_kurbo to main March 3, 2023 23:35
Copy link
Member

@dfrg dfrg left a comment

Choose a reason for hiding this comment

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

Lgtm!

.map_err(Error::BadRegex)?;

if let Some(regex) = &glyph_name_filter {
current_inputs.glyphs.retain(|glyph_name, _| {
Copy link
Member

@dfrg dfrg Mar 6, 2023

Choose a reason for hiding this comment

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

Per im, feature compilation requires the full glyph list. Assuming we want to eventually support filtering in combination with features (compile time subsetting?) it might be worth thinking about how we retain the original glyph order and map between that and the filtered set.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We can store it on Context if it turns out we need it.

@rsheeter rsheeter merged commit 8832b15 into main Mar 6, 2023
@rsheeter rsheeter deleted the glyph_filter branch March 6, 2023 18:29
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