Class Preset
Build from Preset.h
Krita 5.2.0

The Preset class Preset is a resource object that stores brush preset data.

An example for printing the current brush preset and all its settings:

from krita import *view = Krita.instance().activeWindow().activeView()preset = Preset(view.currentBrushPreset())print ( preset.toXML() )

Methods

Preset(resource: Resource) fromXML(xml: str) toXML()str

Member documentation

Preset(resource: Resource)
Krita 5.2.0

Parameters

resource(no description provided)

Return

(no description provided)

fromXML(xml: str)
Krita 5.2.0

convert the preset settings into a preset formatted xml.

Parameters

xml

valid xml preset string.

toXML()str
Krita 5.2.0

convert the preset settings into a preset formatted xml.

Return

the xml in a string.