Inkscape.org
Beyond the Basics fill-rule behaviour
  1. #1
    inklinea inklinea @inklinea⛰️

    This is a feature I don't really use. 

    However I have noticed the following.

    On a clean Inkscape install, there is no fill-rule in the style of the object. ( As checked in the svg code via Edit>XML Editor)

    Clicking either of the ( looks like mouse ears ) fill rule icons in the fill panel will apply either fill-rule:non-zero or fill-rule:even-odd to the current object, and objects going forwards.

    According to Mozilla 

    Value : nonzero | evenodd

    Default value : nonzero

    So the fill-rule defaults to non-zero if not specified, there is no reason for it to be stated in the svg code if you only use non-zero unless you have a special application which needs that statement.

    However, once clicked on those 'mouse ears' you cannot go back, and every object from that point onwards has to have the bulk of either fill rule style properly.

    I can only two ways to turn this off. 

    1. Reset preferences ( with all other settings being reset too)

    2. edit the following in preferences.xml

    <group
         id="desktop"
         style="fill:#000000;fill-rule:evenodd">

     to     
    <group
         id="desktop"
         style="fill:#000000">

         
    with Inkscape closed. Then reopen.

    You should be able to completely delete the style="" in the desktop section ( which is what I did). The fill colour auto regenerates once Inkscape is opened.

     

    Have I got this wrong ? 

  2. #2
    Aero Aero @Aero◻️

    My observations:

    Using 1.3 beta on Windows, nonzero is sticky only for current session. Not saved to preferences.xml, but saved to SVG.

    No style saved to preferences.xml desktop section, if last used style was unset from the context menu on the status bar (bottom left) for fill and stroke.

    Even with no styles at all in preferences.xml desktop section, new objects gets fill and stroke-width style in the next session.

    No need to edit preferences.xml manually.
     

  3. #3
    marinipavingmasonry marinipavingmasonry @marinipavingmasonry

    Wow it's amazing .

  4. #4
    inklinea inklinea @inklinea⛰️

    Thanks for the reply Aero