On Dienstag, 7. Oktober 2008, Peter Clifton wrote: > On Tue, 2008-10-07 at 09:02 +0200, Werner Hoch wrote: > > I'd use the same space separated list of attributes as the > > always-promote-attributes variable in libgeda. > > Why does the attribute viewer need to use that list directly?
I've tried to say that I'd use the same format, not the same list. Sorry for the confusion. > There are already various helper functions to "get promotable > attributes", even if the preview widget doesn't normally promote > them. Unless I've misunderstood something, we don't need to duplicate > any functionality to check for promotable attributes. > See the recently added function: > GList *o_complex_get_promotable (TOPLEVEL *toplevel, OBJECT *object, > int detach); I've looked into it. But I think I cannot use it. If a symbol is opened directly the attributes are just plain text objects. Not elements of a component. He're the current hack of the component selector: http://repo.or.cz/w/geda-gaf/werner.git?a=commitdiff;h=2b0ae504fa605f4e36a454109883222344b39bb1 The relevant function is update_attributes_model() > > But there is a bug entry about that list of values: > > https://sourceforge.net/tracker2/?func=detail&aid=2072230&group_id= > >161080&atid=818426 > > > > Can we say this bug is a feature? > > It is definately a bug in combination with our current definition of > a legal attribute name. Please don't close the bug. Yes, but I think we should just refine the definition of the attribute syntax with an additional phrase: http://geda.seul.org/wiki/geda:file_format_spec#attributes e.g. "The name of the attribute must match the regex '[A-Za-z][a-z0-9-_]*'. The attribute name is case sensitiv." I think this is true for all currently used attribute names out there. Note: I've added the "-" because spice-sdb uses the attribute name "model-name". http://www.geda.seul.org/wiki/geda:sdb_howto#gschem_attributes_for_spice_netlisting Regards Werner _______________________________________________ geda-dev mailing list [email protected] http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev
