forked from HEL/circuiteria
change y logic to relative
This commit is contained in:
parent
9a1fda087c
commit
4e125ef40c
@ -54,20 +54,24 @@
|
|||||||
let (ctx, to-pos) = coordinate.resolve(ctx, (rel: (offset, 0), to: to))
|
let (ctx, to-pos) = coordinate.resolve(ctx, (rel: (offset, 0), to: to))
|
||||||
x = to-pos.at(0)
|
x = to-pos.at(0)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (type(y) == dictionary) {
|
if (type(y) == dictionary) {
|
||||||
let from = y.from
|
let offset = y.rel
|
||||||
let to = y.to
|
let to = y.to
|
||||||
|
let (ctx, to-pos) = coordinate.resolve(ctx, (rel: (0, offset), to: to))
|
||||||
let dy
|
y = to-pos.at(1)
|
||||||
if to == "out" {
|
// let from = y.from
|
||||||
dy = height / 2
|
// let to = y.to
|
||||||
} else {
|
|
||||||
dy = height * (i + 0.5) / inputs
|
// let dy
|
||||||
}
|
// if to == "out" {
|
||||||
|
// dy = height / 2
|
||||||
let (ctx, from-pos) = coordinate.resolve(ctx, from)
|
// } else {
|
||||||
y = from-pos.at(1) + dy - height
|
// dy = height * (i + 0.5) / inputs
|
||||||
|
// }
|
||||||
|
|
||||||
|
// let (ctx, from-pos) = coordinate.resolve(ctx, from)
|
||||||
|
// y = from-pos.at(1) + dy - height
|
||||||
}
|
}
|
||||||
|
|
||||||
let tl = (x, y + height)
|
let tl = (x, y + height)
|
||||||
|
Loading…
Reference in New Issue
Block a user