summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/xindy/style-tutorial
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/xindy/style-tutorial')
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/ex1.raw20
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/ex1.tex16
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/ex2.raw35
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/ex2.tex16
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/index.tex16
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/style1.xdy55
-rw-r--r--Master/texmf-dist/doc/xindy/style-tutorial/style2.xdy80
7 files changed, 238 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/ex1.raw b/Master/texmf-dist/doc/xindy/style-tutorial/ex1.raw
new file mode 100644
index 00000000000..1f4585950a9
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/ex1.raw
@@ -0,0 +1,20 @@
+;; Example raw-index file.
+
+(indexentry :key ("sábado") :locref "5" :attr "definition")
+(indexentry :key ("sabão") :locref "6" :attr "definition")
+(indexentry :key ("saber") :locref "7" :attr "definition")
+(indexentry :key ("sabor") :locref "8" :attr "definition")
+
+(indexentry :key ("academia") :locref "1" :attr "definition")
+(indexentry :key ("acafetado") :locref "2" :attr "definition")
+(indexentry :key ("açafrão") :locref "3" :attr "definition")
+(indexentry :key ("acalmar") :locref "4" :attr "definition")
+
+(indexentry :key ("index" "flat") :locref "1" :attr "usage")
+(indexentry :key ("index" "hierarchical") :locref "2" :attr "usage")
+(indexentry :key ("index" "very" "hierarchical") :locref "3" :attr "usage")
+(indexentry :key ("index" "very" "impressive") :locref "4" :attr "usage")
+
+;(indexentry :key ("arts" "classic") :locref "10" :attr "usage")
+;(indexentry :key ("arts" "contemporary") :locref "11" :attr "usage")
+;(indexentry :key ("arts" "modern") :locref "12" :attr "usage")
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/ex1.tex b/Master/texmf-dist/doc/xindy/style-tutorial/ex1.tex
new file mode 100644
index 00000000000..839c0b9834c
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/ex1.tex
@@ -0,0 +1,16 @@
+%%
+%% An sample file for typesetting an index.
+%%
+
+\documentclass[12pt]{article}
+
+\usepackage[latin1]{inputenc}
+\usepackage{makeidx}
+
+\makeindex
+
+\begin{document}
+
+\printindex
+
+\end{document}
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/ex2.raw b/Master/texmf-dist/doc/xindy/style-tutorial/ex2.raw
new file mode 100644
index 00000000000..88b767aa60f
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/ex2.raw
@@ -0,0 +1,35 @@
+;; Example raw-index file.
+
+(indexentry :key ("appendices") :locref "A-1" :attr "usage")
+(indexentry :key ("appendices") :locref "A-7" :attr "usage")
+(indexentry :key ("appendices") :locref "A-11" :attr "usage")
+(indexentry :key ("appendices") :locref "B-3" :attr "usage")
+(indexentry :key ("appendices") :locref "B-4" :attr "usage")
+(indexentry :key ("appendices") :locref "B-5" :attr "usage")
+(indexentry :key ("appendices") :locref "C-8" :attr "usage")
+(indexentry :key ("appendices") :locref "C-12" :attr "usage")
+(indexentry :key ("appendices") :locref "C-13" :attr "usage")
+(indexentry :key ("appendices") :locref "C-22" :attr "usage")
+(indexentry :key ("appendices") :locref "C-1" :attr "usage")
+(indexentry :key ("appendices") :locref "D-2" :attr "usage")
+(indexentry :key ("appendices") :locref "D-3" :attr "usage")
+(indexentry :key ("appendices") :locref "D-5" :attr "usage")
+(indexentry :key ("appendices") :locref "D-10" :attr "usage")
+
+(indexentry :key ("roman") :locref "iv" :attr "usage")
+(indexentry :key ("roman") :locref "ii" :attr "usage")
+(indexentry :key ("roman") :locref "iii" :attr "usage")
+(indexentry :key ("roman") :locref "ix" :attr "usage")
+(indexentry :key ("roman") :locref "x" :attr "usage")
+(indexentry :key ("roman") :locref "mcmxcvi" :attr "usage")
+
+(indexentry :key ("lyuk") :locref "1" :attr "usage")
+(indexentry :key ("lyukas") :locref "2" :attr "usage")
+(indexentry :key ("maga") :locref "1" :attr "usage")
+(indexentry :key ("magyar") :locref "2" :attr "usage")
+(indexentry :key ("nagy") :locref "1" :attr "usage")
+(indexentry :key ("nagyon") :locref "9" :attr "usage")
+(indexentry :key ("negy") :locref "4" :attr "usage")
+(indexentry :key ("nyolc") :locref "8" :attr "usage")
+(indexentry :key ("nyelv") :locref "1" :attr "usage")
+
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/ex2.tex b/Master/texmf-dist/doc/xindy/style-tutorial/ex2.tex
new file mode 100644
index 00000000000..839c0b9834c
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/ex2.tex
@@ -0,0 +1,16 @@
+%%
+%% An sample file for typesetting an index.
+%%
+
+\documentclass[12pt]{article}
+
+\usepackage[latin1]{inputenc}
+\usepackage{makeidx}
+
+\makeindex
+
+\begin{document}
+
+\printindex
+
+\end{document}
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/index.tex b/Master/texmf-dist/doc/xindy/style-tutorial/index.tex
new file mode 100644
index 00000000000..839c0b9834c
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/index.tex
@@ -0,0 +1,16 @@
+%%
+%% An sample file for typesetting an index.
+%%
+
+\documentclass[12pt]{article}
+
+\usepackage[latin1]{inputenc}
+\usepackage{makeidx}
+
+\makeindex
+
+\begin{document}
+
+\printindex
+
+\end{document}
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/style1.xdy b/Master/texmf-dist/doc/xindy/style-tutorial/style1.xdy
new file mode 100644
index 00000000000..ee809f9aae8
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/style1.xdy
@@ -0,0 +1,55 @@
+;; This is a first example using `xindy'.
+
+(mapc #'(lambda (x)
+ (pushnew x *features*))
+ '(:STEP1 :STEP2 :STEP3 :STEP4 :STEP5))
+
+#+:STEP1
+(progn
+ (define-location-class "page-numbers" ("arabic-numbers"))
+ (define-attributes (("definition" "usage")))
+ )
+
+
+#+:STEP2
+(progn
+ (markup-index :open "~n\begin{theindex}~n"
+ :close "~n~n\end{theindex}~n"
+ :tree)
+
+ (markup-locref :class "page-numbers" :attr "definition"
+ :open "{\bf " :close "}")
+
+ (markup-locref-list :sep ", ")
+ (markup-locclass-list :open "\quad{}")
+ )
+
+#+:STEP3
+(progn
+ (markup-indexentry :open "~n \item " :depth 0)
+ (markup-indexentry :open "~n \subitem " :depth 1)
+ (markup-indexentry :open "~n \subsubitem " :depth 2)
+
+ (markup-range :class "page-numbers" :sep "--")
+ )
+
+#+:STEP4
+(progn
+ (sort-rule "à" "a")
+ (sort-rule "á" "a")
+ (sort-rule "ã" "a")
+ (sort-rule "è" "e")
+ (sort-rule "é" "e")
+ (sort-rule "ç" "c")
+
+ (sort-rule "\\texttt{\(.*\)}" "\1" :again :bregexp)
+ )
+
+#+:STEP5
+(progn
+ (define-letter-groups
+ ("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"))
+
+ (markup-letter-group-list :sep "~n~n \indexspace~n")
+ )
diff --git a/Master/texmf-dist/doc/xindy/style-tutorial/style2.xdy b/Master/texmf-dist/doc/xindy/style-tutorial/style2.xdy
new file mode 100644
index 00000000000..e45e2f24482
--- /dev/null
+++ b/Master/texmf-dist/doc/xindy/style-tutorial/style2.xdy
@@ -0,0 +1,80 @@
+;; This is another example using `xindy'.
+
+(mapc #'(lambda (x)
+ (pushnew x *features*))
+ '(:STEP1 :STEP2 :STEP3 :STEP4 :STEP5 :STEP6 :STEP7 :STEP8 :STEP9 :STEP10))
+
+#+:STEP1
+(progn
+ (define-location-class "page-numbers" ("arabic-numbers"))
+ (define-attributes (("definition" "usage")))
+ )
+
+
+#+:STEP2
+(progn
+ (markup-index :open "~n\begin{theindex}~n"
+ :close "~n~n\end{theindex}~n"
+ :tree)
+
+ (markup-locref :class "page-numbers" :attr "definition"
+ :open "{\bf " :close "}")
+
+ (markup-locref-list :sep ", ")
+ (markup-locclass-list :open "\quad{}")
+ )
+
+#+:STEP3
+(progn
+ (markup-indexentry :open "~n \item " :depth 0)
+ (markup-indexentry :open "~n \subitem " :depth 1)
+ (markup-indexentry :open "~n \subsubitem " :depth 2)
+ )
+
+#+:STEP4
+(progn
+ (sort-rule "à" "a")
+ (sort-rule "á" "a")
+ (sort-rule "ã" "a")
+ (sort-rule "è" "e")
+ (sort-rule "é" "e")
+ (sort-rule "ç" "c")
+
+ (sort-rule "\\texttt{(.*)}" "\1" :again :bregexp)
+ )
+
+#+:STEP5
+(progn
+ (define-letter-groups
+ ("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"))
+
+ (markup-letter-group-list :sep "~n~n \indexspace~n")
+ )
+
+#+:STEP6
+(progn
+ (define-location-class "roman-pages" ("roman-numbers-lowercase"))
+ #-:STEP8
+ (define-location-class "appendices" ("ALPHA" :sep "-" "arabic-numbers"))
+ )
+
+#+:STEP7
+(markup-range :sep "--")
+
+#+:STEP8
+(progn
+ (define-location-class "appendices" ("ALPHA" :sep "-" "arabic-numbers")
+ :hierdepth 2)
+ (markup-locref-list :sep "; " :depth 0 :class "appendices")
+ (markup-locref-list :open "~~" :sep ", " :depth 1 :class "appendices")
+ )
+
+#+:STEP9
+(progn
+ (define-letter-group "ly" :after "l" :before "m")
+ (define-letter-group "ny" :after "n" :before "o")
+
+ (markup-letter-group :open-head "~n {\bf " :close-head "}"
+ :capitalize)
+ )