summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/blindtext/blindtext.sty
blob: 06f37e918889726631f3e745cdcc84e9d5d3bf5c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
%%
%% This is file `blindtext.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% blindtext.dtx  (with options: `package')
%% ----------------------------------------------------------------------
%% The original file is loadable from CTAN on:
%% tex-archive/latex/contrib/blindtext
%% 
%% Name of contribution: blindtext
%% Name and email:       Knut Lickert <knut@lickert.net>
%% Location on CTAN:     tex-archive/macros/latex/contrib/blindtext
%% Summary description:  Package for writing text
%% License type:         Free
%% 
%% Announcement text:
%% blindtext.sty:
%%     Style to create text.
%%     Can be used to create examples with a lot text to become a feeling
%%     for the look of classes, packages...
%% 
%%     There are macros to create dummy text, dummy lists and
%%     dummy documents with sections, text and lists.
%% 
%% For more information visit
%%     http://tex.lickert.net/packages/blindtext/index.html
%% ----------------------------------------------------------------------
\def\fileversion{V1.7}
\def\filedate{2006/11/21}
%%
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~}
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{blindtext}[\filedate\space\fileversion\space%
                 blindtext-Package]
\RequirePackage{xspace}
\providecommand{\frqq}{}
\providecommand{\flqq}{}
\newcommand{\blind@checklanguage}{%
  \@ifundefined{blindtext@\languagename}{%
    \PackageWarning{blindtext}{\languagename\space not
      defined, using english instead.\MessageBreak
    }%
    \selectlanguage{english}%
  }{}%
}

\newcounter{blindtext}\setcounter{blindtext}{1}
\newcounter{Blindtext}\setcounter{Blindtext}{5}
\newcount\blind@countxx
\newcommand{\blindtext}[1][\value{blindtext}]{%
  \blind@checklanguage
  \blind@countxx=1 %
  \loop
    \blindtext@text
  \ifnum\blind@countxx<#1\advance\blind@countxx by 1 %
  \repeat
}
\newcount\blindtext@numBlindtext%
\newcommand{\Blindtext}[1][\value{Blindtext}]{%
\blind@checklanguage%
\blindtext@numBlindtext=#1%
\blind@Blindtext%
}
\newcount\blind@countyy%
\newcommand{\blind@Blindtext}[1][\value{blindtext}]{%
  \blind@countyy=1 %
\loop%
{\blindtext@parstart\blindtext[#1]\blindtext@parend\par}%
  \ifnum\blind@countyy<\blindtext@numBlindtext\advance\blind@countyy by 1 %
\repeat%
}
\newcommand{\blindtext@parstart}{}   %Text at start of paragraph
\newcommand{\blindtext@parend}{}     %Text at end   of paragraph
\newcommand{\parstart}[1]{\renewcommand{\blindtext@parstart}{#1}}
\newcommand{\parend}[1]{\renewcommand{\blindtext@parend}{#1}}
\newif\ifblind@long\blind@longfalse
\newif\ifblind@optional\blind@optionalfalse
\newcounter{blindlist}
\newcounter{blindlistlevel}%Up tu X level
\newcounter{blindlist@level}%internal counter
\newcount\blind@listitem
%% ^^A-----------------------------------------------------------
\newcommand{\blindlist}[1]{
\blind@checklanguage
\def\blind@listtype{#1}
\setcounter{blind@levelcount}{1}
\blind@list
}
\newcommand{\blind@list}[1][5]{%
\setcounter{blindlist}{#1}%
\addtocounter{blindlist@level}{1}%depth of list
  \blind@listitem=1 %
\begin{\blind@listtype}%
\blind@items%
\end{\blind@listtype}%
\blind@longfalse%
\blind@optionalfalse%
}
\newcommand{\blindlistlist}[2][4]{%
\setcounter{blindlistlevel}{#1}%
\setcounter{blindlist@level}{0}%deepest reached level
\setcounter{blind@levelcount}{1}%actual level for printout
\def\blind@listtype{#2}%
\blind@list%
}
\newcommand{\blindlistlistoptional}{%
\blind@optionaltrue%
\blindlistlist%
}
\newcommand{\blinditemize}{\blindlist{itemize}}
\newcommand{\blindenumerate}{\blindlist{enumerate}}
\newcommand{\Blindlist}[1]{%
\blind@longtrue%
\blindlist{#1}%
}
\newcommand{\Blinditemize}{\Blindlist{itemize}}
\newcommand{\Blindenumerate}{\Blindlist{enumerate}}
\newcommand{\blindlistoptional}[1]{%
\blind@optionaltrue%
\blindlist{#1}%
}
\newcommand{\Blindlistoptional}[1]{%
\blind@optionaltrue%
\blind@longtrue%
\blindlist{#1}%
}
\newcommand{\blinddescription}{\blindlistoptional{description}}
\newcommand{\Blinddescription}{\Blindlistoptional{description}}
\newcounter{blind@listcount}
\newcounter{blind@levelcount}
\newcommand{\blind@items}{
\setcounter{blind@listcount}{1}
\loop
\ifblind@optional
    \ifblind@long
        \item[\blindtext@countitem] \blindtext@text
    \else
        \item[\blindtext@count] \blindtext@item
    \fi
    \else % \blind@optionalfalse
    \ifblind@long
        \item \blindtext@text
    \else
        \item \blindtext@countitem
    \fi
    \fi % \ifblind@optional
    {%
    \loop
      \ifnum\value{blindlistlevel}>\value{blindlist@level}
      \addtocounter{blind@levelcount}{1}
      \blind@list[\value{blindlist}]\relax
      \addtocounter{blind@levelcount}{-1}
      \setcounter{blind@listcount}{1}
    \repeat
    }%
\ifnum\value{blind@listcount}<\value{blindlist}
\addtocounter{blind@listcount}{1}
\repeat
}
%% ^^A-----------------------------------------------------------
\newcommand{\blinddocument}{
\@ifundefined{chapter}{}{%
    \chapter{\blindtext@heading 0 (chapter)}
    \blindtext%
    }
  \section{\blindtext@heading 1 (section)}
  \blindtext
  \subsection{\blindtext@heading 2 (subsection)}
  \blindtext
  \subsubsection{\blindtext@heading 3 (subsubsection)}%
  \blindtext
  \paragraph{\blindtext@heading 4 (paragraph)}
  \blindtext
\section{\blindtext@list}
\subsection{\blindtext@listEx (itemize)}
    \blinditemize
    \subsubsection{\blindtext@listEx (4*itemize)}
    \blindlistlist{itemize}[2]
\subsection{\blindtext@listEx (enumerate)}
    \blindenumerate
    \subsubsection{\blindtext@listEx (4*enumerate)}
    \blindlistlist{enumerate}[2]
\subsection{\blindtext@listEx (description)}
    \blinddescription
    \subsubsection{\blindtext@listEx (4*description)}
    \blindlistlistoptional{description}[2]
}
\newcommand{\Blinddocument}{
\@ifundefined{chapter}{}{%
    \chapter{\blindtext@heading 0 (chapter)}
    \blindtext%
  }%
  \section{\blindtext@heading 1 (section)}
  \Blindtext
  \subsection{\blindtext@heading 2 (subsection)}
  \Blindtext
  \subsubsection{\blindtext@heading 3 (subsection)}
  \Blindtext
  \paragraph{\blindtext@heading 4 (paragraph)}
  \Blindtext
\section{\blindtext@list}
\subsection{\blindtext@listEx (itemize)}
    \Blinditemize
    \subsubsection{\blindtext@listEx (4*itemize)}
    \blind@longtrue
    \blindlistlist{itemize}[2]
\subsection{\blindtext@listEx (enumerate)}
    \Blindenumerate
    \subsubsection{\blindtext@listEx (4*enumerate)}
    \blind@longtrue
    \blindlistlist{enumerate}[2]
\subsection{\blindtext@listEx (description)}
    \Blinddescription
    \subsubsection{\blindtext@listEx (4*description)}
    \blind@longtrue
    \blindlistlistoptional{description}[2]
}
%% ^^A-----------------------------------------------------------
\@ifundefined{addto}{
\@ifpackageloaded{babel}{}{
\PackageWarning{blindtext}{%
You are not using babel.sty -> Language by random\MessageBreak
Kein babel.sty verwendet -> Zufallssprache}}
\newcommand{\addto}[2]{#2}
}{}
\def\blindtext@text{Text}
\def\blindtext@count{%
  \ifcase\blind@listitem\or
    First\or Second%...
  \else
    Last%
    \blind@listitem=0 %
  \fi
  \global\advance\blind@listitem by 1 %
}%\blindtext@count}
\def\blindtext@item{itemtext}
\def\blindtext@countitem{\blindtext@count\ \blindtext@item}
\def\blindtext@heading{Heading on level\xspace}
\def\blindtext@list{Lists}
\def\blindtext@listEx{Example for list\xspace}
\def\blindtext@english{}
\addto\extrasenglish{%
\def\blindtext@text{
Hello, here is some text without a meaning. This text should show,
how a printed text will look like at this place. If you read this
text, you will get no information. Really? Is there no
information? Is there a difference between this text and some
nonsense like \frqq Huardest gefburn\flqq? Kjift -- Never mind! A
blind text like this gives you information about the selected
font, how the letters are written and the impression of the look.
This text should contain all letters of the alphabet and it should
be written in of the original language. There is no need for a
special contents, but the length of words should match to the
language.}%\blindtext@text
}
\addto\extrasenglish{%
  \def\blindtext@count{%
    \ifcase\value{blind@listcount}\or
      First\or Second \or Third \or Fourth\or Fivth\or
      Sixth\or Seventh\or Eighth \or Ninth\or Tenth\or
      Eleventh\or Twelfth%
    \else Another%
    \fi
  }% \blindtext@count
  \def\blindtext@item{item in a list}%, level~\arabic{blindlist@level}}
}% \addto\extrasenglish
\addto\extrasenglish{%
    \def\blindtext@heading{Heading on level\xspace}%
    \def\blindtext@list{Lists}%
    \def\blindtext@listEx{Example for list\xspace}%
}%\addto\extrasenglish
\def\blindtext@german{}
\addto\extrasgerman{%
\def\blindtext@text{
Dies hier ist ein Blindtext zum Testen von Textausgaben. Wer
diesen Text liest, ist selbst schuld. Der Text gibt lediglich den
Grauwert der Schrift an. Ist das wirklich so? Ist es
gleich\-g\"ul\-tig ob ich schreibe: \frqq Dies ist ein
Blindtext\flqq\ oder \frqq Huardest gefburn\flqq? Kjift --
mitnichten! Ein Blindtext bietet mir wichtige Informationen. An
ihm messe ich die Lesbarkeit einer Schrift, ihre Anmutung, wie
harmonisch die Figuren zueinander stehen und pr\"u\-fe, wie breit
oder schmal sie l\"auft. Ein Blindtext sollte m\"og\-lichst viele
verschiedene Buchstaben enthalten und in der Originalsprache
gesetzt sein. Er mu\ss\ keinen Sinn ergeben, sollte aber lesbar
sein. Fremdsprachige Texte wie \frqq Lorem ipsum\flqq\ dienen
nicht dem eigentlichen Zweck, da sie eine
falsche Anmutung vermitteln.}%\blindtext@text
}
\addto\extrasgerman{%
\def\blindtext@count{
  \ifcase\value{blind@listcount}\or
    Erster\or Zweiter \or Dritter \or Vierter \or F{\"u}nfter \or
    Sechster \or Siebter\or Achter \or Neunter \or Zehnter\or
    Elfter \or Zw{\"o}lfter \or Dreizehnter \or Vierzehnter
    \else
    Noch ein
    \fi
}%\blindtext@count
\def\blindtext@item{Listenpunkt, Stufe~\arabic{blind@levelcount}}%
}%\addto\extrasgerman
\addto\extrasgerman{%
    \def\blindtext@heading{{\"U}berschrift auf Ebene\xspace}%
    \def\blindtext@list{Listen}%
    \def\blindtext@listEx{Beispiel einer Liste\xspace}%
}%\addto\extrasgerman
\@ifpackageloaded{german}{\selectlanguage{german}}{}
\def\blindtext@ngerman{}
\addto\extrasngerman{%
\def\blindtext@text{
Dies hier ist ein Blindtext zum Testen von Textausgaben. Wer
diesen Text liest, ist selbst schuld. Der Text gibt lediglich den
Grauwert der Schrift an. Ist das wirklich so? Ist es
gleich\-g\"ul\-tig ob ich schreibe: \frqq Dies ist ein
Blindtext\flqq\ oder \frqq Huardest gefburn\flqq? Kjift --
mitnichten! Ein Blindtext bietet mir wichtige Informationen. An
ihm messe ich die Lesbarkeit einer Schrift, ihre Anmutung, wie
harmonisch die Figuren zueinander stehen und pr\"u\-fe, wie breit
oder schmal sie l\"auft. Ein Blindtext sollte m\"og\-lichst viele
verschiedene Buchstaben enthalten und in der Originalsprache
gesetzt sein. Er mu\ss\ keinen Sinn ergeben, sollte aber lesbar
sein. Fremdsprachige Texte wie \frqq Lorem ipsum\flqq\ dienen
nicht dem eigentlichen Zweck, da sie eine
falsche Anmutung vermitteln.}%\blindtext@text
}
\addto\extrasngerman{%
\def\blindtext@count{
    \ifcase\value{blind@listcount}\or
    Erster\or Zweiter \or Dritter \or Vierter \or F{\"u}nfter \or
    Sechster \or Siebter\or Achter \or Neunter \or Zehnter\or
    Elfter \or Zw{\"o}lfter \or Dreizehnter \or Vierzehnter\else
    Noch ein\fi
}%\blindtext@count
\def\blindtext@item{Listenpunkt, Stufe~\arabic{blind@levelcount}}%
}%\addto\extrasgerman
\addto\extrasngerman{%
    \def\blindtext@heading{{\"U}berschrift auf Ebene\xspace}%
    \def\blindtext@list{Listen}%
    \def\blindtext@listEx{Beispiel einer Liste\xspace}%
}%\addto\extrasngerman
\@ifpackageloaded{ngerman}{\selectlanguage{ngerman}}{}
\def\blindtext@latin{}
\addto\extraslatin{%
\def\blindtext@text{
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Etiam
lobortis facilisis sem. Nullam nec mi et neque pharetra
sollicitudin. Praesent imperdiet mi nec ante. Donec ullamcorper,
felis non sodales commodo, lectus velit ultrices augue, a
dignissim nibh lectus placerat pede. Vivamus nunc nunc, molestie
ut, ultricies vel, semper in, velit. Ut porttitor. Praesent in
sapien. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
Duis fringilla tristique neque. Sed interdum libero ut metus.
Pellentesque placerat. Nam rutrum augue a leo. Morbi sed elit sit
amet ante lobortis sollicitudin. Praesent blandit blandit mauris.
Praesent lectus tellus, aliquet aliquam, luctus a, egestas a,
turpis. Mauris lacinia lorem sit amet ipsum. Nunc quis urna dictum
turpis accumsan semper.}%\blindtext@text
}
\addto\extraslatin{%
\def\blindtext@count{
  \ifcase\value{blind@listcount}\or
    Primus\or Duo\or Tres\or Quattuor\or Quinque\or
    Sex\or Septem\or Octo\or Novem\or Decem\or
    Undecim\or Duodecim
  \else
    Nova
  \fi
}%\blindtext@count
\def\blindtext@item{, altum~\arabic{blind@levelcount}}%
}%\addto\extrasgerman
\addto\extraslatin{%
    \def\blindtext@heading{Sectio\xspace}%
    \def\blindtext@list{Caudex}%
    \def\blindtext@listEx{Exemplum caudex\xspace}%
}%\addto\extraslatin
\let\alotoftext=\blindtext
\endinput
%%
%% End of file `blindtext.sty'.