On Mon, 2013-02-25 at 22:10 -0800, Jonathan Wilkes wrote:
Hello list, I'd like to extend the syntax of the xlet metadata in the [pd META] subpatch.
Currently something like [clip] has this for the inlets:
INLET_0 float list INLET_1 float INLET_2 float
That gets picked up by the autotips which display the methods in the tooltip.
However, for objects that have multiple xlets like [clip], an xlet tip would be more helpful if it included a one or two word description of what the inlet is for. So when the user hovers over the middle inlet the tip can also say something like: Inlet 1 of clip (low value): float
and for the right inlet: Inlet 2 of clip (high value): float
I just need some clear syntax for separating the inlet description from the methods.
Idea #0: semicolon Example:
INLET_1 float; low value Nice because there is no chance of ambiguity, since the semi can't be part of a method name. Unfortunately it forces a newline.
The semicolon + description part would be optional so there's no need to change any of the current docs. Plus it's easy to parse.
What I like about the META format is it is also easy to parse with Pd itself. Thus, I was concerned if your proposed addition would break that. I figured it does not. I don't see any other troubles, but see the benefit of having a separator. Please go ahead.
Roman
P.S.: While testing "Pd parsability", I created an object [sel ;] which immediately collapsed to [sel;] on instantiation. Although it looks weird, it's still functional. It seems something in Pd removes spaces around ';'. (Also try creating a [sel ; sel])