Manages up to three children.
The start widget is allocated at the start of the layout (left in left-to-right locales and right in right-to-left ones), and the end widget at the end.
The center widget is centered regarding the full width of the layout's.
<group>Layout containers</group>
function Get_Baseline_Position
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Gtk.Enums.Gtk_Baseline_Position
Returns the baseline position of the layout.
The current baseline position of Self.
function Get_Center_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Gtk.Widget.Gtk_Widget
Returns the center widget of the layout.
the current center widget of Self. Has transfer-ownership='none'.
function Get_End_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Gtk.Widget.Gtk_Widget
Returns the end widget of the layout.
the current end widget of Self. Has transfer-ownership='none'.
function Get_Orientation
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Gtk.Enums.Gtk_Orientation
Gets the current orienration of the layout manager.
The current orientation of Self
function Get_Shrink_Center_Last
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Boolean
Gets whether Self shrinks the center widget after other children. Since: gtk+ 4.12
whether to shrink the center widget after others
function Get_Start_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record)
return Gtk.Widget.Gtk_Widget
Returns the start widget of the layout.
The current start widget of Self. Has transfer-ownership='none'.
function Get_Type return Glib.GType
type Gtk_Center_Layout is access all Gtk_Center_Layout_Record'Class;
function Gtk_Center_Layout_New return Gtk_Center_Layout
Creates a new GtkCenterLayout.
type Gtk_Center_Layout_Record is new Gtk_Layout_Manager_Record with null record;
procedure Gtk_New (Center_Layout : out Gtk_Center_Layout)
Creates a new GtkCenterLayout. Initialize does nothing if the object was already created with another call to Initialize* or G_New.
procedure Initialize
(Center_Layout : not null access Gtk_Center_Layout_Record'Class)
Creates a new GtkCenterLayout. Initialize does nothing if the object was already created with another call to Initialize* or G_New.
procedure Set_Baseline_Position
(Center_Layout : not null access Gtk_Center_Layout_Record;
Baseline_Position : Gtk.Enums.Gtk_Baseline_Position)
Sets the new baseline position of Self
the new baseline position
procedure Set_Center_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record;
Widget : access Gtk.Widget.Gtk_Widget_Record'Class)
Sets the new center widget of Self. To remove the existing center widget, pass null.
the new center widget
procedure Set_End_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record;
Widget : access Gtk.Widget.Gtk_Widget_Record'Class)
Sets the new end widget of Self. To remove the existing center widget, pass null.
the new end widget
procedure Set_Orientation
(Center_Layout : not null access Gtk_Center_Layout_Record;
Orientation : Gtk.Enums.Gtk_Orientation)
Sets the orientation of Self.
the new orientation
procedure Set_Shrink_Center_Last
(Center_Layout : not null access Gtk_Center_Layout_Record;
Shrink_Center_Last : Boolean)
Sets whether to shrink the center widget after other children. By default, when there's no space to give all three children their natural widths, the start and end widgets start shrinking and the center child keeps natural width until they reach minimum width. If set to FALSE, start and end widgets keep natural width and the center widget starts shrinking instead. Since: gtk+ 4.12
whether to shrink the center widget after others
procedure Set_Start_Widget
(Center_Layout : not null access Gtk_Center_Layout_Record;
Widget : access Gtk.Widget.Gtk_Widget_Record'Class)
Sets the new start widget of Self. To remove the existing start widget, pass null.
the new start widget
Shrink_Center_Last_Property : constant Glib.Properties.Property_Boolean;
Whether to shrink the center widget after other children.
By default, when there's no space to give all three children their natural widths, the start and end widgets start shrinking and the center child keeps natural width until they reach minimum width.
If set to FALSE, start and end widgets keep natural width and the center widget starts shrinking instead.