Closed LibertyType closed 6 years ago
The plugin is does not work on the recent Glyphs version also; Version 2.5b (1105)
I just tested the new merge and find it has its own (new) problem: it won't measure the outline if it is round. See the attached testfile. Test file for Stem Thickness.glyphs.zip
have fixed it with https://github.com/RafalBuchner/StemThickness/pull/10
The plugin doesn’t work for me neither Glyphs Version 2.5b (1105)
Traceback (most recent call last): File "GlyphsApp/plugins.py", line 1128, in drawForegroundForLayeroptions File "/Users/xxxxx/Library/Application Support/Glyphs/Plugins/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 100, in foreground closestData = self.calcClosestInfo(layer, crossHairCenter) File "/Users/xxxxx/Library/Application Support/Glyphs/Plugins/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 270, in calcClosestInfo TangentDirection = calcTangent(closestPathTime % 1, segment) File "/Users/xxxxx/Library/Application Support/Glyphs/Plugins/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 28, in calcTangent divided = divideCurve(segment[0], segment[1], segment[2], segment[3], t) NameError: global name 'divideCurve' is not defined
@synthview this is fixed in #10
Ok now it works thanks. Glyphs didn’t report any plugin update, so I though I already had the last version.
Still having issues:
Traceback (most recent call last): File "GlyphsApp/plugins.py", line 1128, in drawForegroundForLayeroptions File "/Users/georgethomas2/Library/Application Support/Glyphs/Repositories/StemThickness/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 99, in foreground closestData = self.calcClosestInfo(layer, crossHairCenter) File "/Users/georgethomas2/Library/Application Support/Glyphs/Repositories/StemThickness/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 264, in calcClosestInfo if OnNode.type == CURVE: AttributeError: 'NoneType' object has no attribute 'type' ERROR: crossPoint == ON CURVE POINT!!!!
That is a different problem. Can you reproduce it? If so, can you send the .glyphs file with that glyph?
I have determined that the "ERROR: crossPoint..." is no more than a warning, easily reproduced. It occurs when the value at the mouse pointer over a node reads 0.0, 0.00 or 0.000, but the error does not affect any valid measurements. I was able to reproduce it only on an extrema node on a horizontal curved path, never vertical. The warning really should be labelled as a warning rather than an error, or even disabled.
The other errors -- real ones (in red), all of which begin with line 1128 -- that crop up from time to time -- definitely are not easily reproducible in most cases* because I couldn't determine the cause, also don't affect any valid measurement that I can determine.
*This one is easily triggered: _File "GlyphsApp/GlyphsApp/plugins.py", line 1128, in drawForegroundForLayeroptions File "/Users/georgethomas2/Library/Application Support/Glyphs/Repositories/StemThickness/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 96, in foreground closestData = self.calcClosestInfo(layer, crossHairCenter) File "/Users/georgethomas2/Library/Application Support/Glyphs/Repositories/StemThickness/StemThickness.glyphsReporter/Contents/Resources/StemThickness.py", line 263, in calcClosestInfo n = math.floor(closestPathTime) TypeError: a float is required
It is caused by opening a character cell which contains an image link but no outlines.
So given all of this, for now I am closing this issue. If I get more information at a later date then I will open an issue at that time.
Glyphs 2.5b [1103] -- Change Log says some plugins may need updating because of this update. It appears this is one of them. When activated, it does not show stem information.