Loading...
Searching...
No Matches
doc_render_fill_rule Class Reference

## Detailed Description

  The attribute "fill-rule" is used to define how polygons should be filled. In the SBML Level 3 Version 1 Render specification, the following are the allowable values for "fill-rule":

  - `"nonzero"`: This value determines the "insideness" of a point in the shape by drawing a ray from that point to infinity in any direction and then examining the places where a segment of the shape crosses the ray. Starting with a count of zero, add one each time a path segment crosses the ray from left to right and subtract one each time a path segment crosses the ray from right to left. After counting the crossings, if the result is zero then the point is outside the path. Otherwise, it is inside.

  - `"evenodd"`: This value determines the "insideness" of a point in the shape by drawing a ray from that point to infinity in any direction and counting the number of path segments from the given shape that the ray crosses. If this number is odd, the point is inside; if even, the point is outside.

  - `"inherit"`: This value declares the "insideness" of a point in the shape by declaring that the property takes the same computed value as the property for the element's parent. The inherited value, which is normally only used as a fallback value, can be clarified by setting 'inherit' explicitly. NOTE: This value is NOT in the Level 3 Version 1 Render specification, but was left out due to an oversight: the value has long been part of the codebase. It is provided here as a convenience. Elements with a fill-rule set to "inherit" actually behave identicaly to elements without a fill-rule attribute at all, since this attribute always takes the value of a parent element if not defined explicitly.