Jump to content

Recommended Posts

"Widget Groups - Say goodbye to endless scrolling that creates a long and tedious workflow. We now offer widget groups in the Object Info palette that allow you to collapse and expand specific groups according to your preferences."

 

Are these accessible by vector script? Where can I find documentation?

Edited by Thomas Wagensommerer

Share this post


Link to post

They are available for Vectorscript and Python. But only on action-driven PIO's.

You also need to add the parameters in the order they need to appear and with the necessary indents:

 

You'll need some extra lines in the event section of the script. I also run a procedure in that part: "object_info_palet". This one holds some extra procedures to create the parameters and separators with the needed indentation. Hope this helps:

 

CASE theEvent OF
        kOnInitPropertiesEventID:
            BEGIN
                bTest := SetObjPropCharVS(kWidgetGroupMode, Chr(kWidgetGroupAutomatic));
                object_info_palet;
            END;

...

function insert_separator(liID: integer; lsPIOName, lsParameter: string; liIndent: integer): integer;
    var
        lbResult:    boolean;
        lsTmp:    string;
    begin
        lbResult := GetLocalizedPluginParameter(lsPIOName, lsParameter, lsTmp);
        if lbResult then begin
            lbResult := vsoAddWidget(liID, 100, lsTmp);
            lbResult := vsoAppendWidget(100, liID, lsTmp, 0);
            vsoWidgetSetIndLvl(liID, liIndent);
        end;
        insert_separator := liID+1;
    end;


function insert_parameter(liID: integer; lsPIOName, lsParameter: string; liIndent: integer): integer;
    var
        lbResult:    boolean;
        lsTmp:    string;
    begin
        lbResult := GetLocalizedPluginParameter(lsPIOName, lsParameter, lsTmp);
        if lbResult then begin
            lbResult := vsoAddParamWidget(liID, lsParameter, '');
            lbResult := vsoAppendParamWidget(liID, lsTmp, 0);
            vsoWidgetSetIndLvl(liID, liIndent);
        end;
        insert_parameter := liID+1;
    end;

 

procedure object_info_palet;
    var
        liID:    integer;
    begin
        liID := 100;
        liID := insert_separator(liID, sPIOName, 'chGlobal', 0);
        liID := insert_parameter(liID, sPIOName, 'ObjType', 1);

        
        liID := insert_separator(liID, sPIOName, 'ch3D', 0);
        liID := insert_parameter(liID, sPIOName, 'DivSymbol3D', 1);

        ...

   end;

 

 

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


 

7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114

 

© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

×
×
  • Create New...