Class GLTextureBuilder.Builder<B extends GLTextureBuilder.Builder<B>>

java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gdk.GLTextureBuilder.Builder<B>
Type Parameters:
B - the type of the Builder that is returned
All Implemented Interfaces:
BuilderInterface
Enclosing class:
GLTextureBuilder

public static class GLTextureBuilder.Builder<B extends GLTextureBuilder.Builder<B>> extends GObject.Builder<B>
Inner class implementing a builder pattern to construct a GObject with properties.
Since:
4.12
  • Constructor Details

    • Builder

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

    • build

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

      public B setColorState(ColorState colorState)
      The color state of the texture.
      Parameters:
      colorState - the value for the color-state property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setContext

      public B setContext(GLContext context)
      The context owning the texture.
      Parameters:
      context - the value for the context property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setFormat

      public B setFormat(MemoryFormat format)
      The format when downloading the texture.
      Parameters:
      format - the value for the format property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setHasMipmap

      public B setHasMipmap(boolean hasMipmap)
      If the texture has a mipmap.
      Parameters:
      hasMipmap - the value for the has-mipmap property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setHeight

      public B setHeight(int height)
      The height of the texture.
      Parameters:
      height - the value for the height property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setId

      public B setId(int id)
      The texture ID to use.
      Parameters:
      id - the value for the id property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setSync

      public B setSync(MemorySegment sync)

      An optional GLSync object.

      If this is set, GTK will wait on it before using the texture.

      Parameters:
      sync - the value for the sync property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setUpdateRegion

      public B setUpdateRegion(org.freedesktop.cairo.Region updateRegion)
      The update region for Gdk.GLTextureBuilder:update-texture.
      Parameters:
      updateRegion - the value for the update-region property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setUpdateTexture

      public B setUpdateTexture(Texture updateTexture)
      The texture Gdk.GLTextureBuilder:update-region is an update for.
      Parameters:
      updateTexture - the value for the update-texture property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12
    • setWidth

      public B setWidth(int width)
      The width of the texture.
      Parameters:
      width - the value for the width property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.12