Class CellRendererToggle.Builder<B extends CellRendererToggle.Builder<B>>

Type Parameters:
B - the type of the Builder that is returned
All Implemented Interfaces:
BuilderInterface
Enclosing class:
CellRendererToggle

public static class CellRendererToggle.Builder<B extends CellRendererToggle.Builder<B>> extends CellRenderer.Builder<B>
Inner class implementing a builder pattern to construct a GObject with properties.
  • Constructor Details

    • Builder

      protected Builder()
      Default constructor for a Builder object.
  • Method Details

    • build

      public CellRendererToggle build()
      Finish building the CellRendererToggle object. This will call GObject.withProperties(Type, String[], Value[]) to create a new GObject instance, which is then cast to CellRendererToggle.
      Overrides:
      build in class CellRenderer.Builder<B extends CellRendererToggle.Builder<B>>
      Returns:
      a new instance of CellRendererToggle with the properties that were set in the Builder object.
    • setActivatable

      public B setActivatable(boolean activatable)
    • setActive

      public B setActive(boolean active)
    • setInconsistent

      public B setInconsistent(boolean inconsistent)
    • setRadio

      public B setRadio(boolean radio)
    • onToggled

      public B onToggled(CellRendererToggle.ToggledCallback handler)

      The ::toggled signal is emitted when the cell is toggled.

      It is the responsibility of the application to update the model with the correct value to store at path. Often this is simply the opposite of the value currently stored at path.

      Parameters:
      handler - the signal handler
      Returns:
      the Builder instance is returned, to allow method chaining
      See Also: