I am mapping animals and have to display their locations in QGIS (2.12.3, Win7 64) with gender symbols (♂/♀). The outline of the symbols should be rendered in different colors corresponding to the dates of survey. The filling should be either colored or transparent respective to classes of behavior. So I generated the svg symbols with INKSCAPE and then replaced the whole „style“-line in the svg file text
style="fill:#000000;fill-opacity:0;stroke:#000000;stroke-width:10.00027084;… … ...“
with
fill="param(fill) #000" fill-opacity="param(fill-opacity) 0.0" stroke="param(outline) #000" stroke-width="param(outline-width) 3"
In QGIS I used attribute-driven rendering for the outline (attribute field “color“) and an expression to choose between either transparency or fill (case when “behav“ <> '+' then '0,0,0,0' else “color“ end)
The outline, both color and width, was displayed as I intended. In contrast, I had no control over the fill. Sometimes all symbols were filled, no matter what the attribute says, sometimes all fillings remained transparent and in the third case the symbols that should be transparent had a black (or white) fill. When I closed and reopened QGIS, the rendering of all fills changed sometimes. The outline, however, was displayed correct all the time.
Instead of '0,0,0,0' in the case-when expression above I experimented with other statements, e.g. '#000000 0.0' or 'default' to achieve correct rendering of color or transparency, but without success. I also varied the default values in the “param(…)...“ statements and omitted the whole “fill-opacity...“ statement. Again without gaining control over the fill.
In addition, it was strange to see that sometimes the fill of all symbols changed from transparent to color or vice versa when I varied the outline width. I then introduced fill-rule=”evenodd”, but again without visible effect.
I have no idea what's wrong.