[PD] Help with patch needed: keyname/route + textfile/gem

Martin Schied crinimal at gmx.net
Thu Sep 17 20:11:31 CEST 2009


James Dunn wrote: 
> Thanks Martin, this is really useful! What I really need now is a way 
> to automatically generate carriage returns or EOL's when the text hits 
> the edge of the window - is this something that can be done in gem or 
> do I have to format the text first in a text editor first?
>
Hi,

spent some time and made an abstraction for this (see attachment).

I think formatting it outside of Pd is much more simple - but less 
flexible inside your patch.
I had some problems when trying to use doubled "newlines" to create new 
paragraphs. text3d and text2d display some strange characters in this case.

If it has not to be dynamically changeable text inside your patch you 
could use latex or something else to format text into pages and then 
convert them to pixel graphics. Like this you can also generate good 
looking hyphened justification which is hardly doable within pd.

I figured out a way to have png from latex with nice alpha transparency:
latex --> ps, split ps into single pages, ps2eps, eps2png.
you'll find them here:
http://www.tm.uka.de/~bless/ps2eps
http://search.cpan.org/~jv/eps2png/

an other more out-of-the-box-method would be using your favorite office 
software, making pdfs and convert them to pixel graphics (using 
imagemagick or something else). Or simply use inkscape and export them 
to png. :D

cheers
Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: line-break.pd
Type: application/puredata
Size: 5472 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20090917/78bb88c3/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: line-break-help.pd
Type: application/puredata
Size: 5292 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20090917/78bb88c3/attachment-0001.bin>


More information about the Pd-list mailing list