gEDA-dev: [pcb] attributes

DJ Delorie dj at delorie.com
Tue Aug 29 22:55:59 EDT 2006


I just checked in a change that allows you to have pcb-global
attributes and element-specific attributes in .pcb files:

Attribute("name" "value")

For global attributes, you can place these anywhere an Element is
allowed.  For element-specific attributes, you can place them anywhere
a Pin is allowed.

PCB does nothing with these attributes; it only reads them, stores
them, and writes them out later.  I propose the following actions in
the near future (for programs like gattrib or gsch2pcb to use):

SetPCBAttribute(name,value)
SetElementAttribute(refdes,name,value)
SaveAttributes(filename)

The last one would write a CSV file, I figured "refdes,name,value".
Not sure how to split global and element attributes.  Two actions?  Or
a magic tag for refdes that means "global" ?

Also, I added an optional third parameter to the Layer() line, which
is a string.  I figure at some point in the future, we'll have layer
flags, this will give us some forward compatibility.  PCB just ignores
the string if present.


More information about the geda-dev mailing list