Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from krita import *
- d = Krita.instance().activeDocument()
- print (d)
- i = InfoObject();
- i.setProperty("color", QColor(100, 100, 200, 255))
- print(i)
- s = Selection();
- s.select(0, 0, d.width(), d.height(), 255)
- print (s)
- n = d.createFillLayer("test", "color", i, s)
- print (n)
- r = d.rootNode();
- print(r)
- c = r.childNodes();
- print(c)
- r.addChildNode(n, c[0])
- d.refreshProjection()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement