If the second word is recognized as ``add'', and the remaining tokens are valid layer names, layers are created (or extracted from the removed list) and added to the end of the layer table.
If the second word is recognized as ``insert'', and the token that follows is a valid layer name, the layer will be inserted into the layer table at a position given by the integer index. If the index is missing, negative, or larger than the number of layers in the table, the layer is appended to the table. If the index is zero, the layer will be inserted at the index of the current layer. Otherwise, the layer is inserted into the table at the position given by the index, with one being the first (topmost) position.
The ``remove'' form removes the listed layers from the layer table. Removed layers are saved, and can be reinserted if needed.
The ``rename'' form renames the layer named oldname to newname.