stemHist error

RoboFont Forums Bugs stemHist error

This topic contains 1 reply, has 2 voices, and was last updated by  frederik 6 years, 4 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #5909

    Jack Jennings
    Participant

    Running:

    
    from mojo.compile import *
    
    stemHist(CurrentFont().path)
    

    Produces:

    
    Traceback (most recent call last):
      File "<untitled>", line 3, in <module>
      File "mojo/compile.pyc", line 57, in stemHist
    TypeError: autohint() got an unexpected keyword argument 'useCurves'
    

    Not sure if I’m doing it wrong but it seems to want a file path?
    There’s also a typo in the docs. stemHist is documented as having a “userCurves” kwarg.

    #5910

    frederik
    Keymaster

    oh, oeps, idd typo, it was redirecting to autoHint instead of stemHist… (will be fixed in the next update)

    stemHist takes a binary path as argument.

    and has optional arguments:
    * useCurves=Bool: Include stems formed by curved line segments; by default, includes
    only stems formed by straight line segments.
    * blueZones=Bool: Return alignment zone report rather than stem report

    this is a Adobe FDK tool.

    The mojo module is just a collection of useful internal modules. You can also use this:

    from lib.tools.compileTools import stemHist
    
    print stemHist("binaryPath.otf", useCurves=True, blueZones=False)
    

    good luck

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.