Layer
Layers are the basic containers of Framer, which can contain images, videos, or text. You can position layers with numeric values and dynamic values. Layers contain many properties that define their appearance, such as opacity, rotation and scale. Layers can also be nested to adjust their hierarchy.
To create a layer, use the new keyword. Every layer has a set of default properties: a blue background, and a default width and height of 100.
译:层的基本容器组成者,它可以包含 图片 , 视频 ,或 文本 。 你可以位置层 数字 价值观和 动态 值。 层包含很多属性,定义他们的外表,如 不透明度 , 旋转 和 规模。层也可以 嵌套的 调整他们的层次结构。
创建一个层,使用新关键字。每层都有一组默认属性:一个蓝色背景,100一个默认的宽度和高度。
layerA = new Layer
You can set layer properties when creating them:
译:你可以设置图层属性在创建:
layerA = new Layer
x: 100
y: 100
width: 250
height: 250
opacity: 0.5
backgroundColor: "white"
And you can also override them later:
译:以后你也可以覆盖它们:
layerA = new Layer
x: 100
y: 100
layerA.x = 200