Icon sets

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
22 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Re: Icon sets

dxli
we can use a special 'character' to indicate "/"

for example, ":", "#", etc.

If we can organize the svg file in a tree similar to directory tree, it's even better.

xnakos wrote
I can provide a full solution tomorrow. What I suggest is this:

1. The "/" character is not used for normal layer names (I believe this holds now).

2. The default exporting directory is the current directory (override immediately to avoid that).

3. Overriding the exporting directory occurs using dummy layers in the huge svg in this way:

    ./    for using the current directory for exporting
    ./asdf/    for creating a directory asdf in the current directory and putting everything that follows, unless overriden, there
    ./asdf/zxcv/    for creating the directory structure and putting everything that follows, unless overriden, there

    ./asf/sdf/&./uidfh/sdfjhk/&./sdfhj/cuyud/ for inserting the stuff that follows into multiple directories (for redundancy fans)

Tell me what you think. I tested using python 2.7.3 and the first inkscape svg given in this thread. I also took a random svg and tried it with LibreCAD, built it and it worked fine as an icon.

Known issue: Thumbnails are not working when viewing the svgs in gnome. But there is a solution. Open the svg as a text file and replace all occurences of "ns0:" with "" (nothing) (without the quotes). Of course, this can be fixed very easily using the script too.

Have in mind that the layers in the svg are stored in reverse, that is the layer at the bottom (when viewing it in inkscape) is the first layer (group element) that appears in the svg/xml file.
Reply | Threaded
Open this post in threaded view
|

Re: Icon sets

xnakos
This is a new version of the python script plus the first svg that wed submitted in this thread. The only change is that I inserted 4 dummy layers, that represent directory structures, to show how it works.

explode.py

librecad-icons_icons_wed_dummy_dir_layers.svg

Same usage as before. Tell me what you think.
12