LayerEditLockingStatus

This page is part of the Draft OpenRaster specification.


State: Implemented (awaiting schema merge) Bug: https://bugs.freedesktop.org/show_bug.cgi?id=37714

Layer Edit Locking Status

Editor applications sometimes have a concept of layers which are currently locked to prevent accidental editing. This state should be saved as part of OpenRaster files which might be opened again for editing in order to assist user workflow. Therefore, the <layer/> element in a layer stack definition should support the following extra attribute:

Example

When a user does not wish to accidentally paint colour onto a monochrome sketch layer, they may wish to edit-lock that layer in the user interface. When the working document is saved, such a layer stack might be saved as:

<stack>
  <layer name="sketch" x="0" y="0" src="data/layer001.png" edit-locked="true"/>
  <layer name="colours" x="-512" y="-128" src="data/layer002.png"/>
</stack>

Impact on Applications

This change has no impact on the viewing baseline intent.

Applications supporting the full baseline intent which permit layers to be made immutable by the user to prevent accidental edits should mark edit-locked layers with the edit-locked attribute when saving, and restore their edit-locked state when loading. Applications may impose their own definition of what edit-locked actually means; for example, in MyPaint, layers marked as locked in this way cannot be painted to, but are also unavailable for selection by brushstroke or for brushstroke picking.

The edit-locked attribute must be omitted when saving for the archival intent.

Support

Implemented in Krita and MyPaint development trunks since 2012-03-26.