Hello,
I am a beginner for scripting in KLayout. I want to select some shapes in a layer "1:0" which I have marked using text label 'A'. So I want to select those 'A' shapes and copy them to a new layer "1:1". I tried to go through the API, but not successful.
Thanks,
Qum
Comments
Hi Qum,
use the DRC feature for this purpose. Select all texts with "A" (see http://www.klayout.de/doc-qt4/about/drc_ref_layer.html#h2-1893) and use "interact" to select the original shapes with these labels.
For an introduction see http://www.klayout.de/doc-qt4/manual/drc.html.
Matthias
Thanks for pointing me to the right direction. When I try to select text from a layer, I got the following error.
undefined method `texts` for #<DRC::DRCLayer:0x00000000099b0830> in MacroInterpreter::execute.
Hi Qum,
what KLayout version are you using? "texts" is there since 0.25.x.
Matthias
You are absolutely right that it's a version issue. I upgraded to 0.25.x and it works now.
Regards,
Qun