Package org.gnome.gtk
Class BoxLayout.Builder<B extends BoxLayout.Builder<B>>
java.lang.Object
io.github.jwharm.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gtk.LayoutManager.Builder<B>
org.gnome.gtk.BoxLayout.Builder<B>
- Type Parameters:
B
- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
,Orientable.Builder<B>
- Enclosing class:
BoxLayout
public static class BoxLayout.Builder<B extends BoxLayout.Builder<B>>
extends LayoutManager.Builder<B>
implements Orientable.Builder<B>
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Finish building theBoxLayout
object.setBaselineChild
(int baselineChild) The child that determines the baseline of the box in vertical layout.setBaselinePosition
(BaselinePosition baselinePosition) The position of the allocated baseline within the extra space allocated to each child.setHomogeneous
(boolean homogeneous) Whether the box layout should distribute the available space equally among the children.setSpacing
(int spacing) The space to put between the children.Methods inherited from class org.gnome.gobject.GObject.Builder
onNotify
Methods inherited from class io.github.jwharm.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValues
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.jwharm.javagi.gobject.BuilderInterface
addBuilderProperty, connect, connect, getArena
Methods inherited from interface org.gnome.gtk.Orientable.Builder
setOrientation
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilder
object.
-
-
Method Details
-
build
Finish building theBoxLayout
object. This will callGObject.withProperties(org.gnome.glib.Type, java.lang.String[], org.gnome.gobject.Value[])
to create a new GObject instance, which is then cast toBoxLayout
.- Overrides:
build
in classLayoutManager.Builder<B extends BoxLayout.Builder<B>>
- Returns:
- a new instance of
BoxLayout
with the properties that were set in the Builder object.
-
setBaselineChild
The child that determines the baseline of the box in vertical layout.If the child does baseline positioning, then its baseline is lined up with the baseline of the box. If it doesn't, then the bottom edge of the child is used.
- Parameters:
baselineChild
- the value for thebaseline-child
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setBaselinePosition
The position of the allocated baseline within the extra space allocated to each child.This property is only relevant for horizontal layouts containing at least one child with a baseline alignment.
- Parameters:
baselinePosition
- the value for thebaseline-position
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setHomogeneous
Whether the box layout should distribute the available space equally among the children.- Parameters:
homogeneous
- the value for thehomogeneous
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setSpacing
The space to put between the children.- Parameters:
spacing
- the value for thespacing
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-