Enum Class FillRule

java.lang.Object
java.lang.Enum<FillRule>
org.gnome.gsk.FillRule
All Implemented Interfaces:
Serializable, Comparable<FillRule>, Constable, Enumeration

@Generated("org.javagi.JavaGI") public enum FillRule extends Enum<FillRule> implements Enumeration

Specifies how paths are filled.

Whether or not a point is included in the fill is determined by taking a ray from that point to infinity and looking at intersections with the path. The ray can be in any direction, as long as it doesn't pass through the end point of a segment or have a tricky intersection such as intersecting tangent to the path.

(Note that filling is not actually implemented in this way. This is just a description of the rule that is applied.)

New entries may be added in future versions.

Since:
4.14
  • Enum Constant Details

    • WINDING

      public static final FillRule WINDING
      If the path crosses the ray from left-to-right, counts +1. If the path crosses the ray from right to left, counts -1. (Left and right are determined from the perspective of looking along the ray from the starting point.) If the total count is non-zero, the point will be filled.
    • EVEN_ODD

      public static final FillRule EVEN_ODD
      Counts the total number of intersections, without regard to the orientation of the contour. If the total number of intersections is odd, the point will be filled.
  • Method Details

    • values

      public static FillRule[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static FillRule valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • of

      public static FillRule of(int value)
      Create a new FillRule for the provided value
      Parameters:
      value - the enum value
      Returns:
      the enum for the provided value
    • getValue

      public int getValue()
      Get the numeric value of this enum
      Specified by:
      getValue in interface Enumeration
      Returns:
      the enum value
    • of

      public static FillRule of(MemorySegment address)
      Create a new FillRule for the value in the provided memory address.
      Parameters:
      address - the memory address holding a enum value
      Returns:
      the enum for the value in the provided memory address
    • getType

      public static @Nullable Type getType()
      Get the GType of the FillRule class.
      Returns:
      the GType