diff --git a/src/content/audition.typ b/src/content/audition.typ index 000f270..7d0f1ba 100644 --- a/src/content/audition.typ +++ b/src/content/audition.typ @@ -18,7 +18,7 @@ #import "../prelude.typ" as prelude -#set heading(numbering: none) +#set heading(numbering: none, supplement: [Heading]) #set page(numbering: "I.", footer: "") #include "../pages/title.typ" diff --git a/src/content/outline.typ b/src/content/outline.typ index acdea85..0999d8e 100644 --- a/src/content/outline.typ +++ b/src/content/outline.typ @@ -28,54 +28,69 @@ footer: "" ) -#let heading_outline_title = if prelude.format.language == "de" [ - Inhaltsverzeichnis +#set heading(supplement: [Heading]) +#set page(numbering: "I.", footer: "") + +#if prelude.format.language == "de" [ + = Inhaltsverzeichnis ] else if prelude.format.language == "en" [ - Table of contents + = Table of contents ] else [ #panic("no translation for language: ", prelude.format.language) ] -#outline(title: heading_outline_title, indent: auto) + +#par(first-line-indent: 0pt)[ + #show outline.entry.where( + level: 1 + ): it => { + strong(it) + } + + #outline(title: none, indent: auto, target: heading.where(supplement: [Heading])) +] #pagebreak() -#let image_outline_title = if prelude.format.language == "de" [ - Abbildungsverzeichnis +#if prelude.format.language == "de" [ + = Abbildungsverzeichnis ] else if prelude.format.language == "en" [ - List of figures + = List of figures ] else [ #panic("no translation for language: ", prelude.format.language) ] + #outline( - title: image_outline_title, + title: none, target: figure.where(kind: image), ) #pagebreak() -#let table_outline_title = if prelude.format.language == "de" [ - Tabellensverzeichnis +#if prelude.format.language == "de" [ + = Tabellensverzeichnis ] else if prelude.format.language == "en" [ - List of tables + = List of tables ] else [ #panic("no translation for language: ", prelude.format.language) ] + #outline( - title: table_outline_title, + title: none, target: figure.where(kind: table), ) #pagebreak() -#let raw_outline_title = if prelude.format.language == "de" [ - Quelltextverzeichnis +#if prelude.format.language == "de" [ + = Quelltextverzeichnis ] else if prelude.format.language == "en" [ - Table of source code + = List of source code ] else [ #panic("no translation for language: ", prelude.format.language) ] + #outline( - title: raw_outline_title, + title: none, target: figure.where(kind: raw), ) @@ -98,7 +113,7 @@ // destination array #let glossary_entries = () -// parse TOML entries into correct format +// parse YAML entries into correct format #if glossary.glossary != none { for entry in glossary.glossary { let short = entry.at("short", default: none) @@ -115,5 +130,20 @@ #print-glossary(glossary_entries) +#pagebreak() + +#if prelude.format.language == "de" [ + = Anhangsverzeichnis +] else if prelude.format.language == "en" [ + = List of appendencies +] else [ + #panic("no translation for language: ", prelude.format.language) +] + +#outline( + title: none, + target: heading.where(supplement: [Appendix]), +) + // reset page counter #counter(page).update(0) \ No newline at end of file diff --git a/src/content/preface.typ b/src/content/preface.typ index b4b3f5c..97b7bd1 100644 --- a/src/content/preface.typ +++ b/src/content/preface.typ @@ -12,6 +12,9 @@ #import "../prelude.typ" as prelude +#set heading(supplement: [Heading]) +#set page(numbering: "I.", footer: "") + #set page( binding: left, header-ascent: 2em, diff --git a/src/main.typ b/src/main.typ index ad3ae33..503f31d 100644 --- a/src/main.typ +++ b/src/main.typ @@ -131,6 +131,8 @@ footer: "" ) +#set heading(supplement: [Heading]) + #include "pages/introduction.typ" // ------------------------------------------ diff --git a/src/pages/appendix.typ b/src/pages/appendix.typ index dd4daea..31089f5 100644 --- a/src/pages/appendix.typ +++ b/src/pages/appendix.typ @@ -28,13 +28,28 @@ #set heading(numbering: none) -= Appendix +#if prelude.format.language == "de" [ + = Anhang +] else if prelude.format.language == "en" [ + = Appendix +] else [ + #panic("no translation for language: ", prelude.format.language) +] #set heading(numbering: "A.1") // reset page counter #counter(heading).update(1) +#let appendix(text) = [ + #heading( + supplement: [Appendix], + level: 2, + numbering: "A.1", + )[#text] + <#text> +] + // ------------------------------------------ // Put your appendencies here and link them // to correclty reference them in the document @@ -42,10 +57,9 @@ // Example: // -// == Appendix title -// +// #appendix([Titel]) // // Some appendix content goes here -// Then reference with in the document: -// @appendix-section-link-name \ No newline at end of file +// Then reference it in the document: +// @Titel diff --git a/src/pages/introduction.typ b/src/pages/introduction.typ index 793dbe4..324483d 100644 --- a/src/pages/introduction.typ +++ b/src/pages/introduction.typ @@ -2,7 +2,3 @@ #import "../prelude.typ" as prelude = Einleitung - -#pagebreak() - -= Test \ No newline at end of file