updated manual
This commit is contained in:
parent
b8a7adb58f
commit
60898d1e60
@ -147,4 +147,22 @@ wire.wire("w1", ((0, 0), (1, 1)), style: "zigzag")
|
||||
wire.wire("w2", ((0, 0), (1, -.5)),
|
||||
style: "zigzag", zigzag-ratio: 80%)
|
||||
wire.intersection("w1.zig")
|
||||
```)
|
||||
```)
|
||||
|
||||
#let capacitor = example(```
|
||||
electrical.capacitor(
|
||||
x: 0, y: 0, w: 2, h: 1, id: "a",
|
||||
scales: (100%, 80%), gap: 0.3
|
||||
)
|
||||
|
||||
electrical.capacitor(
|
||||
x: 4, y: -0.5, w: 1, h: 2, id: "b",
|
||||
vertical: true, symbols: ([+], none)
|
||||
)
|
||||
```, vertical: true)
|
||||
|
||||
#let resistor = example(```
|
||||
electrical.resistor(x: 0, y: 0, w: 2, h: 0.5, id: "a", zigzags: 8)
|
||||
electrical.resistor(x: 4, y: -0.5, w: 0.5, h: 2, id: "b", vertical: true)
|
||||
electrical.resistor(x: 6.5, y: 0, w: 2, h: 0.5, id: "c", zigzags: none)
|
||||
```, vertical: true)
|
BIN
manual.pdf
BIN
manual.pdf
Binary file not shown.
23
manual.typ
23
manual.typ
@ -4,6 +4,7 @@
|
||||
#import "doc/examples.typ"
|
||||
#import "src/circuit.typ": circuit
|
||||
#import "src/element.typ"
|
||||
#import "src/electrical.typ"
|
||||
#import "src/gates.typ"
|
||||
#import "src/util.typ"
|
||||
#import "src/wire.typ"
|
||||
@ -195,4 +196,24 @@ Simply import #link("src/lib.typ") and call the `circuit` function:
|
||||
)
|
||||
)
|
||||
|
||||
#tidy.show-module(gates-docs, sort-functions: false)
|
||||
#tidy.show-module(gates-docs, sort-functions: false)
|
||||
|
||||
#pagebreak()
|
||||
|
||||
#let electrical-docs = tidy.parse-module(
|
||||
read("src/elements/electrical/capacitor.typ") + "\n" +
|
||||
read("src/elements/electrical/resistor.typ") + "\n",
|
||||
name: "electrical",
|
||||
scope: (
|
||||
element: element,
|
||||
circuit: circuit,
|
||||
electrical: electrical,
|
||||
draw: draw,
|
||||
wire: wire,
|
||||
tidy: tidy,
|
||||
examples: examples,
|
||||
doc-ref: doc-ref
|
||||
)
|
||||
)
|
||||
|
||||
#tidy.show-module(electrical-docs, sort-functions: false)
|
Loading…
Reference in New Issue
Block a user