Index: src/libpcb_fp.c =================================================================== --- src/libpcb_fp.c (revision 857) +++ src/libpcb_fp.c (revision 858) @@ -108,9 +108,14 @@ counter++; e = htsp_getentry(pcb_fp_tags, (char *)tag); } - return e; + return e->key; } +const char *pcb_fp_tagname(const void *tagid) +{ + return (char *)tagid; +} + /* Decide about the type of a footprint file: - it is a file element if the first non-comment is "Element(" or "Element[" - else it is a parametric element (footprint generator) if it contains Index: src/libpcb_fp.h =================================================================== --- src/libpcb_fp.h (revision 857) +++ src/libpcb_fp.h (revision 858) @@ -42,4 +42,7 @@ /* Resolve a tag name to an unique void * ID; create unknown tag if alloc != 0 */ const void *pcb_fp_tag(const char *tag, int alloc); +/* Resolve a tag ID to a tag name */ +const char *pcb_fp_tagname(const void *tagid); + #endif