158{
159 std::string attribute_string;
160 std::string comment_string;
161
162
163 switch( aAttribute )
164 {
165
168 break;
169
171
172
173 attribute_string = "TA.AperFunction,EtchedComponent";
174 break;
175
177 attribute_string = "TA.AperFunction,Conductor";
178 break;
179
181 attribute_string = "TA.AperFunction,Profile";
182 break;
183
185 attribute_string = "TA.AperFunction,ViaPad";
186 break;
187
189
190 attribute_string = "TA.AperFunction,NonConductor";
191 break;
192
194
195 attribute_string = "TA.AperFunction,ComponentPad";
196 break;
197
199
200
201 attribute_string = "TA.AperFunction,SMDPad,SMDef";
202 break;
203
205
206 attribute_string = "TA.AperFunction,SMDPad,CuDef";
207 break;
208
210
211 attribute_string = "TA.AperFunction,BGAPad,SMDef";
212 break;
213
215
216 attribute_string = "TA.AperFunction,BGAPad,CuDef";
217 break;
218
220
221 attribute_string = "TA.AperFunction,ConnectorPad";
222 break;
223
225
226 attribute_string = "TA.AperFunction,WasherPad";
227 break;
228
230
231 attribute_string = "TA.AperFunction,HeatsinkPad";
232 break;
233
235
236 attribute_string = "TA.AperFunction,TestPad";
237 break;
238
240
241 attribute_string = "TA.AperFunction,FiducialPad,Global";
242 break;
243
245
246 attribute_string = "TA.AperFunction,FiducialPad,Local";
247 break;
248
250
251 attribute_string = "TA.AperFunction,CastellatedPad";
252 break;
253
255
256 attribute_string = "TA.AperFunction,CastellatedDrill";
257 break;
258
260 attribute_string = "TA.AperFunction,ViaDrill";
261 break;
262
264
265 attribute_string = "TA.AperFunction,ComponentDrill";
266 break;
267
268
269
270
272 comment_string = "aperture for slot hole";
273 attribute_string = "TA.AperFunction,ComponentDrill";
274 break;
275
277
278
279 attribute_string = "TA.AperFunction,ComponentMain";
280 break;
281
283
284
285
286 attribute_string = "TA.AperFunction,ComponentPin";
287 break;
288
290
291
292
293
294 attribute_string = "TA.AperFunction,ComponentPin";
295 break;
296
298
299
300 attribute_string = "TA.AperFunction,ComponentOutline,Body";
301 break;
302
304
305
306 attribute_string = "TA.AperFunction,ComponentOutline,Lead2Lead";
307 break;
308
310
311
312 attribute_string = "TA.AperFunction,ComponentOutline,Footprint";
313 break;
314
316
317
318 attribute_string = "TA.AperFunction,ComponentOutline,Courtyard";
319 break;
320
321 break;
322 }
323
324 std::string full_attribute_string;
325 wxString eol_string;
326
327 if( !attribute_string.empty() )
328 {
329 if( !comment_string.empty() )
330 {
331 full_attribute_string = "G04 " + comment_string + "*\n";
332 }
333
334 if( aUseX1StructuredComment )
335 {
336 full_attribute_string += "G04 #@! ";
337 eol_string = "*\n";
338 }
339 else
340 {
341 full_attribute_string += "%";
342 eol_string = "*%\n";
343 }
344 }
345
346 full_attribute_string += attribute_string + eol_string;
347
348 return full_attribute_string;
349}