mirror of
https://github.com/yglukhov/kiwi
synced 2026-01-02 16:34:43 +00:00
No description
| .github/workflows | ||
| kiwi | ||
| tests | ||
| .gitignore | ||
| kiwi.nim | ||
| kiwi.nimble | ||
| LICENSE | ||
| README.md | ||
kiwi

A Nim port of the kiwi-java implementation of the Cassowary constraint solving algorithm
Usage
import kiwi
let s = newSolver()
let x = newVariable()
let y = newVariable()
s.addConstraint(x == 20)
s.addConstraint(x + 2 == y + 10)
s.updateVariables()
assert(x.value == 20)
assert(y.value == 12)
Links
- overconstrained - collection of similar projects (github)