Xsection - absence of "moved" method

I was trying to visualize alignment error using xsection emulator. But there is only "sized" method which introduces bias isotropically or anisotropicallt, but there is no "moved" method to just move the initial layout. Am I missing something? And if not, is there a work around on how to get the layer to move to emulate alignment error within xsection script without modifying the original layout?


  • Hi @ResuS,

    No, there is no "moved" and I have stopped work on XSection.


  • Hi Matthias,
    Alright. I was able to create such "moved" method and tried to code it in your style (but with my limited skills). Xsections are correctly generated with this addition to layout_data.rb and I am getting exactly what I want.

        #Use moved if you want to return a new LayoutData object with the polygons moved.
        def moved(*args)
          if args.length == 2
            # Create a transformation object with the specified x and y shifts
            transform = RBA::ICplxTrans::new(1, 0, false, args[0] / @xs.dbu, args[1] / @xs.dbu)
            # Apply the transformation to polygons and return a new LayoutData object
            upcast(@polygons.collect { |p| p.transformed(transform) })
            raise("moved method expects two arguments, namely x and y shifts")
Sign In or Register to comment.