• 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. Custom IC SKILL
  3. After creating dockable window containing a form, how to...

Stats

  • Locked Locked
  • Replies 9
  • Subscribers 143
  • Views 7734
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

After creating dockable window containing a form, how to locate and delete in order to recreate the dockable window and form

blankman
blankman over 1 year ago

Hi,

I am trying to create a dockable window in layout window containing a form, however I am running into the issue after creating the window/form, that when the "x" top right of the dockable window is pressed, it doesn't actually close the window, but hides it. To be able to unhide the window after it is hidden, I need to re-create the window&form by again calling the procedure, however in order for this to work, I must first locate and delete the originally created dockable window and form. This is where I have the question. Does anyone know how to find and delete the original dockable window and form? Below is an outline of the code I am using to create the window.

Thanks and regards,

Brian.

-------------------------------------------------

After defining a form within a procedure: "dockForm()"


procedure(dockFormDisplay()

myForm1= dockForm()

myDockW=hiCreateDockWindow( ?appType "text" ?widgetType "form" ?title "Form" ?form myForm1)

hiDockWindow( ?window myDockW ?session hiGetCurrentWindow()->sessionWindow ?side 'left )

)

  • Cancel
Parents
  • blankman
    blankman over 1 year ago

    Edit, to give more information: when I call the above code for the 1st time in a session, it loads the docked form fine, however when I recall the above code in a session I get the following errors in CIW:

    *WARNING* hiCreateAppForm: Could not delete already created form dockForm
    *WARNING* hiCreateDockWindow: formStruct@0x28a35d28 has been instantiated. Same form can not exist in more than one form or window.
    *Error* hiDockWindow: argument for keyword ?window should be a window type (type template = "wgsxg") - nil

    Thus I believe I need to locate and close both the form and docked window in order to create the docked window again. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • blankman
    blankman over 1 year ago

    Edit, to give more information: when I call the above code for the 1st time in a session, it loads the docked form fine, however when I recall the above code in a session I get the following errors in CIW:

    *WARNING* hiCreateAppForm: Could not delete already created form dockForm
    *WARNING* hiCreateDockWindow: formStruct@0x28a35d28 has been instantiated. Same form can not exist in more than one form or window.
    *Error* hiDockWindow: argument for keyword ?window should be a window type (type template = "wgsxg") - nil

    Thus I believe I need to locate and close both the form and docked window in order to create the docked window again. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • blankman
    blankman over 1 year ago in reply to blankman

    Update: I have now managed to resolve the issue with the following code, this allows for the dockable window to be created, and then if the “x” is pressed top right of docked window, it will “re open” (re map) the docked window.

    However this brings 2 further issues…

    1: this only works on 1 layout window. When called from a second window after already being called from the first, it doesn’t work.

    2: also, when called from the 1st layout window, and that window is then closed: when then called in a second opened layout window, I get the following error message:

    *Error* hiMapWindow: Invalid window - window(invalid):649201536(destroyed)

     

    I believe I need to first check within the current session window if the docked form has been created, and depending on that, either 1: create it within that session window, or 2: map the docked window using hiMapWindow, to ensure anytime the function is called within that session window that the docked window appears. But the knack being it needing to check uniquely within each opened layout session window. Simple enough, but from a skill perspective does anyone know how to implement the correct coding/syntax etc?

     

    Also, for the hiDockWindow command, does anyone know how to get the dock window to dock to the north of other windows on that side of the screen? ie to the north of the layer palette, as opposed to the south (underneath)? It appears this can be done using the ?index parameter within hiDockWindow, however the correct value to use is not clear.

    Additionally, is it possible to set the height at which the docked window will be opened at once docked, ie how much vertical real estate the docked window will be given upon being docked?

     

    Finally, using the command hiUndockWindow to then un dock the window, is it possible to set the x/y dimensions and screen position that the window will be undocked to?

     

    Thanks in advance,

    Brian.

    ------------------------------------------------------

    ------------------------------------------------------

    procedure(TestForm()

       text1=hiCreateOutputStringField(

            ?name 'text1

            ?prompt "Test Form\n"

            )    

     

        myForm=hiCreateAppForm(

            ?name gensym('TestAppForm)

            ?formTitle "Test App Form"

            ?fields

            list(

                list(text1 19:0 56:25 56)

                )

            )

        myForm

    )

     

    procedure(callForm()

                    when(boundp('myDockW)

                                    hiMapWindow(myDockW)

                    )

                   

                    unless(boundp('myDockW)

                                    myForm1=TestForm()

                                    myDockW=hiCreateDockWindow( ?appType "text" ?widgetType "form" ?title "Test App Form Window" ?form myForm1)

                                    hiDockWindow( ?window myDockW ?session hiGetCurrentWindow()->sessionWindow ?side 'left ?index 0)

                    )

    )

     

    hiSetBindKey("Layout" "Ctrl<key>#" "callForm()")

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

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