Skip to content

Commit

Permalink
Merge pull request #1281 from googlefonts/naming
Browse files Browse the repository at this point in the history
Fix name and add ref
  • Loading branch information
anthrotype authored Feb 14, 2025
2 parents 0f70a6d + bcbf047 commit 50917d5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion glyphs-reader/src/font.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2599,7 +2599,8 @@ impl Font {
&self.masters[self.default_master_idx]
}

pub fn instance(&self, master: &FontMaster) -> Option<&Instance> {
/// <https://handbook.glyphsapp.com/exports/>
pub fn variable_export_settings(&self, master: &FontMaster) -> Option<&Instance> {
self.instances
.iter()
.find(|i| i.active && i.type_ == InstanceType::Variable && i.name == master.name)
Expand Down
2 changes: 1 addition & 1 deletion glyphs2fontir/src/source.rs
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ impl Work<Context, WorkId, Error> for StaticMetadataWork {
.map(|bits| bits.iter().copied().collect());

let default_master = font.default_master();
let default_instance = font.instance(default_master);
let default_instance = font.variable_export_settings(default_master);
if let Some(raw_panose) = default_instance
.and_then(|di| di.custom_parameters.panose.as_ref())
.or(default_master.custom_parameters.panose.as_ref())
Expand Down

0 comments on commit 50917d5

Please sign in to comment.