[PD] message box issue with blank spaces

IOhannes m zmoelnig zmoelnig at iem.at
Wed Dec 9 12:17:39 CET 2009

Matteo Sisti Sette wrote:
> Ok I have it.
> This does work as expected:
> [32(
> |
> [makefilename foo%cbar]
> |
> [set $1(
> |
> [  (
> Then you can bang the last message box and feed its output to a [list
> length] to verify it is one symbol (well, not a symbol, one whatever).
> But then, if I manually edit the message box and modify it (for example
> add some characters), then the space is reconverted to a "true space"
> and the symbol is broken.

that's because the contents of the msgbox get's reparsed when you edit it.

> However, I've realised my particular case has a workaround, since I know
> that the box must contain one symbol, so I can glue it again with the
> "32->%c" trick.

if you want a real symbol, you could as well use

[set symbol $1(

or just believe the output of [makefilename] to be what you expect it to be.

(and there's zexy's [list2symbol] which will concatenate all the
arguments of a list into a single symbol, the default delimiter being space.

> I think a general escaping mechanism would really be needed in PD!!!


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3636 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20091209/eddceedb/attachment.bin>

More information about the Pd-list mailing list