mirror of
https://github.com/C0ffeeCode/typst-dhbw-technik-template.git
synced 2025-12-28 17:22:19 +01:00
Update to replace deprecated features with modern ones:
- Use Linux Libertine's sucessor Libertinus Serif by default - use `context`/`here()` instead of deprecated `locate` - Recommend Tinymist over deprecated Typst LSP
This commit is contained in:
parent
573e87a15d
commit
bb437af760
3 changed files with 20 additions and 20 deletions
|
|
@ -10,8 +10,8 @@ To compile your document,
|
||||||
you need to take the `thesis.typ` file as the input file.
|
you need to take the `thesis.typ` file as the input file.
|
||||||
To use the CLI, compile using `typst watch thesis.typ`
|
To use the CLI, compile using `typst watch thesis.typ`
|
||||||
or `typst compile thesis.typ`.
|
or `typst compile thesis.typ`.
|
||||||
If you intend to use the VS Code plug-in "Typst-LSP",
|
|
||||||
make sure it is either configured to only take the `thesis.typ` as input
|
If you intend to use the VS Code extension "Typst-LSP", don't,
|
||||||
or not to perform compilation at all (to use the CLI).
|
and use the Tinymist Typst extension instead.
|
||||||
|
|
||||||
This is a adapted version of a template by [@satoqz](https://github.com/satoqz/).
|
This is a adapted version of a template by [@satoqz](https://github.com/satoqz/).
|
||||||
|
|
|
||||||
34
template.typ
34
template.typ
|
|
@ -184,7 +184,7 @@
|
||||||
|
|
||||||
// suggested font and font size by the DHBW style guide
|
// suggested font and font size by the DHBW style guide
|
||||||
#set text(
|
#set text(
|
||||||
font: "Linux Libertine",
|
font: "Libertinus Serif",
|
||||||
// font: "New Computer Modern Sans",
|
// font: "New Computer Modern Sans",
|
||||||
size: 12pt,
|
size: 12pt,
|
||||||
hyphenate: false,
|
hyphenate: false,
|
||||||
|
|
@ -499,25 +499,25 @@
|
||||||
#let acro(short, pref: "normal", append: "") = {
|
#let acro(short, pref: "normal", append: "") = {
|
||||||
let item = acronyms.at(short)
|
let item = acronyms.at(short)
|
||||||
|
|
||||||
locate(loc => {
|
context({
|
||||||
let entries = acroStates.at(loc).filter(e => e == short);
|
let entries = acroStates.at(here()).filter(e => e == short);
|
||||||
|
|
||||||
// Already used once
|
// Already used once
|
||||||
if entries.len() > 0 {
|
if entries.len() > 0 {
|
||||||
if pref == "long" {
|
if pref == "long" {
|
||||||
link(label(short))[#item#append]
|
link(label(short))[#item#append]
|
||||||
|
} else {
|
||||||
|
link(label(short))[#short#append]
|
||||||
|
}
|
||||||
|
// First usage
|
||||||
} else {
|
} else {
|
||||||
link(label(short))[#short#append]
|
acroStates.update(e => {e.push(short); e;});
|
||||||
|
if pref == "short" {
|
||||||
|
link(label(short))[#short#append (#item)]
|
||||||
|
} else {
|
||||||
|
link(label(short))[#item#append (#short)]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// First usage
|
|
||||||
} else {
|
|
||||||
acroStates.update(e => {e.push(short); e;});
|
|
||||||
if pref == "short" {
|
|
||||||
link(label(short))[#short#append (#item)]
|
|
||||||
} else {
|
|
||||||
link(label(short))[#item#append (#short)]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
BIN
thesis.pdf
Normal file
BIN
thesis.pdf
Normal file
Binary file not shown.
Loading…
Reference in a new issue