| 1 |
%% |
| 2 |
%% This is file `luaindex-example.ltx', |
| 3 |
%% generated with the docstrip utility. |
| 4 |
%% |
| 5 |
%% The original source files were: |
| 6 |
%% |
| 7 |
%% luaindex.dtx (with options: `example') |
| 8 |
%% |
| 9 |
%% Copyright (c) 2011 by Markus Kohm <komascript(at)gmx.info> |
| 10 |
%% |
| 11 |
%% This file was generated from file(s) of luaindex distribution. |
| 12 |
%% -------------------------------------------------------------- |
| 13 |
%% |
| 14 |
%% This work may be distributed and/or modified under the conditions of |
| 15 |
%% the LaTeX Project Public License, version 1.3c of the license. |
| 16 |
%% The latest version of this license is in |
| 17 |
%% http://www.latex-project.org/lppl.txt |
| 18 |
%% and version 1.3c or later is part of all distributions of LaTeX |
| 19 |
%% version 2005/12/01 or later. |
| 20 |
%% |
| 21 |
%% This work has the LPPL maintenance status "maintained". |
| 22 |
%% |
| 23 |
%% The Current Maintainer and author of this work is Markus Kohm. |
| 24 |
%% |
| 25 |
%% This file may only be distributed together with the files listed in |
| 26 |
%% `luaindex.dtx'. You may however distribute the files listed in |
| 27 |
%% `luaindex.dtx' without this file. |
| 28 |
%% |
| 29 |
%% NOTE: THIS IS AN ALPHA-VERSION! |
| 30 |
%% |
| 31 |
\NeedsTeXFormat{LaTeX2e}[1995/06/01] |
| 32 |
\ProvidesFile{luaindex-example.ltx} |
| 33 |
\documentclass{article} |
| 34 |
\usepackage[ngerman]{babel} |
| 35 |
\usepackage{blindtext} |
| 36 |
\usepackage{fontspec} |
| 37 |
\usepackage[ |
| 38 |
locale=de_DE, |
| 39 |
singlepass % Wenn der Index ohnehin eine neue Seite produziert, |
| 40 |
% dann kann er direkt beim ersten Lauf ein korrektes |
| 41 |
% Ergebnis liefern. |
| 42 |
]{luaindex} |
| 43 |
\makeindex |
| 44 |
\directlua{luaindex.presortreplace('general',0, |
| 45 |
'\luatexluaescapestring{\string\textbf}\space*\string\{([\string^\string\}]*)\string\}','\%1')} |
| 46 |
\begin{document} |
| 47 |
|
| 48 |
\blindtext[10] |
| 49 |
A\index{B ist der zweite Buchstabe} |
| 50 |
aber\index{aber ist ein Wort} |
| 51 |
D\index{D ist der vierte Buchstabe} |
| 52 |
A\index{A ist der erste Buchstabe} |
| 53 |
A\index{A ist der erste Buchstabe} |
| 54 |
C\index{C ist "`der"' dritte Buchstabe} |
| 55 |
X\index{X ist der drittletzte Buchstabe} |
| 56 |
D\index{\textbf{D} ist der Buchstabe nach C} |
| 57 |
Y\index{Y ist der \textbf{vorletzte} Buchstabe} |
| 58 |
Z\index{Z ist der letzte Buchstabe} |
| 59 |
A\index{Ä ist auch ein Buchstabe} |
| 60 |
Ä\index[sort={Ä ist aber auch ein Buchstabe},% |
| 61 |
pageformat=\emph]{Ä ist wirklich auch |
| 62 |
ein Buchstabe (und hier stimmt die Sortierung |
| 63 |
nicht -- \emph{aber eigentlich doch})} |
| 64 |
\clearpage |
| 65 |
|
| 66 |
A\index{A ist der erste Buchstabe} |
| 67 |
Ae\index{Ae ist kein Buchstabe, sondern zwei} |
| 68 |
|
| 69 |
Kompliziert\subindex{Diverses}{Untereintrag} |
| 70 |
Noch komplizierter\subindex{Diverses}{Obereintrag} |
| 71 |
Noch komplizierter\% |
| 72 |
subindex{Diverses}[sort=Obereintra,pageformat=\emph]{Untereintrag} |
| 73 |
Noch komplizierter% |
| 74 |
\subsubindex{Diverses}{Untereintrag}{Unteruntereintrag} |
| 75 |
|
| 76 |
\printindex |
| 77 |
\end{document} |
| 78 |
\endinput |
| 79 |
%% |
| 80 |
%% End of file `luaindex-example.ltx'. |