Transform Components



  • It would be great if components would be affected by transformations, at least scale/mirror. It is a bit cumbersome to edit the transformation matrix directly in the inspector window ;) Or is there an easier way I’m missing?


  • admin

    It's disabled by default cause transforming multiple glyphs can end up with a double transformation on glyphs with components, one time by the referenced glyph and other one by transforming the component itself.



  • Ah, sorry I was blind, I didn't find the "Transform Components" setting in the transform panel ;) Great!


  • admin

    The transformations are saved and stored as a transform matrix [xx, xy, yx, yy, x, y] and when ever there is a rotate or skew transform its impossible to revert the matrix back to readable, understandable and simple values like position, scale, rotation,....

    This can help to transform components: Use the transformation pane in the inspector, but be sure you enabled "Transform Components" in the transform pane option menu.

    or with code:

    g = CurrentGlyph()
    
    for component in g.components:
        center = (100, 100)
        component.rotate(50, center)
        # component.transalte((100, 100))
        # component.scaleTransformation((.3, .3), center)
    

Log in to reply