Is there any way to save an array or dictionary directly into/with a krita document?

what the title says. is there any slot where i can add additional information into a krita document and also be able to save it in the kra file on save?

(i dont know , im kinda sure ive seen someone develop a note taking addon for attaching notes to different layers. maybe ive dreamed that though because i cannot find it anymore , i wanted to take a look how he did it …

This one?

I’m sure @Grum999 will be able to explain it.

Hi

Grum999

yes that one ! thanx

haha you´re the man ! should have known its yours , absolutely amazing work ! heck , such a big and versatile plugin. thanx for opensourcing it. everything i need should be in there somewhere :heart:

Looking in BuliNote code might be a little bit more complex than just reading link I gave, as code to write stuff in Krita file is nothing compared to everything that has been implemented in BuliNote (user interfaces, encoding/decoding data, managing notes and different types of linked data…)

Embedding data in Krita file is literally one line of code :slight_smile:
Same to read it.

In your case (list of dict) you have to serialize data in a binary string to write it, and unserialize binary data read from file.
There’s many possible method to serialize/unserialize data, you have to find one that match your need (type of data, simplicity, …)

Grum999