// GENERATED — DO NOT EDIT
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/class.CenterBox.html).
pub type CenterBox
///|
pub(open) trait ICenterBox {
fn as_center_box(Self) -> CenterBox
fn get_baseline_position(Self) -> BaselinePosition = _
fn get_center_widget(Self) -> Widget? = _
fn get_end_widget(Self) -> Widget? = _
fn get_shrink_center_last(Self) -> Bool = _
fn get_start_widget(Self) -> Widget? = _
fn set_baseline_position(Self, BaselinePosition) -> Unit = _
fn set_center_widget(Self, &IWidget?) -> Unit = _
fn set_end_widget(Self, &IWidget?) -> Unit = _
fn set_shrink_center_last(Self, Bool) -> Unit = _
fn set_start_widget(Self, &IWidget?) -> Unit = _
}
///|
pub impl ICenterBox for CenterBox with fn as_center_box(self) {
self
}
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/ctor.CenterBox.new.html).
pub extern "c" fn CenterBox::new() -> CenterBox = "moonbit_gtk_center_box_new"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.get_baseline_position.html).
#borrow(self)
pub extern "c" fn CenterBox::get_baseline_position(
self : CenterBox,
) -> BaselinePosition = "moonbit_gtk_center_box_get_baseline_position"
///|
#borrow(self_)
extern "c" fn moonbit_gtk_center_box_get_center_widget(
self_ : CenterBox,
) -> @glib.Nullable[Widget] = "moonbit_gtk_center_box_get_center_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.get_center_widget.html).
pub fn CenterBox::get_center_widget(self : CenterBox) -> Widget? {
let raw_result = moonbit_gtk_center_box_get_center_widget(self)
raw_result.to_option()
}
///|
#borrow(self_)
extern "c" fn moonbit_gtk_center_box_get_end_widget(
self_ : CenterBox,
) -> @glib.Nullable[Widget] = "moonbit_gtk_center_box_get_end_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.get_end_widget.html).
pub fn CenterBox::get_end_widget(self : CenterBox) -> Widget? {
let raw_result = moonbit_gtk_center_box_get_end_widget(self)
raw_result.to_option()
}
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.get_shrink_center_last.html).
#borrow(self)
pub extern "c" fn CenterBox::get_shrink_center_last(self : CenterBox) -> Bool = "moonbit_gtk_center_box_get_shrink_center_last"
///|
#borrow(self_)
extern "c" fn moonbit_gtk_center_box_get_start_widget(
self_ : CenterBox,
) -> @glib.Nullable[Widget] = "moonbit_gtk_center_box_get_start_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.get_start_widget.html).
pub fn CenterBox::get_start_widget(self : CenterBox) -> Widget? {
let raw_result = moonbit_gtk_center_box_get_start_widget(self)
raw_result.to_option()
}
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.set_baseline_position.html).
#borrow(self)
pub extern "c" fn CenterBox::set_baseline_position(
self : CenterBox,
position : BaselinePosition,
) = "moonbit_gtk_center_box_set_baseline_position"
///|
#borrow(self_, child)
extern "c" fn moonbit_gtk_center_box_set_center_widget(
self_ : CenterBox,
child : @glib.Nullable[Widget],
) = "moonbit_gtk_center_box_set_center_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.set_center_widget.html).
pub fn CenterBox::set_center_widget(
self : CenterBox,
child : &IWidget?,
) -> Unit {
moonbit_gtk_center_box_set_center_widget(
self,
match child {
Some(v) => @glib.Nullable::some(v.as_widget())
None => @glib.Nullable::null()
},
)
}
///|
#borrow(self_, child)
extern "c" fn moonbit_gtk_center_box_set_end_widget(
self_ : CenterBox,
child : @glib.Nullable[Widget],
) = "moonbit_gtk_center_box_set_end_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.set_end_widget.html).
pub fn CenterBox::set_end_widget(self : CenterBox, child : &IWidget?) -> Unit {
moonbit_gtk_center_box_set_end_widget(
self,
match child {
Some(v) => @glib.Nullable::some(v.as_widget())
None => @glib.Nullable::null()
},
)
}
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.set_shrink_center_last.html).
#borrow(self)
pub extern "c" fn CenterBox::set_shrink_center_last(
self : CenterBox,
shrink_center_last : Bool,
) = "moonbit_gtk_center_box_set_shrink_center_last"
///|
#borrow(self_, child)
extern "c" fn moonbit_gtk_center_box_set_start_widget(
self_ : CenterBox,
child : @glib.Nullable[Widget],
) = "moonbit_gtk_center_box_set_start_widget"
///|
/// [Upstream documentation](https://docs.gtk.org/gtk4/method.CenterBox.set_start_widget.html).
pub fn CenterBox::set_start_widget(self : CenterBox, child : &IWidget?) -> Unit {
moonbit_gtk_center_box_set_start_widget(
self,
match child {
Some(v) => @glib.Nullable::some(v.as_widget())
None => @glib.Nullable::null()
},
)
}
///|
impl ICenterBox with fn get_baseline_position(self) -> BaselinePosition {
self.as_center_box().get_baseline_position()
}
///|
impl ICenterBox with fn get_center_widget(self) -> Widget? {
self.as_center_box().get_center_widget()
}
///|
impl ICenterBox with fn get_end_widget(self) -> Widget? {
self.as_center_box().get_end_widget()
}
///|
impl ICenterBox with fn get_shrink_center_last(self) -> Bool {
self.as_center_box().get_shrink_center_last()
}
///|
impl ICenterBox with fn get_start_widget(self) -> Widget? {
self.as_center_box().get_start_widget()
}
///|
impl ICenterBox with fn set_baseline_position(self, position) -> Unit {
self.as_center_box().set_baseline_position(position)
}
///|
impl ICenterBox with fn set_center_widget(self, child) -> Unit {
self.as_center_box().set_center_widget(child)
}
///|
impl ICenterBox with fn set_end_widget(self, child) -> Unit {
self.as_center_box().set_end_widget(child)
}
///|
impl ICenterBox with fn set_shrink_center_last(self, shrink_center_last) -> Unit {
self.as_center_box().set_shrink_center_last(shrink_center_last)
}
///|
impl ICenterBox with fn set_start_widget(self, child) -> Unit {
self.as_center_box().set_start_widget(child)
}
///|
pub fn CenterBox::as_widget(self : CenterBox) -> Widget = "%identity"
///|
pub impl IWidget for CenterBox with fn as_widget(self) {
self.as_widget()
}
///|
pub fn CenterBox::as_gobject_object(self : CenterBox) -> @gobject.Object = "%identity"
///|
pub impl @gobject.IObject for CenterBox with fn as_object(self) {
self.as_gobject_object()
}
///|
pub fn CenterBox::as_orientable(self : CenterBox) -> Orientable = "%identity"
///|
pub impl IOrientable for CenterBox with fn as_orientable(self) {
self.as_orientable()
}