fontParts icon indicating copy to clipboard operation
fontParts copied to clipboard

Allow `BaseGlyph.name = None`

Open knutnergaard opened this issue 9 months ago • 3 comments

Once a value has been set, BaseGlyph.name limits the input type to str and does not allow for the value to be reset to None.

Would this be possible to change? At least for testing purposes, the ability to reset the glyph name would be beneficial.

knutnergaard avatar Mar 21 '25 09:03 knutnergaard

Very hesitant to allow this, as one could very easily shoot themselves in the foot with this. Understand how it'd be good for testing, is there another way to allow this just in testing?

benkiel avatar Jun 04 '25 19:06 benkiel

Very hesitant to allow this, as one could very easily shoot themselves in the foot with this. Understand how it'd be good for testing, is there another way to allow this just in testing?

I see your point. I can't really remember why I thought this might be a good idea, but I think it could be acheived for testing quite simply by allowing users to pass a special boolean argument which can dictate the the normalization behavior.

knutnergaard avatar Jun 05 '25 11:06 knutnergaard

Will look into that, have an idea of how to make it work with a mixin

benkiel avatar Jun 05 '25 17:06 benkiel