How to insert a new Tab on default ArchiCad windows/Doors

Home Forums Problems and solutions in GDL Doors and windows How to insert a new Tab on default ArchiCad windows/Doors

This topic contains 9 replies, has 4 voices, and was last updated by  Pavel Čapek 1 year ago.

  • Author
    Posts
  • #1991

    Daniel Virtic
    Participant

    Hello everyone.

    I am trying to add some custom settings to an existing ArchiCad window/door.

    Is there a way to add a new tab to appear next to the existing tabs?. Or to create a new one. Please see attached screenshot.

    At the moment I am not able to do it.
    There are a lot of call functions, using few macro objects.

    If I write something on the Interface script i am not able to see it.

    Any advices will be greatly appreciated.

    Thank you.

    Attachments:
  • #1997

    Dominika Bobály
    Keymaster

    The screenshots were taken in AC18, right? If so, do the following steps:

    1. from the master script of the door, open “gs_general_lt_door_macro” macro
    2. look for ! Tabpage Structure Definition part of the UI script in the macro
    3. find the last tabpage definition (which is the Parameters for Listing in general, displayed in every DW object):
      gs_stUI = titleListing:				gs_icoUI = "ui_tabpage_listing(13)":				gs_idUI = 0: i=i+1
      
    4. duplicate it with copy-paste, and fill up according to your new tabpage, for example:
      gs_stUI = “My Tabpage Title”: gs_icoUI = “nameOfMyPageIcon”: gs_idUI = 0: i=i+1
      Leave the gs_idUI with 0 value. The “GS Door Functions” macro handles the pages with fix IDs (non zero), while the rest of the pages get their ID in the returned parameters of the macro call in variables like myPage_9. There are 20 slots for extra pages. Just add a new return value for your new page, myPage_10 in doors, for example. That will be the last used index.
    5. look for the variable myPage_ListingId in the script, and wherever you find it with value assignation, do the following (in cases you want to insert your page, depending on the existing conditions):
      myPage_ListingId			= myPage_9
      myPage_NewPageId			= myPage_10 !always the next index after the listing one
      
    6. Do this in all the needed places. This ensures the continuous indexing of pages, so the Prev-Next buttons will work for your new page as well. I think the best is to include it into every condition to make sure (7 or 8 places alltogether).
    7. look for the line if myPage_ListingId > 0 then. This is a condition to show the Parameter for Listing page. Copy-paste the whole condition, and modify to fit your new page:
      if myPage_NewPageId > 0 then
      	ui_page myPage_NewPageId
      	! your UI script here
      endif
    8. You can either code the content of the page there, or create a macro and call it from within the condition.

      This should work for AC18. Look for similarities in window macros as well (almost the same).
      If you need solution for AC19, let me know, because that is a lot different (and a bit more flexible).

    Dominika Bobály
    Library Developer, Library Team
    GRAPHISOFT SE

    • #2711

      Pavel Čapek
      Participant

      Hello, I respond on previous post.

      If you need solution for AC19, let me know, because that is a lot different (and a bit more flexible).

      Please let me know solution for AC19 and if I may solution for AC17 also.
      Thanks, Pavel

      Pavel Čapek
      senior developer
      BIM Project

  • #1998

    Daniel Virtic
    Participant

    Thank you Dominika. I’ll try it.

  • #2052

    Doug Thornton
    Participant

    If you need solution for AC19, let me know, because that is a lot different (and a bit more flexible).

    Hi Dominika. I don’t mean to hijack this thread but I’m working with AC19. I’ve read (and seen) that the “All Parameters” option was removed. As far as I can see the only parameters that can be altered and show in the UI are the listing parameters.

    I have several custom objects that the user manipulates with custom parameters. Is there a way to show custom, user created parameters or is the custom UI the only option?

    Thanks for your time,
    Doug

    • #2054

      Dominika Bobály
      Keymaster

      Doug,
      not sure if I understand right.. the All Parameters List option is not really removed, we just started to use the hideparameter command (with the all parameter) to omit it in most of GRAPHISOFT’s objects for better-looking interfaces. This is optional. If you create objects only using the All Parameters list, that’s fine. If you want to have an UI along the All Parameters list, that is also possible (without doing anything special). The special thing is only needed to hide the list (hideparameter command).
      If you need further info, give me an example or a more detailed specification. Thanks.

      Dominika Bobály
      Library Developer, Library Team
      GRAPHISOFT SE

      • #2055

        Dominika Bobály
        Keymaster

        More about the complete parameter list hiding is here (end of the topic). I should really link this to the UI section of Learning as well:)

        Dominika Bobály
        Library Developer, Library Team
        GRAPHISOFT SE

      • #2094

        Doug Thornton
        Participant

        Thanks Dominika. I didn’t specify that the object in this case is an AC19 window. I save the window as one of my standard windows and make changes, adding parameters and scripting as needed. When I place the window and try to see these new parameters in the properties dialog I’m unable to find them.

        I hope this is more clear.

        Doug

      • #2103

        Dominika Bobály
        Keymaster

        Doug,
        the fast solution to your problem is to unlock the “All parameters” list in windows: open your saved window, find the macro call for “gs_general_window_macro”, open that macro, and look for the macro call for “GS Corner Window Functions” (or “GS Window Functions” in some cases) in its parameter script. Open it, and comment the hideparameter all line in its paramscript (don’t forget to save: probably the easiest way to do this is to extract the library lcf to make it all writable). This will give you the All Parameters list back, where you can look for your new parameters.
        To add them to the UI: if they are property parameters, I would insert them into the already existing Descriptions page (the macro of it is in “gs_general_window_macro”, called “ui_Description_m”, look for it in the UI script). Your new parameters should be added to the macro as well, and must be taken care of in the UI script of the macro, similar to the other, existing property parameters.
        Hope this helps. Ask, if you need more specific assistance, or you want to create a separate page for your new parameters only.

        Dominika Bobály
        Library Developer, Library Team
        GRAPHISOFT SE

  • #1999

    Dominika Bobály
    Keymaster

    It is not possible to put pages outside of the Custom Settings group in AC18. You can only add pages within that (see my other reply).

    Dominika Bobály
    Library Developer, Library Team
    GRAPHISOFT SE

You must be logged in to reply to this topic.