Script Windows

Use the scripting windows of the GDL Object Editor to edit object scripts.

If you click the script name (e.g. Master), you edit right in the GDL Editor window

If you click on the window icon next to the script name, you open a separate scripting window

ScriptWindows.png 

The Master Script will be executed each time any of the other scripts are executed. The primary benefit of this script is that you can globally define variables or operations, or access external data before executing other Scripts.

In the 2D Script window, you can create a parametric 2D symbol using the transformations and elements available for the two-dimensional space in GDL. This script will be used to generate the 2D Full View of the Object.

In the 3D Script window, you can find and edit the 3D description of the GDL Object. The script will be used to generate the 3D View of the Object.

With the Property Script, you can attach descriptions and technical data to the Object using its variables and the related GDL commands and expressions. Component quantities (weight, price, paint, etc.) can be calculated according to the expressions in the Properties Script and included in the lists. To use the custom Properties Script as the default in the element’s settings dialog box, click the Set as Default button at the top of the screen.

Note: When there is a Property Script defined, the listing commands will use this script, even if you previously created Components and Descriptors in the corresponding sections of the dialog box.

Using the Parameter Script, you can define the choices available as a value of a given parameter. For example, you can restrict the choice of the surface of a table top to wooden surfaces, or define the different panel styles of a given door by their name.

The Interface Script allows you to define a custom user interface for your GDL Objects, including the graphic explanation of additional parameters. If an Interface Script exists, the settings dialog box of the given library part will include a Custom Settings panel. To use the custom Interface Script as the default in the element’s settings dialog box, click the Set as Default button at the top of the screen.

Forward/Backward Migration Scripts: Click the Forward Migration or Backward Migration buttons to define how to migrate the parameters of an old instance forward to the current open element (or backward to an older element).

Autocomplete

While you type, use the suggested auto-complete (all GDL commands and parameters are there) to make your work easier.

At the top of all script windows, some commonly used functions:

Note: Some of these commands are also available from the Archicad Edit menu (if a script window is active).

See also Editing Commands in Text-Type Windows.

Check Script

Check syntax of the GDL script in the active window. To check all scripts of the current Library Part, use this command in the Master script window.

CheckScript.PNG 

Commands

GDL_CommandsButton.png 

Click to access common script editing commands, including:

Code folding: This feature allows you to collapse and expand sections of code, making it easier to navigate through large files.

Multiple cursors: This feature allows you to place multiple cursors in different parts of your code, so you can edit multiple lines at the same time.

Find and replace

Comment/Uncomment

CommentUncomment.png 

Transform selected lines into comments and vice versa.

Open Macro in another script window

In the script window, select the macro text (preceded by “call”) and click Open Object.

CallMacro.png 

This opens the macro script for editing.

If nothing is selected, this command opens the Open Object dialog.

Dark Mode

Toggle dark mode on-off.

GDL_DarkMode.png 

Generate Script based on Floor Plan selection

GenerateScript.png 

Use this while working in the 2D or 3D GDL script window.

Select an element in the Floor Plan window.

Return to GDL Editor window (2D or 3D script window) and click the command to “Generate 2D-3D script”.

Interface Script Window

GDL_InterfaceScriptButtons.png 

Preview - See a preview of the Interface you are creating.

Hierarchical Pages - Turn on hierarchical tab page structure.

Set as Default - Use the current Interface settings as default.