CESDK/CE.SDK/Engine/API Reference/Block
Types
Get to know all available block types and their properties
The following tables document the currently available blocks and their properties.
Block properties#
audio
#
audio
#Member | Type | Default | Description |
---|---|---|---|
Member fileURI | Type string | Default "" | Description A URI referencing an audio file. |
group
#
group
#No block-specific properties.
image
#
image
#Member | Type | Default | Description |
---|---|---|---|
Member externalReference | Type string | Default "" | Description A string that may be used to determine where the URI used in imageFileURI originates from. NOT used by the block. |
Member imageFileURI | Type string | Default "" | Description A URI referencing an image file. |
Member previewFileURI | Type string | Default "" | Description A URI pointing to an image file, that's used while the resource for imageFileURI is still loading. |
Member showsPlaceholderButton | Type bool | Default true | Description Whether a placeholder button should be rendered. |
Member showsPlaceholderOverlay | Type bool | Default true | Description Whether a placeholder overlay should be rendered. |
metrics
#
metrics
#No block-specific properties.
page
#
page
#Member | Type | Default | Description |
---|---|---|---|
Member margin | Type OuterMargin2D(float left, float top, float right, float bottom) | Default OuterMargin2D(10.0) | Description Left, up, right, down page margins in local coordinates. |
Member marginEnabled | Type bool | Default false | Description Whether the bleed margin should be applied. |
Member titleTemplate | Type string | Default string("Page {{ubq.page_index}}") | Description Page label template. Includes special template variables {{ubq.page_index}} and {{ubq.name}} |
shapes/ellipse
#
shapes/ellipse
#No block-specific properties.
shapes/line
#
shapes/line
#No block-specific properties.
shapes/polygon
#
shapes/polygon
#Member | Type | Default | Description |
---|---|---|---|
Member sides | Type int | Default 5 | Description The number of sides the polygon is supposed to have. |
shapes/rect
#
shapes/rect
#No block-specific properties.
shapes/star
#
shapes/star
#Member | Type | Default | Description |
---|---|---|---|
Member innerDiameter | Type float | Default 0.5 | Description The inner diameter of the star. |
Member points | Type int | Default 5 | Description The number of tips the star is supposed to have. |
stack
#
stack
#A convenience block, that overrides its childrens position and sorting order to bring them all in a single line along its axis
. An optional spacing allows evenly spacing the items via additional elements. The stack relies on our layouting defaults: flex wrap: no wrap, align content: flex start, and align items: stretch
Member | Type | Default | Description |
---|---|---|---|
Member axis | Type uint enum : {'Horizontal', 'Vertical', 'Depth'} | Default Horizontal | Description The direction of the main stack axis, either horizontal or vertical. |
Member spacing | Type float | Default 0. | Description Adds an explicit spacing between the stacks children. This is only added between the "inner" children & doesn't add spacing towards the stacks outer edges. Negative spacing is not supported. |
Member spacingInScreenspace | Type bool | Default true | Description Whether to interpret the spacing value as pixels in screen space instead of design units. During export, the spacing is always interpreted in design units. |
sticker
#
sticker
#Member | Type | Default | Description |
---|---|---|---|
Member externalReference | Type string | Default "" | Description A string that may be used to determine where the URI used in imageFileURI originates from. NOT used by the block. |
Member imageFileURI | Type string | Default "" | Description The sticker asset id. A corresponding StickerAsset must be registered under this uri. |
Member previewFileURI | Type string | Default "" | Description A URI pointing to an image file, that's used while the resource for imageFileURI is still loading. |
text
#
text
#Member | Type | Default | Description |
---|---|---|---|
Member externalReference | Type string | Default "" | Description An external reference that may hint at the source that was used to populate fontFileURI |
Member fontFileUri | Type string | Default {} | Description The URI of a font file. |
Member fontSize | Type float | Default 10. | Description The font size in points. |
Member hideLinesOutsideOfFrame | Type bool | Default true | Description Whether or not to display lines outside the frame. |
Member horizontalAlignment | Type uint enum : {'Left', 'Right', 'Center'} | Default Left | Description The horizontal text alignment. |
Member letterSpacing | Type float | Default 0.0 | Description Relative to the original spacing. |
Member lineHeight | Type float | Default 1.0 | Description The line height relative to the font size. |
Member text | Type string | Default "" | Description The text content. |
Member verticalAlignment | Type uint enum : {'Top', 'Bottom', 'Center'} | Default Top | Description The vertical text alignment. |
vector_path
#
vector_path
#Member | Type | Default | Description |
---|---|---|---|
Member height | Type float | Default 100.0 | Description The coordinate bounds in y direction. |
Member path | Type string | Default "" | Description The path string, accepts a subset of svg path strings. |
Member width | Type float | Default 100.0 | Description The coordinate bounds in x direction. |
scene
#
scene
#Member | Type | Default | Description |
---|---|---|---|
Member aspectRatioLock | Type bool | Default true | Description Wether the ratio of the pageDimensions' width and height should remain constant when changing either dimension. Example: A page of 400x300 with aspect ratio lock ON should be resized to 800x600 when the user sets its width to 800, to maintain the aspect ratio of 4/3. |
Member defaultPageDuration | Type float | Default 5. | Description The default page duration in this scene. |
Member designUnit | Type DesignUnit | Default Pixel | Description The unit type in which the page values (size, distances etc) are defined. |
Member dpi | Type float | Default 300. | Description The DPI value to use when exporting and when converting between pixels and inches or millimeter units. For all of our purposes, this is synonymous with PPI. |
Member layout | Type SceneLayout | Default Free | Description A value describing how the scenes children are laid out. |
Member mode | Type SceneMode | Default Design | Description The mode of this scene and all elements inside of it. |
Member pageDimensions | Type Size2(float width, float height) | Default Size2(1, 1) | Description The dimension of all pages in this scene. |
Member pageFormatId | Type string | Default "" | Description The identifier of the page format configuration that was most recently selected for the pages in this scene. |
Member pixelScaleFactor | Type float | Default 1. | Description A scale factor that is applied to the final export resolution if the design unit is Pixel. |