Comment 11 for bug 168958

Revision history for this message
Wong Cho Ching (chwong249664) wrote :

I have some ideas on solutions to this bug

A. How about making the content of inkscape:export-filename relative? Relativize the path have the following benifits:
* Fix privacy issue in some extent. However, it won't help if the export destination is too far away from the original one.
* As a bonus, it fixes file migration problem. In the current version of inkscape:
1. In the directory /home/user/Document/, create the file drawing.svg
2. Export it to /home/user/Document/drawing.svg
3. Somehow, you want to move the everything from /home/user/Document/ to /home/user/Desktop/
4. Now use the export function on inkscape. Uh oh. It still exports to /home/user/Document/
OR:
1. create an export drawing.svg in USB pendrive
2. plug the USB pendrive on another computer. Uh oh! The absolute export path no longer works.
^ That's why relativize the path can be useful.
Maybe we can set a limit of directory layers for relativization of path. So that path won't be relativized if the export file is 2, or 3 layers of directory away from the source file.

B. Encrypt inkscape:export-filename. XOR encryption should be good enough. Store the key in inkscape preference. Then store the encrypted data to inkscape:export-filename
The advantage of using this method compared with A is that it works no matter where is the export file located in
One of the problem of this idea is that it won't work if inkscape data file got deleted, or the user is launching another copy of inkscape. It is common because of the following reason:
* System upgrade
* The .svg file is stored in a portable device

C. Use both method. For absolute path, use method B. For relativized path, use method A
The issue of using this method is that this would change more code than using single method.

How do you think about it?