Skip to content

Commit bff64b3

Browse files
committed
Handle substitutions in footprint text
Fixes #27
1 parent a11a057 commit bff64b3

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

InteractiveHtmlBom/generate_interactive_bom.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,9 +195,13 @@ def parse_text(d):
195195
else:
196196
height = d.GetHeight() * 1e-6
197197
width = d.GetWidth() * 1e-6
198+
if hasattr(d, "GetShownText"):
199+
text = d.GetShownText()
200+
else:
201+
text = d.GetText()
198202
return {
199203
"pos": pos,
200-
"text": d.GetText(),
204+
"text": text,
201205
"height": height,
202206
"width": width,
203207
"horiz_justify": d.GetHorizJustify(),

0 commit comments

Comments
 (0)