Gimp - an easy way to make many layers visible?

In Gimp, I created a .xcf file, which consists of 200 layers. Some are visible and some are not. Now I want to create an image consisting of all layers, so I have to make all layers visible. Later I will have to return to a state where some layers are visible and some are not. How can I achieve this without clicking a few hundred cells to view?

+4
source share
1 answer

Shift + Click on the eye icon (eycon?) Of the layer in the layers dialog box or where it should be if the layer is currently invisible.

This will:

  • make the layer you click visible

. http://docs.gimp.org/2.8/en/gimp-dialogs-structure.html#gimp-layer-dialog

, File- > Revert,

...

... , ...

Python GIMP, Filters- > Python-Fu- > . , , , :

pdb.gimp_image_undo_group_start(gimp.image_list()[0])
for layer in gimp.image_list()[0].layers:
    layer.visible = True

pdb.gimp_image_undo_group_end(gimp.image_list()[0])

, . , visiblity .

... ?

, .

, , , , .

, , , , - pdb.gimp_item_is_group (layer) true . , , , , .

Python ( gimp.Image.layers - ) -, , . .

, if, :

pdb.gimp_image_undo_group_start(gimp.image_list()[0])

# iterate layer groups
for group in [group for group in gimp.image_list()[0].layers if pdb.gimp_item_is_group(group)]:
    # you want a group.name check here to pick a specific group
    for layer in group.layers:
        layer.visible = True

# iterate non-group layers
for layer in gimp.image_list()[0].layers:
    layer.visible = True

pdb.gimp_image_undo_group_end(gimp.image_list()[0])

... ?

, - . - .

, , .

+8

Source: https://habr.com/ru/post/1612690/


All Articles