Home > Community > Forums > Custom IC SKILL > Get current command option

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 Get current command option 

Last post Fri, Sep 21 2012 7:48 AM by Andrew Beckett. 3 replies.
Started by psill 20 Sep 2012 12:49 PM. Topic has 3 replies and 829 views
Page 1 of 1 (4 items)
Sort Posts:
  • Thu, Sep 20 2012 12:49 PM

    • psill
    • Top 500 Contributor
    • Joined on Sun, Mar 25 2012
    • Posts 24
    • Points 420
    Get current command option Reply

    Is there a better way of getting the current command option than from the command option gui?

    Is there a celliew/window variable that has the current option and the other command options?

    Example of part of the script:

     case( hiGetCurrentCmd(hiGetCurrentWindow())

                  ("Stretch"
                            unless(boundp('leStretchForm) hiDisplayForm(leStretchForm))
                            if(hiIsFormDisplayed(leStretchForm) hiiToggleEnterForm(leStretchForm))
                            theForm         = leStretchForm
                            currOpt         = theForm~>keepWiresConnected~>value
                            optList         = theForm~>keepWiresConnected~>items
                            unless(dirBool optList = reverse(optList))
                            optAssoc        = buildOptList(optList)
                            nOpt            = cadr(assoc(currOpt optAssoc))
                            theForm~>keepWiresConnected~>value = nOpt
                            printf("Set option %s\n" nOpt)
                            hiChangeBannerLabel(win sprintf(nil "%s\n" nOpt) 0)
                    )

     

    • Post Points: 20
  • Thu, Sep 20 2012 1:03 PM

    Re: Get current command option Reply

    I don't really know what you mean by the "current option and the other command options". What are you actually trying to do?

    Andrew.

    • Post Points: 20
  • Fri, Sep 21 2012 7:41 AM

    • psill
    • Top 500 Contributor
    • Joined on Sun, Mar 25 2012
    • Posts 24
    • Points 420
    Re: Get current command option Reply
     In the command Stretch, when you bring up the command option,  hiToggleEnterForm(), for the type of stretch you want the tool to perform; All wires and vias,  Spine wires only,  No wires and vias.

    Is there an environment variable that has the command options list. I did not see a variable that has the information of the command option from  hiGetCurrentWindow()~>? or geGetWindowCellView()~>?

    It is not big a deal to get the information from the command option gui, but I thought it would be better code to get the information from an environment variable.

    psill
    • Post Points: 20
  • Fri, Sep 21 2012 7:48 AM

    Re: Get current command option Reply

    There's no such thing as a general list of options for each command. Each command will have encoded necessary options onto the options form, but how that has been done is specific to each command.

    Andrew

    • Post Points: 5
Page 1 of 1 (4 items)
Sort Posts:
Started by psill at 20 Sep 2012 12:49 PM. Topic has 3 replies.