prep for release v0.0.2 #1

Merged
HEL merged 13 commits from dev into main 2024-06-15 12:20:48 +00:00
10 changed files with 75 additions and 0 deletions
Showing only changes of commit 9f8bf02522 - Show all commits

40
gallery.bash Normal file
View File

@ -0,0 +1,40 @@
#!/bin/bash
PDFS=false
while getopts "p" flag
do
case "${flag}" in
p) PDFS=true;;
esac
done
echo "Generating gallery images"
set -- ./gallery/example*.typ
cnt="$#"
i=1
for f
do
f2="${f/typ/png}"
echo "($i/$cnt) $f -> $f2"
typst c --root ./ "$f" "$f2"
i=$((i+1))
done
if [ "$PDFS" = true ]
then
echo
echo "Generating gallery PDFs"
set -- ./gallery/*.typ
cnt="$#"
i=1
for f
do
f2="${f/typ/pdf}"
echo "($i/$cnt) $f -> $f2"
typst c --root ./ "$f" "$f2"
i=$((i+1))
done
fi

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 378 KiB

After

Width:  |  Height:  |  Size: 376 KiB

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 303 KiB

After

Width:  |  Height:  |  Size: 302 KiB

BIN
gallery/example3.pdf Normal file

Binary file not shown.

BIN
gallery/example3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 487 KiB

23
gallery/example3.typ Normal file
View File

@ -0,0 +1,23 @@
#import "../src/lib.typ": schema, config
#let example = schema.load("/gallery/example1.yaml")
//#schema.render(example)
= Chapter 1
#lorem(50)
= Chapter 2
#lorem(50)
== Section 2.1
#lorem(20)
#figure(
schema.render(example, config: config.config(all-bit-i: false)),
caption: "Test schema"
)
#lorem(20)
= Chapter 3

12
gallery/example3.yaml Normal file
View File

@ -0,0 +1,12 @@
structures:
main:
bits: 32
ranges:
31-24:
name: op
23-16:
name: r1
15-8:
name: r2
7-0:
name: r3

Binary file not shown.