# FillRule 枚举

## 定义

``public enum class FillRule``
``public enum FillRule``
``type FillRule = ``
``Public Enum FillRule``

FillRule

## 字段

 EvenOdd 0 通过从一点向任意方向绘制一条射向无穷远的射线，然后计算给定形状中与该射线相交的路径段的数目，从而确定该点是否位于填充区域的规则。Rule that determines whether a point is in the fill region by drawing a ray from that point to infinity in any direction and counting the number of path segments within the given shape that the ray crosses. 如果此数目为奇数，那么该点则在内部；如果为偶数，则该点在外部。If this number is odd, the point is inside; if even, the point is outside. Nonzero 1 通过从一点向任意方向绘制一条射向无穷远的射线，并检查一段形状与射线相交的位置，从而确定该点是否位于路径的填充区域的规则。Rule that determines whether a point is in the fill region of the path 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 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.