# Gimp.GroupLayer.new

    function new(image: Gimp.Image, name: String): Gimp.GroupLayer {
        // Gjs wrapper for gimp_group_layer_new()
    }

Create a new group layer.

This procedure creates a new group layer with a given name. If name is null, GIMP will choose a name using its default layer name algorithm.

The new group layer still needs to be added to the image, as this is not automatic. Add the new layer with the [method@Image.insert_layer] method.

Other attributes such as layer mask modes, and offsets should be set with explicit procedure calls.

Since 3.0

image

  The image to which to add the layer.

name

  The group layer name.

Returns

  The newly created group layer. The object belongs to libgimp and you should not free it.