w

wavy

@preview

Draw digital timing diagram in Typst using Wavedrom.

v0.1.3
MIT

Package Information

Last Updated

1. Get the package

Download the package using the TPIX CLI:

tpix get @preview/wavy:0.1.3

2. Import in your Typst file

Add this to your .typ file:

#import "@preview/wavy:0.1.3": *

Version History

0.1.3
3a542065681a...
0.1.1
c8c1e072ecf5...
0.1.0
8db8f3ea26c5...

Wavy

Draw digital timing diagram in Typst using Wavedrom.

#import "@preview/wavy:0.1.3"

#set page(height: auto, width: auto, fill: black, margin: 2em)
#set text(fill: white)

#show raw.where(lang: "wavy"): it => wavy.render(it.text)

= Wavy

Typst, now with waves.

```wavy
{
  signal:
  [
    {name:'clk',wave:'p......'},
    {name:'bus',wave:'x.34.5x',data:'head body tail'},
    {name:'wire',wave:'0.1..0.'}
  ]
}
```

```js
{
  signal:
  [
    {name:'clk',wave:'p......'},
    {name:'bus',wave:'x.34.5x',data:'head body tail'},
    {name:'wire',wave:'0.1..0.'}
  ]
}
```

Documentation

render

Render a wavedrom json5 string to an image

Arguments

  • src: str - wavedrom json5 string
  • All other arguments are passed to image so you can customize the image size

Returns

The image, of type content