From: Pedro L. <psl...@gm...> - 2019-10-26 16:37:25
|
Hi, I just made a graphical plugin to set and get views. It uses the set_view and get_view functions. It is available in the last option ("Show views") on the "Scene" menu. Double-click to rename a view. Erase it's name to delete it. In order to persist data in the PSE session it stores data into the mesh_clear_selection setting. It was the only way I found. How to store arbitrary data on the session? Some "ostate" string settings are preserved on the PSE session. But not all support set arbitrary data (eg, bg_image_filename). It is very hackish and not a definite solution. Just wondering, maybe a hidden "setting" (not visible to can be be used as a key-value store. It would hold serialized data (eg json or pickle) and have a pair of functions set_key(key, obj) and get(key) that read and write the setting. Another great addition would be able to set arbitrary strings to objects and atoms. But in case of implementing a key-value store would be some overlap. Best regards, [image: image.png] -- Pedro Sousa Lacerda *Laboratório de Bioinformática e Modelagem Molecular* *Faculdade de Farmácia / UFBA* *@pslacerda* *+55 71 9 9981-1856* |