Repo re-org, now we are KiCad add-ons.

This commit is contained in:
jaseg 2023-10-23 16:13:48 +02:00
parent c4f176d3f4
commit c91ed4f594
14 changed files with 815 additions and 13 deletions

View file

@ -1,38 +0,0 @@
from os import path
import subprocess
import sys
import wx
import pcbnew
def check_requirements(*packages):
missing = []
for pkg in packages:
try:
__import__(pkg)
except ImportError:
missing.append(pkg)
if missing:
wx.MessageDialog(None, "Error: Missing python dependencies:\n\n{}".format('\n'.join(missing)),
"Missing Dependencies").ShowModal()
return False
else:
return True
class MeshPlugin(pcbnew.ActionPlugin):
def defaults(self):
self.name = 'Mesh generator'
self.category = 'Modify PCB'
self.description = 'Creates security mesh traces on a PCB'
self.icon_file_name = path.join(path.dirname(__file__), 'mesh_plugin_icon.png')
self.show_toolbar_button = True
def Run(self):
if not check_requirements('shapely'):
return
from .mesh_dialog import show_dialog
show_dialog(pcbnew.GetBoard())