As part of an attempt to debug another problem, I have a need for a TeX/LaTeX command that generates some dummy text in place. I know of lipsum and blindtext, but they are not what they want. What I have in mind is a command that takes the following arguments: a string (s) and integers (k and n), and produces k occurrences of s per line (no spaces) for n lines. I think this should be possible, even if one has to drop down to TeX to do it. After all, TeX is a text processing Turing complete programming language. Unfortunately, my knowledge of TeX could fit on a postage stamp with space left over, so I'm asking on this forum.
|
|
||||
|
The simplest way IMHO to do it is to use As Andrey already stated there are the open question about how to handle line breaks exactly. I simply use a
|
|||||
|
|
And a Plain TeX-style solution using
|
|||||||||
|
|
You mentioned already Unfortunately the missing spaces need also a redefiniton of Below is an example.
|
||||
|
|
|
Using LaTeX3 it's almost a one liner; the
|
|||
|
s, TeX cannot justify the line because there is nothing stretchable in it. Do you want the text left- or right-aligned? And what to do if the line overfills? – Andrey Vihrov Aug 8 '11 at 9:23