# Gimp.ValueArray.new

    function new(n_prealloced: Number(gint)): Gimp.ValueArray {
        // Gjs wrapper for gimp_value_array_new()
    }

Allocate and initialize a new Gimp.ValueArray, optionally preserve space for n_prealloced elements. New arrays always contain 0 elements, regardless of the value of n_prealloced.

Since 2.10

n_prealloced

  number of values to preallocate space for

Returns

  a newly allocated Gimp.ValueArray with 0 values