What is gAttrib?

gattrib is the attribute editor for gschem, the schematic capture program/tool which is part of gEDA. gattrib's sole purpose is to facilitate the editing of attributes of components.

sdb_notes SDB's original comment in gattrib.c

In the spirit of open source/free software, major sections of gattrib's code were borrowed from other sources, and hacked together by SDB in Dec. 2003.
Particularly rich sources for code were gEDA/gnetlist, and the gtkextra program testgtksheet.c.

Thanks to their authors for providing the foundation upon which this is built.
Of course, I *did* write major portions of the code too . . . . .
Some documentation about the internal operation of this program can be found in the "NOTES" file in the gattrib top-level directory.
-- SDB December 2003 --

Architecture

Extracted from SDB's mailing list posting: http://osdir.com/ml/cad.geda.devel/2007-06/msg00282.html - believed to still be relevant.

gattrib has three major components:

When run, gattrib does this:

Saving out a design is similar, except the process runs in reverse:

Therefore, think of SHEET_DATA and the other gattrib data structures as a thin layer between GtkSheet and TOPLEVEL.
The gattrib data structures are used basically for convenience while trying to build or update either of the two other, more important data structures.