[PD] how to write different types to [text]

Christof Ressi info at christofressi.com
Tue Mar 29 10:55:17 CEST 2022


On 28.03.2022 22:43, Roman Haefeli wrote:

> ```
> eins;
> zwei;
> drei, vier;
> fuenf;
> ```
>
> [text size] returns 5. [2(-[text get] returns 'symbol drei'. The
> message after that is accessed with [3(-[text get].

Wow, you're right of course! *big facepalm* In all these years I never 
realized that comma seperate messages count as seperate "lines"!

The documentation of [text] only always speaks of "lines" and one would 
think that "line" would mean, well, "line of text".

 From [text get]:

"text get" reads the nth line from the named text and outputs it.

 From [text size]:

"text size" reports the number of lines in the text or the length of a specified line.

How am I supposed to know that

1 2 3, a b c, foo bar baz;

actually counts as 3 "lines"?

I think a more proper term would be "message". I think the documentation 
has to be improved. @porres to the rescue!! :-)

Christof

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20220329/39ee24f3/attachment-0001.htm>


More information about the Pd-list mailing list