diff options
Diffstat (limited to 'src/ee/kicad/model.py')
-rw-r--r-- | src/ee/kicad/model.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/ee/kicad/model.py b/src/ee/kicad/model.py index f112e72..b230f94 100644 --- a/src/ee/kicad/model.py +++ b/src/ee/kicad/model.py @@ -105,6 +105,10 @@ class Component(object): return self.ref_type == "#PWR" @property + def is_flg(self) -> bool: + return self.ref_type == "#FLG" + + @property def value(self): return self._fields[1].value @@ -120,6 +124,11 @@ class Component(object): def named_fields(self): return [f for f in self._fields if f.name] + def get_field(self, name) -> ComponentField: + for f in self.fields: + if name.lower() == f.name.lower(): + return f + class Sheet(object): def __init__(self): |