• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Allegro X Scripting - Skill
  3. Mirroring top to buttom

Stats

  • Replies 2
  • Subscribers 17
  • Views 9370
  • Members are here 0
More Content

Mirroring top to buttom

karthikeyan123
karthikeyan123 over 6 years ago

hai,

I would like to mirror top to bottom i attached   the code but that code mirrored left to right any one please recorrect the code send me please i am new to skill

axlCmdRegister("mirror_box" 'mirror_box ?cmdType "interactive")
symDBID = nil
procedure(mirror_box()
let( (symDBID UC_mbMark UC_mbPopup notdone)

axlSetFindFilter(?enabled '("NOALL" "SYMBOLS" "VIAS" "CLINES" "LINES" "SHAPES" "TEXT")
                       ?onButtons '("SYMBOLS" "VIAS" "CLINES" "LINES" "SHAPES" "TEXT"))
;; Set the Control Panel to the Find tab
axlControlRaise('find)   

    UC_mbMark = axlDBTransactionStart()


UC_mbPopup = axlUIPopupDefine( nil (list
     (list "Oops" 'UC_mbOops)
    (list "Mirror" 'UC_mbMirror)
        (list "Done" 'UC_mbDone)
      (list "Cancel" 'UC_mbCancel)
     ))
    axlUIPopupSet(UC_mbPopup)

    notdone = t
    while(notdone
          symDBID = axlGetSelSet(axlSelect(?prompt "Select objects to mirror"))
        axlDBTransactionMark(UC_mbMark)
          if(symDBID then
            axlTransformObject(symDBID, ?mirror t)
          ); endif
    ); end while   
)); let and procedure

procedure(UC_mbMirror()      
    axlTransformObject(symDBID, ?mirror t)
    axlClearSelSet()
);end procedure


procedure(UC_mbOops()
    axlDBTransactionOops(UC_mbMark)
    axlClearSelSet()
); end procedure

procedure(UC_mbCancel()
      axlUIWPrint(nil "** All changes Cancelled ! **")
      axlDBTransactionRollback(UC_mbMark)
      notdone = nil
      axlClearSelSet()
      axlCancelEnterFun()
    axlUIPopupSet( nil)
); end procedure

procedure(UC_mbDone()
     axlUIWPrint(nil "Done")
     axlDBTransactionCommit(UC_mbMark)
     notdone = nil
      axlClearSelSet()
     axlFinishEnterFun()
    axlUIPopupSet( nil)

); end procedure

  • Cancel
  • Sign in to reply
  • eDave
    eDave over 6 years ago

    This is not an easy task. As a beginner in Skill I suggest you try something easier.

    However, the code you need could be based on this:

    flipInY = t; or nil if you prefer

    loc = [pick a point]

    objs = axlGetSelSet(axlSelect(?prompt "Select objects to mirror"))

    mirroredObjs = axlTransformObject(objs, ?mirror t, ?angle when(flipInY, 180.0), ?origin loc)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • karthikeyan123
    karthikeyan123 over 6 years ago in reply to eDave

    Thanks for your reply dave,

    Sure dave i will choose easier task but for this case i want i don't know how to elaborate this can you share me the full skill code please.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Cadence Guidelines

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information