diff options
Diffstat (limited to 'pcbnew/scripting/examples/hidePcbValuesShowReferences.py')
-rw-r--r-- | pcbnew/scripting/examples/hidePcbValuesShowReferences.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/pcbnew/scripting/examples/hidePcbValuesShowReferences.py b/pcbnew/scripting/examples/hidePcbValuesShowReferences.py new file mode 100644 index 0000000..6b37842 --- /dev/null +++ b/pcbnew/scripting/examples/hidePcbValuesShowReferences.py @@ -0,0 +1,14 @@ +#!/usr/bin/env python +import sys +from pcbnew import * + +filename=sys.argv[1] + +pcb = LoadBoard(filename) + +for module in pcb.GetModules(): + print "* Module: %s"%module.GetReference() + module.Value().SetVisible(False) # set Value as Hidden + module.Reference().SetVisible(True) # set Reference as Visible + +pcb.Save("mod_"+filename) |