Masked components with nine.dnom not exporting

Hi Forum!

I’m having issues exporting a variable file because of black-circled numbers containing the glyph nine.dnom. I double checked:

  • Components are the same
  • Node count and order are compatible, ever after removing overlaps in the source glyphs
  • Mask option is checked in both Masters, Reversed disabled

Any clue why this happens?

Can you send me the file?

1 Like

Sent! Thanks for taking a look into this

The problem is that the mask is computed by removing overlap. That can change the starting point. I’ll look into it.

For now, it is easier to use the “Reverse” option.

1 Like

Got it, thanks! On another note, is there any script that toggles the mask/reverse option without having to select the components in each and every layer?

Paste this in the Macro Window and press Run:

for l in Font.selectedLayers:
	count = 0
	for c in l.components:
		if c.attributeForKey_("mask"):
			count += 1
			c.removeAttributeForKey_("mask")
			c.setAttribute_forKey_(1, "reversePaths")
	print("%s: %i components reversed." % (l.parent.name,count))
print("Done.")

It will turn Mask off and Reverse on for all components with the Mask option in selected glyphs.

1 Like

Amazing, thanks!

1 Like

Hi there, I wanted to follow up on this as Reversed components don’t seem to export as they should in variable fonts. Any clue why? It used to work just fine till the latest export and it affect 6 out of 9 numbers.

Thanks for your time!

Can you send me the file?

1 Like

Sent, thanks!

Also, I’m looking at some nested components with intermediate layers and they don’t seem to apply to the final glyphs. Here’s an example, see the 1:

The Intermediate layers for 1 and 3 are the same so they should look similar, instead the 1 seems lighter.

Any luck finding the issue?

Glyphs with multiple components that each have brace layers are difficult. Can you try the latest cutting edge version?

1 Like

Tried it, still not working, unfortunately

Can you send me the file?

1 Like

Sent it

Any update on this? :slight_smile:

You are using the .dnom figures inversed on black background. In all instances in Font Info > Exports, remove the Filter and add a PreFilter with the following code:

RemoveOverlap; include: zero.dnom, one.dnom, two.dnom, three.dnom, four.dnom, five.dnom, six.dnom, seven.dnom, eight.dnom, nine.dnom, zero.dnom.perthousand

Then it works for me:

1 Like

Thanks for the hint! This solves the .otf overlaps but doesn’t apply to the VF instance, in which the figures are still not exporting. I could remove overlaps manually but the shapes would change in the interpolations.

Yes. You will have to prepare the shapes more for a VF export. This may include decomposition and overlap removal.