summaryrefslogtreecommitdiff
path: root/gerbonara/cad/kicad/layer_colors.py
diff options
context:
space:
mode:
authorjaseg <git@jaseg.de>2023-04-22 17:16:20 +0200
committerjaseg <git@jaseg.de>2023-04-22 17:16:20 +0200
commita93d118773818fbd47af4965d7b37e1b10bdf9b6 (patch)
tree528a06ac8154dfa70caa8714e7aa5ea62a51dd9f /gerbonara/cad/kicad/layer_colors.py
parent5ce88e4d1b06dcc846c94ec614fb00f64e85c125 (diff)
downloadgerbonara-a93d118773818fbd47af4965d7b37e1b10bdf9b6.tar.gz
gerbonara-a93d118773818fbd47af4965d7b37e1b10bdf9b6.tar.bz2
gerbonara-a93d118773818fbd47af4965d7b37e1b10bdf9b6.zip
kicad unit tests WIP
Diffstat (limited to 'gerbonara/cad/kicad/layer_colors.py')
-rw-r--r--gerbonara/cad/kicad/layer_colors.py70
1 files changed, 70 insertions, 0 deletions
diff --git a/gerbonara/cad/kicad/layer_colors.py b/gerbonara/cad/kicad/layer_colors.py
new file mode 100644
index 0000000..b4caa2d
--- /dev/null
+++ b/gerbonara/cad/kicad/layer_colors.py
@@ -0,0 +1,70 @@
+
+# Maps KiCad layer IDs to (r, g, b, a) color tuples. R, G, B are ints in [0...255], a is a float in [0...1]
+KICAD_LAYER_COLORS = {
+ 'F.Cu': (200, 52, 52, 1),
+ 'In1.Cu': (127, 200, 127, 1),
+ 'In2.Cu': (206, 125, 44, 1),
+ 'In3.Cu': (79, 203, 203, 1),
+ 'In4.Cu': (219, 98, 139, 1),
+ 'In5.Cu': (167, 165, 198, 1),
+ 'In6.Cu': (40, 204, 217, 1),
+ 'In7.Cu': (232, 178, 167, 1),
+ 'In8.Cu': (242, 237, 161, 1),
+ 'In9.Cu': (141, 203, 129, 1),
+ 'In10.Cu': (237, 124, 51, 1),
+ 'In11.Cu': (91, 195, 235, 1),
+ 'In12.Cu': (247, 111, 142, 1),
+ 'In13.Cu': (167, 165, 198, 1),
+ 'In14.Cu': (40, 204, 217, 1),
+ 'In15.Cu': (232, 178, 167, 1),
+ 'In16.Cu': (242, 237, 161, 1),
+ 'In17.Cu': (237, 124, 51, 1),
+ 'In18.Cu': (91, 195, 235, 1),
+ 'In19.Cu': (247, 111, 142, 1),
+ 'In20.Cu': (167, 165, 198, 1),
+ 'In21.Cu': (40, 204, 217, 1),
+ 'In22.Cu': (232, 178, 167, 1),
+ 'In23.Cu': (242, 237, 161, 1),
+ 'In24.Cu': (237, 124, 51, 1),
+ 'In25.Cu': (91, 195, 235, 1),
+ 'In26.Cu': (247, 111, 142, 1),
+ 'In27.Cu': (167, 165, 198, 1),
+ 'In28.Cu': (40, 204, 217, 1),
+ 'In29.Cu': (232, 178, 167, 1),
+ 'In30.Cu': (242, 237, 161, 1),
+ 'B.Cu': (77, 127, 196, 1),
+ 'B.Adhes': (0, 0, 132, 1),
+ 'F.Adhes': (132, 0, 132, 1),
+ 'B.Paste': (0, 194, 194, 0.9),
+ 'F.Paste': (180, 160, 154, 0.9),
+ 'B.SilkS': (232, 178, 167, 1),
+ 'F.SilkS': (242, 237, 161, 1),
+ 'B.Mask': (2, 255, 238, 0.4),
+ 'F.Mask': (216, 100, 255, 0.4),
+ 'Dwgs.User': (194, 194, 194, 1),
+ 'Cmts.User': (89, 148, 220, 1),
+ 'Eco1.User': (180, 219, 210, 1),
+ 'Eco2.User': (216, 200, 82, 1),
+ 'Edge.Cuts': (208, 210, 205, 1),
+ 'Margin': (255, 38, 226, 1),
+ 'B.CrtYd': (38, 233, 255, 1),
+ 'F.CrtYd': (255, 38, 226, 1),
+ 'B.Fab': (88, 93, 132, 1),
+ 'F.Fab': (175, 175, 175, 1),
+ 'User.1': (194, 194, 194, 1),
+ 'User.2': (89, 148, 220, 1),
+ 'User.3': (180, 219, 210, 1),
+ 'User.4': (216, 200, 82, 1),
+ 'User.5': (194, 194, 194, 1),
+ 'User.6': (89, 148, 220, 1),
+ 'User.7': (180, 219, 210, 1),
+ 'User.8': (216, 200, 82, 1),
+ 'User.9': (232, 178, 167, 1),
+}
+
+KICAD_DRILL_COLORS = {
+ ('drill', 'pth'): (194, 194, 0, 1),
+ ('drill', 'npth'): (26, 196, 210, 1),
+ ('drill', 'via'): (227, 183, 46, 1),
+}
+