Gimp.Layer.add_alpha

### Method

# Gimp Layeradd_alpha

#### Declaration [src]

    gboolean
    gimp_layer_add_alpha (
      GimpLayer* layer
    )

#### Description [src]

Add an alpha channel to the layer if it doesn’t already have one.

This procedure adds an additional component to the specified layer if it does not already possess an alpha channel. An alpha channel makes it possible to clear and erase to transparency, instead of the background color. This transforms layers of type RGB to RGBA, GRAY to GRAYA, and INDEXED to INDEXEDA.

#### Return value

Type: `gboolean`

TRUE on success.