Skip to content

Commit

Permalink
feat(Tabellenverzeichnis)
Browse files Browse the repository at this point in the history
chore(translations)
fix: custom verzeichnisse are displayed in toc
  • Loading branch information
lbsekr committed Jul 21, 2024
1 parent 65d9239 commit a1b0a18
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 17 deletions.
9 changes: 9 additions & 0 deletions main.typ
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,15 @@ Beim zweiten Mal wird @oidc nur abgekürzt.
#lorem(100)

=== Unter-Unterpunkt
#figure(
table(
columns: 4,
[t], [1], [2], [3],
[y], [0.3s], [0.4s], [0.8s],
),
caption: [Timing results],
)

#lorem(100)

= Zusammenfassung
Expand Down
67 changes: 51 additions & 16 deletions template.typ
Original file line number Diff line number Diff line change
Expand Up @@ -78,23 +78,56 @@ Titel und Untertitel der Arbeit],
glossary-page(translations.abkuerzungsverzeichnis, abbreviation_entries)
}

// Man könnte die ganzen Tables wsl. abstrahieren. Aber kein Bock
let table_of_code() = {
locate(loc => {
if counter(figure.where(kind: code_identifier)).final(loc).at(0) > 0 {
pagebreak()
outline(
title: translations.codeausschnittverzeichnis,
depth: 3,
indent: true,
target: figure.where(kind: code_identifier)
)
context {
pagebreak()

show outline: set heading(
outlined: true,
supplement: [#translations.vorwort]
)

outline(
title: translations.codeausschnittverzeichnis,
depth: 3,
indent: true,
target: figure.where(kind: code_identifier)
)
}

}
})
}

let table_of_tables() = {
locate(loc => {
if counter(figure.where(kind: table)).final(loc).at(0) > 0 {
context {
pagebreak()

show outline: set heading(
outlined: true,
supplement: [#translations.vorwort]
)

outline(
title: translations.tabellenverzeichnis,
depth: 3,
indent: true,
target: figure.where(kind: table)
)
}
}
}
)
}

let table_of_figures() = {
locate(loc => {
if counter(figure).final(loc).at(0) > 0 {
if counter(figure.where(kind: image)).final(loc).at(0) > 0 {
context {
if show_lists_after_content {
pagebreak()
Expand All @@ -115,6 +148,14 @@ Titel und Untertitel der Arbeit],
})
}

let lists = [
#table_of_figures()
#table_of_code()
#table_of_tables()
#glossary()
#abbreviations()
]

set document(author: authors.map(a => a.name), title: title)
set text(font: "Times New Roman", lang: language, weight: 500, size: 12pt,)
set heading(numbering: "1.1")
Expand Down Expand Up @@ -305,10 +346,7 @@ Titel und Untertitel der Arbeit],
}
if not show_lists_after_content {
table_of_figures()
table_of_code()
glossary()
abbreviations()
lists
}
set block(spacing: .65em)
Expand Down Expand Up @@ -356,10 +394,7 @@ Titel und Untertitel der Arbeit],
if show_lists_after_content {
table_of_figures()
table_of_code()
glossary()
abbreviations()
lists
}
Expand Down
4 changes: 3 additions & 1 deletion translations.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
{
"de": {
"codeausschnittverzeichnis": "Code-Ausschnitt-Verzeichnis",
"codeausschnittverzeichnis": "Codeausschnittverzeichnis",
"codeausschnitt": "Code-Ausschnitt",
"confidentalClaus": "Sperrvermerk",
"confidentalClausText": "Diese Arbeit darf Dritten, mit Ausnahme der betreuenden Dozenten und befugten Mitgliedern der Verwaltung der Provadis Hochschule, sowie Beschäftigten der Deutschen Telekom AG, ohne ausdrückliche Zustimmung der Deutschen Telekom AG nicht zugänglich gemacht werden. In begründeten Verdachtsfällen dürfen die Arbeit oder Teile davon von der Provadis Hochschule einer Plagiatsprüfung durch einen Plagiatssoftware-Anbieter unterzogen werden und auf dort eingerichteten Provadis Hochschul-spezifischen Datenbanken temporär gespeichert werden. Der Sperrvermerk ist im Fall einer Plagiatsprüfung nicht wirksam.\n\nEine Vervielfältigung und Veröffentlichung der Arbeit ohne ausdrückliche Genehmigung durch die Deutsche Telekom AG - auch in Auszügen - ist nicht erlaubt.",
"abbildungsverzeichnis": "Abbildungsverzeichnis",
"tabellenverzeichnis": "Tabellenverzeichnis",
"appendix": "Anhang",
"kapitel": "Kapitel",
"vorwort": "Vorwort",
Expand Down Expand Up @@ -46,6 +47,7 @@
"confidentalClaus": "Confidental Clause",
"confidentalClausText": "This work may not be made accessible to third parties, with the exception of the supervising lecturers and authorized members of the administration of Provadis University, as well as employees of Deutsche Telekom AG, without the express consent of Deutsche Telekom AG. In justified cases of suspicion, Provadis Hochschule may subject the thesis or parts thereof to a plagiarism check by a plagiarism software provider and temporarily store it in Provadis Hochschule-specific databases set up there. The blocking notice is not effective in the event of a plagiarism check.\n\nReproduction and publication of the work - even in excerpts - is not permitted without the express permission of Deutsche Telekom AG.",
"abbildungsverzeichnis": "Table of figures",
"tabellenverzeichnis": "List of tables",
"appendix": "Appendix",
"kapitel": "Chapter",
"vorwort": "Preface",
Expand Down

0 comments on commit a1b0a18

Please sign in to comment.