Class Assistant.Builder<B extends Assistant.Builder<B>>

Type Parameters:
B - the type of the Builder that is returned
All Implemented Interfaces:
Accessible.Builder<B>, BuilderInterface
Enclosing class:
Assistant

public static class Assistant.Builder<B extends Assistant.Builder<B>> extends Window.Builder<B> implements Accessible.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 Assistant build()
      Finish building the Assistant object. This will call GObject.withProperties(Type, String[], Value[]) to create a new GObject instance, which is then cast to Assistant.
      Overrides:
      build in class Window.Builder<B extends Assistant.Builder<B>>
      Returns:
      a new instance of Assistant with the properties that were set in the Builder object.
    • setUseHeaderBar

      @Deprecated public B setUseHeaderBar(int useHeaderBar)
      Deprecated.
      This widget will be removed in GTK 5

      true if the assistant uses a GtkHeaderBar for action buttons instead of the action-area.

      For technical reasons, this property is declared as an integer property, but you should only set it to true or false.

      Parameters:
      useHeaderBar - the value for the use-header-bar property
      Returns:
      the Builder instance is returned, to allow method chaining
    • onApply

      @Deprecated public B onApply(Assistant.ApplyCallback handler)
      Deprecated.
      This widget will be removed in GTK 5

      Emitted when the apply button is clicked.

      The default behavior of the GtkAssistant is to switch to the page after the current page, unless the current page is the last one.

      A handler for the ::apply signal should carry out the actions for which the wizard has collected data. If the action takes a long time to complete, you might consider putting a page of type AssistantPageType.PROGRESS after the confirmation page and handle this operation within the Gtk.Assistant::prepare signal of the progress page.

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

      @Deprecated public B onCancel(Assistant.CancelCallback handler)
      Deprecated.
      This widget will be removed in GTK 5
      Emitted when then the cancel button is clicked.
      Parameters:
      handler - the signal handler
      Returns:
      the Builder instance is returned, to allow method chaining
      See Also:
    • onClose

      @Deprecated public B onClose(Assistant.CloseCallback handler)
      Deprecated.
      This widget will be removed in GTK 5
      Emitted either when the close button of a summary page is clicked, or when the apply button in the last page in the flow (of type AssistantPageType.CONFIRM) is clicked.
      Parameters:
      handler - the signal handler
      Returns:
      the Builder instance is returned, to allow method chaining
      See Also:
    • onEscape

      @Deprecated public B onEscape(Assistant.EscapeCallback handler)
      Deprecated.
      This widget will be removed in GTK 5
      The action signal for the Escape binding.
      Parameters:
      handler - the signal handler
      Returns:
      the Builder instance is returned, to allow method chaining
      See Also:
    • onPrepare

      @Deprecated public B onPrepare(Assistant.PrepareCallback handler)
      Deprecated.
      This widget will be removed in GTK 5

      Emitted when a new page is set as the assistant's current page, before making the new page visible.

      A handler for this signal can do any preparations which are necessary before showing page.

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