Scripting Reference

Hi,

I just wrote my first KiCAD plugin and I find it really hard to find all the attributes for all the different types of objects. Like what attributes and functions do Modules have? A list of all the shapes (S_CIRCLE, S_ARC…). Where do you find these? I’ve tried reading this documentation (https://docs.kicad.org/doxygen-python/namespacepcbnew.html) but I can’t find anything useful…

How did you go about learning scripting for KiCad?

Many thanks!

This is a bit old, but still useful: https://kicad.mmccoo.com/kicad-scripting-table-of-contents/

You can also open the python console in PCBNEW and load the pcbnew module. Then start poking it with dir and help to see what you find.

Also, take a look at the source for any PCBNEW plugins listed here.

1 Like

You have doxygen generated reference at SetLayer(), TEXTE_PCB and API doc puzzles

Many thanks for the suggestions! I didn’t know the dir command, that helps a LOT!

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.