TraceMaker
C++ API of the engine
Loading...
Searching...
No Matches
project_reader.hpp File Reference

Reads design rules from a KiCad project: <name>.kicad_pro (JSON) and <name>.kicad_dru (s-expressions). More...

#include <string>
#include "model/rules.hpp"

Go to the source code of this file.

Namespaces

namespace  tmk
namespace  tmk::io

Functions

model::DesignRules tmk::io::read_design_rules (const std::string &board_path)
 board_path is the .kicad_pcb; the project and rule files are looked up next to it with the same stem.
std::optional< Coord > tmk::io::parse_length (std::string_view s)
 Parses a KiCad length with an optional unit suffix ("0.2mm", "8mil", "0.01in", "150um", "0.2") to nm.

Detailed Description

Reads design rules from a KiCad project: <name>.kicad_pro (JSON) and <name>.kicad_dru (s-expressions).

Definition in file project_reader.hpp.