# Grid Builder for Adobe Illustrator Construction grid generator for logos, icons, and marks. Creates the geometry as **guides** on a dedicated locked layer, with anchors positioned so Illustrator's native snapping catches every intersection — without cluttering the document with objects. Single script, no installer, no dependencies. Free and open-source under the MIT license. ![version](https://img.shields.io/badge/version-1.0-blue) ![license](https://img.shields.io/badge/license-MIT-green) --- ## Index - [Quick Start](#quick-start) - [Permanent Installation](#permanent-installation) - [Grid Families](#grid-families) - [How Snapping Works](#how-snapping-works) - [Configuring Snap in Illustrator](#configuring-snap-in-illustrator) - [Area and Positioning](#area-and-positioning) - [Presets](#presets) - [Output: Guides or Strokes](#output-guides-or-strokes) - [Compatibility](#compatibility) - [Known Limitations](#known-limitations) - [License](#license) --- ## Quick Start 1. Download `Grid_Builder_V1.jsx`. 2. Open a document in Illustrator (the script requires an open document). 3. **File > Scripts > Other Script...** — shortcut `Ctrl+F12` on Windows, `Cmd+F12` on macOS. 4. Select the `.jsx` file. The panel opens instantly. 5. Choose a preset under **Built-in Grids**, click **Apply** and then **Generate**. No administrator permission or restarting Illustrator is required. ## Permanent Installation For the script to appear directly in the **File > Scripts** menu, copy the `.jsx` file to your installation's scripts folder. **Windows** (requires PowerShell as administrator — the folder is in `Program Files`): ``` C:\Program Files\Adobe\Adobe Illustrator 2025\Presets\en_US\Scripts\ ``` **macOS**: ``` /Applications/Adobe Illustrator 2025/Presets.localized/en_US/Scripts/ ``` Adjust the year to your version. The subfolder is your **installation locale**, which is often `en_US` even if the interface is in another language — check what exists inside `Presets` before copying. Restart Illustrator after copying. > If you plan to edit the script, prefer `Ctrl+F12`: the installed copy does not reflect edits made to the original file. ## Grid Families | Family | Use Case | |---|---| | **Modular / square** | Mesh with subdivisions, diagonals, and inscribed circle. The foundation of any geometric logo. | | **Icon Keyline** | Square + circle + vertical/horizontal rectangles with rounded corners, following the Material/iOS standard. Compensates for the optical illusion of area between different shapes — a circle of the same height as a square *appears* smaller. | | **Radial / concentric** | Rings + rays. Monograms, seals, marks with rotational symmetry. Ring spacing can be linear, square root (equal areas), or golden ratio. | | **Golden / Fibonacci** | Nested golden rectangles, squares, spiral, inscribed circles, and concentric φ circles. | | **Flower of Life** | Overlapping circles in a hexagonal grid. 2 rings = the classic 19 circles. | | **Isometric / triangular** | Three families of lines at 60° to each other. 30° creates isometric, 0° creates triangular, any angle is accepted. | Includes **15 built-in presets** covering the most used ones in brand construction: 8×8 modular with diagonals, 24 and 48 icon keyline, 12 and 16 radial, seal with golden rings, 9-step golden spiral, Fibonacci circles, flower of life, isometric, and triangular. ## How Snapping Works This is the part that defines the tool's quality. The naive approach would be drawing continuous lines and scattering loose points over them to provide snap targets. That clutters the document with thousands of objects and makes snapping inconsistent. Here, the geometry is built so that **a real anchor exists at every intersection**: - **Grid lines** are segmented at every crossing. A horizontal line of a 16×16 grid does not have 2 points, it has 17 — one in each column. - **Circles** are beziers with a number of anchors equal to the number of angular divisions. In a 12-division radial grid, each ring has exactly 12 anchors, one on top of each ray. The radial error of this approximation is 0.00004% of the radius with 12 anchors — irrelevant at any working scale. - **Center marks** are 3-point crosshairs, with the middle anchor exactly on the target. Result: a complete 16×16 grid has **34 objects and 578 snap points**. ## Configuring Snap in Illustrator The script tries to turn on preferences automatically, but the keys are undocumented by Adobe and change from version to version. **Confirm in the menu:** - **View > Snap to Point** — snaps to the anchors of the guides. This is the main one. - **View > Smart Guides** (`Ctrl+U` / `Cmd+U`) — shows alignments and catches intersections and tangents. - Tolerance in **Edit > Preferences > Selection & Anchor Display > Snapping Tolerance**. 2 to 4 px is usually good; above that, the cursor "fights" with you in dense grids. **Do not turn on Snap to Grid alongside these.** It uses Illustrator's document grid, not the generated grid, and they conflict with each other. ## Area and Positioning - **Fit to artboard** — uses the active artboard's smallest dimension × a percentage. - **Custom size** — side length in pt, px, mm, cm, or in. - **Use selection** — uses the longest side of the selection's bounding box. The center can be the active artboard or the center of the selection. Useful for fitting a radial grid over an existing drawing. ## Presets Besides the 15 built-in ones, you can save your own. They are stored in: | System | Path | |---|---| | Windows | `%APPDATA%\GridBuilder\presets.jsxdata` | | macOS | `~/Library/Application Support/GridBuilder/presets.jsxdata` | It is a plain text file — you can version it, edit it manually, or share it with the team. Built-in presets cannot be deleted. ## Output: Guides or Strokes - The layer is named `GRID · ` and is locked at the end. The **Clear grids** button removes all layers with this prefix. - In **guide mode** (default), the geometry does not print or export, and disappears in Preview mode (`Ctrl+Y` / `Cmd+Y` toggles). - By turning off **Create as guides**, you get real paths with strokes (configurable color and thickness) in a layer marked as non-printing. Useful for presenting the construction study alongside the final mark. ## Compatibility Written in ExtendScript, developed for Illustrator CC 2021 or newer. It uses no recently introduced APIs, so it should work in much older versions (CS6 onwards), but this hasn't been tested. If you run it on an older version, feedback is welcome. Windows and macOS. ## Known Limitations - **Guides don't have a per-object color.** In Illustrator, guide color is global, set in **Preferences > Guides & Grid**. The color field in the panel only affects the stroke mode. - **Very dense grids lag.** Modular above ~60 divisions or isometric above ~40 take a few seconds and make the canvas slow. The modular has a hard cap of 120 total divisions. - **The panel is modal.** You can't adjust parameters with the document visible, nor is there a live preview. Generate, look, undo (`Ctrl+Z`), and generate again is the workflow. ## Reporting Issues When reporting a bug, include the Illustrator version, operating system, grid family, and parameters used. If the script showed an error alert, copy the entire message. ## License MIT — see [LICENSE](LICENSE). Free for use, including commercial. You can modify and redistribute it, as long as you keep the copyright notice. Made by **samuelmendes**.