<!--
Create Silkscreen Layer from components
Need App Examples or Learn More about the App Matrix format?
Visit, https:
<NumericalMatrix text_height=".03" refdes_font="fab.fnt" select_font="Arial" top_side="true" bottom_side="true">
<!-- Define a reference Array -->
<REF name="top_silk_object">
<ADD>
<JOB>@active</JOB>
<UNITS>INCH</UNITS>
<COMPOSITE>dark</COMPOSITE>
<TEXTSTYLE>@refdes_font</TEXTSTYLE>
<TEXTALIGN>cc</TEXTALIGN>
<TEXT>Silkscreen Top,__center_x,__center_y,@text_height,0,FALSE,__refdes,cc</TEXT>
</ADD>
</REF>
<!-- Define a reference Array: For bottom Silktext -->
<REF name="bottom_silk_object">
<ADD>
<JOB>@active</JOB>
<UNITS>INCH</UNITS>
<COMPOSITE>dark</COMPOSITE>
<TEXTSTYLE>@refdes_font</TEXTSTYLE>
<TEXTALIGN>cc</TEXTALIGN>
<TEXT>Silkscreen Bottom,__center_x,__center_y,@text_height,0,TRUE,__refdes,cc</TEXT>
</ADD>
</REF>
<!-- Add Modal dialog -->
<DIALOGBOX title="Generate Silkscreen (from Components)..." width="400" height="200" columnWidth="180" help_url="">
<DLGITEM name="Text Height" value="@text_height" type="edit" />
<DLGITEM name="Text Font Style" value="@select_font" type="combo">
<OPTION>Fab</OPTION>
<OPTION>Arial</OPTION>
<OPTION>Times</OPTION>
</DLGITEM>
<DLGITEM name="Add Silkscreen (Top Side)" value="@top_side" type="check" />
<DLGITEM name="Add Silkscreen (Bottom Side)" value="@bottom_side" type="check" />
</DIALOGBOX>
<EXIT if="__dlg_result==false"></EXIT>
<!-- Select Top Layer Pads set -->
<if test="@top_side==true">
<FILTER>
<NAME>top_filter</NAME>
<JOB>@active</JOB>
<LAYERS>[Top_Components]</LAYERS>
<NewLayer result="@top_silk">Silkscreen Top,GRAPHIC</NewLayer>
</FILTER>
<SELECTION>
<Name>top_set</Name>
<FILTER>top_filter</FILTER>
<JOB>@active</JOB>
<SELECT_ALL/>
</SELECTION>
<foreach select="top_set">
<get type="all" />
<MESSAGE>#{{__index+1}}: __object (__refdes), __layer, Center: __center_pt</MESSAGE>
<matrix_ref name="top_silk_object" />
</foreach>
</if>
<!-- Process Bottom side -->
<if test="@bottom_side==true">
<FILTER>
<NAME>bottom_filter</NAME>
<JOB>@active</JOB>
<LAYERS>[Bottom_Components]</LAYERS>
<NewLayer result="@bot_silk">Silkscreen Bottom,GRAPHIC</NewLayer>
</FILTER>
<SELECTION>
<Name>bottom_set</Name>
<FILTER>bottom_filter</FILTER>
<JOB>@active</JOB>
<SELECT_ALL/>
</SELECTION>
<foreach select="bottom_set">
<get type="all" />
<MESSAGE>#{{__index+1}}: __object (__refdes), __layer, Center: __center_pt</MESSAGE>
<matrix_ref name="bottom_silk_object" />
</foreach>
</if>
<!-- Zoom Out to see edits -->
<ZOOM_ALL />
</NumericalMatrix>