Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
with
74 additions
and 4 deletions.
- +9 −4 extras/CactusFramer/static/app.coffee
- +49 −0 framer/Utils.coffee
- +16 −0 test/tests/UtilsTest.coffee
@@ -1,6 +1,11 @@ | ||
Framer.Device = new Framer.DeviceView() | ||
Framer.Device.setupContext() | ||
|
||
layer = new Layer width:10000, height:10000 | ||
style = | ||
font: "20px/1em Menlo" | ||
|
||
Framer.Device.rotateRight() | ||
layer = new Layer | ||
layer.backgroundColor = "rgba(255,0,0,.4)" | ||
layer.style = style | ||
layer.html = "Hello Koen Bok" | ||
|
||
layer.frame = Utils.textSize(layer.html, style, {width:100}) | ||
print layer.frame |