Skip to content

Setup & Requirements

Python Version

LinkCAD 11 ships with an embedded Python 3.11 interpreter. No separate Python installation is required.

Plugin Location

Place Python plugin files (.py) in one of these directories:

  • User plugins: %APPDATA%\LinkCAD\plugins\
  • System plugins: <LinkCAD install dir>\plugins\

LinkCAD scans these directories on startup and registers any plugins it finds.

Accessing the Console

Open the interactive Python console from the menu:

  • View → Python Console (Ctrl+Shift+P)

The console provides full access to the linkcad package and the currently loaded drawing.

Script Editor

LinkCAD includes a built-in script editor:

  • View → Python Script Editor (Ctrl+Shift+E)
  • Run the current script with F5
  • Run the selected text with Ctrl+Enter

Package Structure

The linkcad Python package provides three modules:

Module Purpose
linkcad.plugin Plugin framework — decorators, options, base classes
linkcad.db Drawing database — cells, layers, shapes, transactions
linkcad.geom Geometry primitives — points, vectors, transforms, bounds

Installing Additional Packages

You can install additional Python packages using pip in the LinkCAD Python environment:

import subprocess
subprocess.check_call(["pip", "install", "numpy"])

Note

Only pure-Python packages are guaranteed to work. Packages with C extensions may require matching the embedded Python version and architecture.