Layer types

All layer nodes can use next tag, see Creating blueprint > Nesting. In the following list of layer types parameters are formatted as follows:

  • name (type, default if optional) Description

Note

Setting add_to_position = -1 adds the layer to a recently defined group.

image

Create new image. Needed for any layer creation.

  • size (tuple) Image dimensions in pixels note

  • name (str, Card Assembler Image) Image name

monochrome

Single color filled layer.

  • size (tuple) Layer dimensions in pixels

  • color (str) Layer color in hex code

  • name (str, Monochrome): Layer name

  • position (tuple, 0, 0)

  • add_to_position (int, 0) Position among layers (-1 for group)

import_layer_load

Load new data image. The file has to be in the data folder. Filename is specified in the XML file. Name parameter is used in the XML file to reference the imported file. That’s why it’s not an optional parameter.

import_layer

Copy layer from a data image.

  • target_file (str) Use name filled in import_layer_load

  • target_layer (str) Name of the layer to be imported in the target file

  • add_to_position (int, 0) Position among layers (-1 for group)

  • name (str, target_layer) Layer name

  • position (tuple, 0, 0)

group

Create new layer group. To fill next layers in, set theirs add_to_position parameter to -1.

  • add_to_position (int, 0) Position among layers (-1 for group)

  • name (str, Group) Group name

text

Text layer.

  • text (str) Text

  • font (str) Font name

  • font_size (int) Font size

  • font_scale (float, 1) Multiply font_size

  • add_to_position (int, 0) Position among layers (-1 for group)

  • name (str, Gimp default = Text Layer) Layer name

  • color (str, #000000) Text color in hex code

  • size (tuple, autosize) Layer dimensions in pixels

  • line_spacing (float, 0) Line separation change

  • letter_spacing (float, 0) Letters separation change

  • justification (int, 0) Either left (0), right (1), center (2) or fill (3)

  • position (tuple, 0, 0)

select

New selection by percentage of image size.

  • mode (str, select) Either select, select_invert or deselect

  • left (float, 0) Left edge position in percentage of the image size

  • right (float, 100) Right edge position in percentage of the image size

  • top (float, 0) Top edge position in percentage of the image size

  • botton (float, 100) Bottom edge position in percentage of the image size

mask

Mask layer. Create a mask for the given layer from the given selection.

  • target_layer (str) Layer to be masked

  • other parameters are passed to select

hide

Ignore command. Used for overrides, i.e. hiding a predefined (template) layer.