[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Color silk layers in pcb



> I might have put the attribute string "PCB::non-copper" in a #define
> somewhere, but if the string is canonical, I guess it doesn't hurt to
> place it explicitly in the code.

Perhaps we should tell DRC about all sorts of attributes?  Then we can
do layer-specific ones.  I'd want to use DRC::* at that point though.
And we'd need a GUI to edit them nicely.  Migration to/from the old
DRC() format needs to be considered.

Maybe it's time for me to find time to put in the layer types change,
which would cover this need anyway (copper vs non-copper at least).
After Oct 16th though, no sooner.

> OR.. we could eventually optimise the attribute lookup code to be
> "really fast", so as to avoid the need to keep a separate flag in the
> layer data-structure. (Assuming "lookup_attrib" is too slow to use at
> the moment??)

Lookups are slow but we can cache both the lookup and the conversion
if we need to.  A hash of structs with multiple types (string, int,
float) for each attribute would do.

> It would be nice to move some the attribute lookup helper function out
> of action.c, if attributes are to form a bigger role in PCB's future,
> perhaps more functions will be created, and can live away from the
> already bloated (and seemingly unrelated) action.c

Core attribute lookups are in misc.c

But yeah, the code's getting messy.


_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user