### ----------------------------------------------------
### -- Gnome::Gtk3
### -- Licenses: Artistic-2.0
### -- Authors: Marcel Timmerman
### -- File: lib/Gnome/Gtk3/Widget.rakumod
### ----------------------------------------------------
### -- Chunk 3 of 8
-direction

Obtains the current default reading direction. See C<set-default-direction()>.

Returns: the current default direction.

  method get-default-direction ( --> GtkTextDirection )

=end pod

method get-default-direction ( --> GtkTextDirection ) {
  GtkTextDirection(gtk_widget_get_default_direction())
}

sub gtk_widget_get_default_direction ( --> GEnum )
  is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:0:get-device-enabled:
=begin pod
=head2 get-device-enabled

Returns whether I<device> can interact with I<widget> and its children. See C<set-device-enabled()>.

Returns: C<True> is I<device> is enabled for I<widget>

  method get-device-enabled ( N-GObject $device --> Bool )

=item N-GObject $device; a B<Gnome::Gdk3::Device>

=end pod

method get-device-enabled ( $device is copy --> Bool ) {
  $device .= _get-native-object-no-reffing unless $device ~~ N-GObject;
  gtk_widget_get_device_enabled( self._f('GtkWidget'), $device).Bool
}

sub gtk_widget_get_device_enabled (
  N-GObject $widget, N-GObject $device --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:0:get-device-events:
=begin pod
=head2 get-device-events

Returns the events mask for the widget corresponding to a specific device. These are the events that the widget will receive when I<device> operates on it. Flags in this mask are from C<GdkEventMask> in B<Gnome::Gdk3::Types>.

Returns: device event mask for I<widget>

  method get-device-events ( N-GObject $device --> Int )

=item N-GObject $device; a B<Gnome::Gdk3::Device>

=end pod

method get-device-events ( $device is copy --> Int ) {
  $device .= _get-native-object-no-reffing unless $device ~~ N-GObject;
  gtk_widget_get_device_events( self._f('GtkWidget'), $device)
}

sub gtk_widget_get_device_events (
  N-GObject $widget, N-GObject $device --> GFlag
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-direction:
=begin pod
=head2 get-direction

Gets the reading direction for a particular widget. See C<set-direction()>.

Returns: the reading direction for the widget.

  method get-direction ( --> GtkTextDirection )

=end pod

method get-direction ( --> GtkTextDirection ) {
  GtkTextDirection(gtk_widget_get_direction(self._f('GtkWidget')))
}

sub gtk_widget_get_direction (
  N-GObject $widget --> GEnum
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-display:
#TM:1:get-display-rk:
=begin pod
=head2 get-display, get-display-rk

Get the B<Gnome::Gdk3::Display> for the toplevel window associated with this widget. This function can only be called after the widget has been added to a widget hierarchy with a B<Gnome::Gtk3::Window> at the top.

In general, you should only create display specific resources when a widget has been realized, and you should free those resources when the widget is unrealized.

Returns: the B<Gnome::Gdk3::Display> for the toplevel for this widget.

  method get-display-rk ( --> Gnome::Gdk3::Display )
  method get-display ( --> N-GObject )

=end pod

method get-display-rk ( --> Gnome::Gdk3::Display ) {
  Gnome::Gdk3::Display.new(
    :native-object(gtk_widget_get_display(self._f('GtkWidget')))
  )
}

method get-display ( --> N-GObject ) {
  gtk_widget_get_display(self._f('GtkWidget'))
}

sub gtk_widget_get_display (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-events:
=begin pod
=head2 get-events

Returns the event mask (see GdkEventMask) for the widget. These are the events that the widget will receive.

Note: Internally, the widget event mask will be the logical OR of the event mask set through C<set-events()> or C<add-events()>, and the event mask necessary to cater for every B<Gnome::Gtk3::EventController> created for the widget.

Returns: event mask for I<widget>

  method get-events ( --> Int )

=end pod

method get-events ( --> Int ) {
  gtk_widget_get_events(self._f('GtkWidget'))
}

sub gtk_widget_get_events (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-focus-on-click:
=begin pod
=head2 get-focus-on-click

Returns whether the widget should grab focus when it is clicked with the mouse. See C<set-focus-on-click()>.

Returns: C<True> if the widget should grab focus when it is clicked with the mouse.

  method get-focus-on-click ( --> Bool )

=end pod

method get-focus-on-click ( --> Bool ) {
  gtk_widget_get_focus_on_click(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_focus_on_click (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#`{{
#-------------------------------------------------------------------------------
#TM:0:get-font-map:
=begin pod
=head2 get-font-map

Gets the font map that has been set with C<set-font-map()>.

Returns: A B<PangoFontMap>, or C<undefined>

  method get-font-map ( --> N-GObject )

=end pod

method get-font-map ( --> N-GObject ) {
  gtk_widget_get_font_map(self._f('GtkWidget'))
}

sub gtk_widget_get_font_map (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }
}}

#-------------------------------------------------------------------------------
#TM:0:get-font-options:
=begin pod
=head2 get-font-options

Returns the B<cairo-font-options-t> used for Pango rendering. When not set, the defaults font options for the B<Gnome::Gdk3::Screen> will be used.

Returns: the B<cairo-font-options-t> or C<undefined> if not set

  method get-font-options ( --> cairo_font_options_t )

=end pod

method get-font-options ( --> cairo_font_options_t ) {
  gtk_widget_get_font_options(self._f('GtkWidget'))
}

sub gtk_widget_get_font_options (
  N-GObject $widget --> cairo_font_options_t
) is native(&gtk-lib)
  { * }

#`{{
#-------------------------------------------------------------------------------
# TM:0:get-frame-clock:
=begin pod
=head2 get-frame-clock

Obtains the frame clock for a widget. The frame clock is a global “ticker” that can be used to drive animations and repaints. The most common reason to get the frame clock is to call C<gdk-frame-clock-get-frame-time()>, in order to get a time to use for animating. For example you might record the start of the animation with an initial value from C<gdk-frame-clock-get-frame-time()>, and then update the animation by calling C<gdk-frame-clock-get-frame-time()> again during each repaint.

C<gdk-frame-clock-request-phase()> will result in a new frame on the clock, but won’t necessarily repaint any widgets. To repaint a widget, you have to use C<queue-draw()> which invalidates the widget (thus scheduling it to receive a draw on the next frame). C<queue-draw()> will also end up requesting a frame on the appropriate frame clock.

A widget’s frame clock will not change while the widget is mapped. Reparenting a widget (which implies a temporary unmap) can change the widget’s frame clock.

Unrealized widgets do not have a frame clock.

Returns: a B<Gnome::Gdk3::FrameClock>, or C<undefined> if widget is unrealized

  method get-frame-clock ( --> N-GObject )

=end pod

method get-frame-clock ( --> N-GObject ) {

  gtk_widget_get_frame_clock(
    self._f('GtkWidget'),
  )
}

sub gtk_widget_get_frame_clock (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }
}}

#-------------------------------------------------------------------------------
#TM:1:get-halign:
=begin pod
=head2 get-halign

Gets the value of the  I<halign> property.

For backwards compatibility reasons this method will never return C<GTK-ALIGN-BASELINE>, but instead it will convert it to C<GTK-ALIGN-FILL>. Baselines are not supported for horizontal alignment.

Returns: the horizontal alignment of I<widget>

  method get-halign ( --> GtkAlign )

=end pod

method get-halign ( --> GtkAlign ) {
  GtkAlign(gtk_widget_get_halign(self._f('GtkWidget')))
}

sub gtk_widget_get_halign (
  N-GObject $widget --> GEnum
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-has-tooltip:
=begin pod
=head2 get-has-tooltip

Returns the current value of the has-tooltip property. See  I<has-tooltip> for more information.

Returns: current value of has-tooltip on I<widget>.

  method get-has-tooltip ( --> Bool )

=end pod

method get-has-tooltip ( --> Bool ) {
  gtk_widget_get_has_tooltip(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_has_tooltip (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-has-window:
=begin pod
=head2 get-has-window

Determines whether I<widget> has a B<Gnome::Gtk3::Window> of its own. See C<set-has-window()>.

Returns: C<True> if I<widget> has a window, C<False> otherwise

  method get-has-window ( --> Bool )

=end pod

method get-has-window ( --> Bool ) {
  gtk_widget_get_has_window(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_has_window (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-hexpand:
=begin pod
=head2 get-hexpand

Gets whether the widget would like any available extra horizontal space. When a user resizes a B<Gnome::Gtk3::Window>, widgets with expand=TRUE generally receive the extra space. For example, a list or scrollable area or document in your window would often be set to expand.

Containers should use C<compute-expand()> rather than this function, to see whether a widget, or any of its children, has the expand flag set. If any child of a widget wants to expand, the parent may ask to expand also.

This function only looks at the widget’s own hexpand flag, rather than computing whether the entire widget tree rooted at this widget wants to expand.

Returns: whether hexpand flag is set

  method get-hexpand ( --> Bool )

=end pod

method get-hexpand ( --> Bool ) {
  gtk_widget_get_hexpand( self._f('GtkWidget')).Bool
}

sub gtk_widget_get_hexpand (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-hexpand-set:
=begin pod
=head2 get-hexpand-set

Gets whether C<set-hexpand()> has been used to explicitly set the expand flag on this widget.

If hexpand is set, then it overrides any computed expand value based on child widgets. If hexpand is not set, then the expand value depends on whether any children of the widget would like to expand.

There are few reasons to use this function, but it’s here for completeness and consistency.

Returns: whether hexpand has been explicitly set

  method get-hexpand-set ( --> Bool )

=end pod

method get-hexpand-set ( --> Bool ) {
  gtk_widget_get_hexpand_set(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_hexpand_set (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-mapped:
=begin pod
=head2 get-mapped

Whether the widget is mapped.

Returns: C<True> if the widget is mapped, C<False> otherwise.

  method get-mapped ( --> Bool )

=end pod

method get-mapped ( --> Bool ) {
  gtk_widget_get_mapped(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_mapped (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-margin-bottom:
=begin pod
=head2 get-margin-bottom

Gets the value of the  I<margin-bottom> property.

Returns: The bottom margin of I<widget>

  method get-margin-bottom ( --> Int )

=end pod

method get-margin-bottom ( --> Int ) {
  gtk_widget_get_margin_bottom(self._f('GtkWidget'))
}

sub gtk_widget_get_margin_bottom (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-margin-end:
=begin pod
=head2 get-margin-end

Gets the value of the  I<margin-end> property.

Returns: The end margin of I<widget>

  method get-margin-end ( --> Int )

=end pod

method get-margin-end ( --> Int ) {
  gtk_widget_get_margin_end(self._f('GtkWidget'))
}

sub gtk_widget_get_margin_end (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-margin-start:
=begin pod
=head2 get-margin-start

Gets the value of the  I<margin-start> property.

Returns: The start margin of I<widget>

  method get-margin-start ( --> Int )

=end pod

method get-margin-start ( --> Int ) {
  gtk_widget_get_margin_start(self._f('GtkWidget'))
}

sub gtk_widget_get_margin_start (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-margin-top:
=begin pod
=head2 get-margin-top

Gets the value of the  I<margin-top> property.

Returns: The top margin of I<widget>

  method get-margin-top ( --> Int )

=end pod

method get-margin-top ( --> Int ) {
  gtk_widget_get_margin_top(self._f('GtkWidget'))
}

sub gtk_widget_get_margin_top (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-modifier-mask:
=begin pod
=head2 get-modifier-mask

Returns the modifier mask the I<widget>’s windowing system backend uses for a particular purpose.

See C<gdk-keymap-get-modifier-mask()>.

Returns: the modifier mask used for I<intent>. The mask bits are GdkModifierType

  method get-modifier-mask ( GdkModifierIntent $intent --> Int )

=item GdkModifierIntent $intent; the use case for the modifier mask

=end pod

method get-modifier-mask ( GdkModifierIntent $intent --> Int ) {
  gtk_widget_get_modifier_mask(self._f('GtkWidget'), $intent)
}

sub gtk_widget_get_modifier_mask (
  N-GObject $widget, GEnum $intent --> GEnum
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-name:
=begin pod
=head2 get-name

Retrieves the name of a widget. See C<set-name()> for the significance of widget names.

Returns: name of the widget. This string is owned by GTK+ and should not be modified or freed

  method get-name ( --> Str )

=end pod

method get-name ( --> Str ) {
  gtk_widget_get_name(self._f('GtkWidget'))
}

sub gtk_widget_get_name (
  N-GObject $widget --> gchar-ptr
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-no-show-all:
=begin pod
=head2 get-no-show-all

Returns the current value of the  I<no-show-all> property, which determines whether calls to C<show-all()> will affect this widget.

Returns: the current value of the “no-show-all” property.

  method get-no-show-all ( --> Bool )

=end pod

method get-no-show-all ( --> Bool ) {
  gtk_widget_get_no_show_all(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_no_show_all (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-opacity:
=begin pod
=head2 get-opacity

Fetches the requested opacity for this widget. See C<set-opacity()>.

Returns: the requested opacity for this widget.

  method get-opacity ( --> Num )

=end pod

method get-opacity ( --> Num ) {
  gtk_widget_get_opacity(self._f('GtkWidget'))
}

sub gtk_widget_get_opacity (
  N-GObject $widget --> gdouble
) is native(&gtk-lib)
  { * }


#-------------------------------------------------------------------------------
#TM:1:get-pango-context:
=begin pod
=head2 get-pango-context

Gets a B<PangoContext> with the appropriate font map, font description, and base direction for this widget. Unlike the context returned by C<create-pango-context()>, this context is owned by the widget (it can be used until the screen for the widget changes or the widget is removed from its toplevel), and will be updated to match any changes to the widget’s attributes. This can be tracked by using the  I<screen-changed> signal on the widget.

Returns: the native object of B<Gnome::Pango::Context> for the widget.

  method get-pango-context ( --> N-GObject )

=end pod

method get-pango-context ( --> N-GObject ) {
  gtk_widget_get_pango_context(self._f('GtkWidget'))
}

sub gtk_widget_get_pango_context (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }


#-------------------------------------------------------------------------------
#TM:1:get-parent:
#TM:1:get-parent-rk:
=begin pod
=head2 get-parent, get-parent-rk

Returns the parent object of this I<widget> or C<undefined> in the case of the native object or invalid in the case of a raku object.

  method get-parent ( --> N-GObject )
  method get-parent-rk ( :$child-type? --> Gnome::GObject::Object )

=item $child-type: This is an optional argument. You can specify a real type or a type as a string. In the latter case the type must be defined in a module which can be found by the Raku require call.

=end pod

method get-parent-rk ( *%options --> Gnome::GObject::Object ) {
  my $no = gtk_widget_get_parent(self._f('GtkWidget'));
  if ?$no {
    self._wrap-native-type-from-no( $no, |%options)
  }

  else {
    # create an invalid object
    self.new(:native-object($no))
  }
}

method get-parent ( --> N-GObject ) {
  gtk_widget_get_parent(self._f('GtkWidget'))
}

sub gtk_widget_get_parent (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-parent-window:
#TM:1:get-parent-window-rk:
=begin pod
=head2 get-parent-window, get-parent-window-rk

Gets I<widget>’s parent window, or C<undefined> if it does not have one.

Returns: the parent window of I<widget>, or C<undefined> if it does not have a parent window.

  method get-parent-window ( --> N-GObject )
  method get-parent-window-rk ( :$child-type? --> Gnome::GObject::Object )

=item $child-type: This is an optional argument. You can specify a real type or a type as a string. In the latter case the type must be defined in a module which can be found by the Raku require call.

=end pod

method get-parent-window-rk ( *%options --> Gnome::GObject::Object ) {
  my $no = gtk_widget_get_parent_window(self._f('GtkWidget'));
  if ?$no {
    self._wrap-native-type-from-no( $no, |%options)
  }

  else {
    # create an invalid object
    self.new(:native-object($no))
  }
}

method get-parent-window ( --> N-GObject ) {
  gtk_widget_get_parent_window(self._f('GtkWidget'))
}

sub gtk_widget_get_parent_window (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-path:
#TM:1:get-path-rk:
=begin pod
=head2 get-path, get-path-rk

Returns the B<Gnome::Gtk3::WidgetPath> representing I<widget>, if the widget is not connected to a toplevel widget, a partial path will be created.

Returns: The B<Gnome::Gtk3::WidgetPath> representing I<widget>

  method get-path ( --> N-GObject )
  method get-path-rk ( --> Gnome::Gtk3::WidgetPath )

=end pod

method get-path-rk ( --> Gnome::Gtk3::WidgetPath ) {
  # cannot wrap it because it isn't a N-GObject. It is Boxed!
  Gnome::Gtk3::WidgetPath.new(
    :native-object(gtk_widget_get_path(self._f('GtkWidget')))
  )
}

method get-path ( --> N-GObject ) {
  gtk_widget_get_path(self._f('GtkWidget'))
}

sub gtk_widget_get_path (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-height:
=begin pod
=head2 get-preferred-height

Retrieves a widget’s initial minimum and natural height.

This call is specific to width-for-height requests.

The returned request will be modified by the GtkWidgetClass::adjust_size_request virtual method and by any GtkSizeGroups that have been applied. That is, the returned request is the one that should be used for layout, not necessarily the one returned by the widget itself.

  method get-preferred-height ( --> List )

Returns a List with
=item Int minimum_height;
=item Int natural_height;

=end pod

method get-preferred-height ( --> List ) {
  my int $minimum;
  my int $natural;

  gtk_widget_get_preferred_height( self._f('GtkWidget'), $minimum, $natural);
  ( $minimum, $natural)
}

sub gtk_widget_get_preferred_height (
  N-GObject $widget, gint $minimum_height is rw, gint $natural_height is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-height-and-baseline-for-width:
=begin pod
=head2 get-preferred-height-and-baseline-for-width

Retrieves a widget’s minimum and natural height and the corresponding baselines if it would be given the specified width , or the default height if width is -1. The baselines may be -1 which means that no baseline is requested for this widget.

The returned request will be modified by the GtkWidgetClass::adjust_size_request and GtkWidgetClass::adjust_baseline_request virtual methods and by any GtkSizeGroups that have been applied. That is, the returned request is the one that should be used for layout, not necessarily the one returned by the widget itself.

  method get-preferred-height-and-baseline-for-width (
    Int $width --> List
  )

=item Int $width;

Returns a List containing;
=item Int minimum_height;
=item Int natural_height;
=item Int minimum_baseline;
=item Int natural_baseline;

=end pod

method get-preferred-height-and-baseline-for-width ( Int $width --> List ) {
  my gint $minimum_height;
  my gint $natural_height;
  my gint $minimum_baseline;
  my gint $natural_baseline;

  gtk_widget_get_preferred_height_and_baseline_for_width(
    self._f('GtkWidget'), $width, $minimum_height, $natural_height, $minimum_baseline, $natural_baseline
  );

  ( $minimum_height, $natural_height, $minimum_baseline, $natural_baseline)
}

sub gtk_widget_get_preferred_height_and_baseline_for_width (
  N-GObject $widget, gint $width, gint $minimum_height is rw,
  gint $natural_height is rw, gint $minimum_baseline is rw,
  gint $natural_baseline is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-height-for-width:
=begin pod
=head2 get-preferred-height-for-width

Retrieves a widget’s minimum and natural height if it would be given the specified width .

=comment The returned request will be modified by the GtkWidgetClass::adjust_size_request virtual method and by any GtkSizeGroups that have been applied. That is, the returned request is the one that should be used for layout, not necessarily the one returned by the widget itself.

  method get-preferred-height-for-width ( Int $width --> List )

=item Int $width;

Returning a List with
=item Int minimum_height;
=item Int natural_height;

=end pod

method get-preferred-height-for-width ( Int $width --> List ) {
  my gint $minimum_height;
  my gint $natural_height;

  gtk_widget_get_preferred_height_for_width(
    self._f('GtkWidget'), $width, $minimum_height, $natural_height
  );

  ( $minimum_height, $natural_height)
}

sub gtk_widget_get_preferred_height_for_width (
  N-GObject $widget, gint $width, gint $minimum_height is rw, gint $natural_height is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-size:
=begin pod
=head2 get-preferred-size

Retrieves the minimum and natural size of a widget, taking into account the widget’s preference for height-for-width management.

This is used to retrieve a suitable size by container widgets which do not impose any restrictions on the child placement. It can be used to deduce toplevel window and menu sizes as well as child widgets in free-form containers such as GtkLayout.

Handle with care. Note that the natural height of a height-for-width widget will generally be a smaller size than the minimum height, since the required height for the natural width is generally smaller than the required height for the minimum width.

Use gtk_widget_get_preferred_height_and_baseline_for_width() if you want to support baseline alignment.

  method get-preferred-size ( --> List )

The returned list holds
=item N-GtkRequisition $minimum_size;
=item N-GtkRequisition $natural_size;

=end pod

method get-preferred-size ( --> List ) {
  my N-GtkRequisition $minimum .= new;
  my N-GtkRequisition $natural .= new;

  gtk_widget_get_preferred_size( self._f('GtkWidget'), $minimum, $natural);
  ( $minimum, $natural)
}

sub gtk_widget_get_preferred_size (
  N-GObject $widget, N-GtkRequisition $minimum_size, N-GtkRequisition $natural_size
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-width:
=begin pod
=head2 get-preferred-width

Retrieves a widget’s initial minimum and natural width.

This call is specific to height-for-width requests.

The returned request will be modified by the GtkWidgetClass::adjust_size_request virtual method and by any GtkSizeGroups that have been applied. That is, the returned request is the one that should be used for layout, not necessarily the one returned by the widget itself.

  method get-preferred-width ( --> List )

Returned List holds;
=item Int minimum_width;
=item Int natural_width;

=end pod

method get-preferred-width ( --> List ) {
  my gint $minimum_width;
  my gint $natural_width;

  gtk_widget_get_preferred_width(
    self._f('GtkWidget'), $minimum_width, $natural_width
  );

  ( $minimum_width, $natural_width)
}

sub gtk_widget_get_preferred_width (
  N-GObject $widget, gint $minimum_width is rw, gint $natural_width is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-preferred-width-for-height:
=begin pod
=head2 get-preferred-width-for-height

Retrieves a widget’s minimum and natural width if it would be given the specified height .

The returned request will be modified by the GtkWidgetClass::adjust_size_request virtual method and by any GtkSizeGroups that have been applied. That is, the returned request is the one that should be used for layout, not necessarily the one returned by the widget itself.

  method get-preferred-width-for-height ( Int $height --> List )

=item Int $height;

The returned List holds
=item Int minimum_width;
=item Int natural_width;

=end pod

method get-preferred-width-for-height ( Int $height--> List ) {
  my gint $minimum_width;
  my gint $natural_width;

  gtk_widget_get_preferred_width_for_height(
    self._f('GtkWidget'), $height, $minimum_width, $natural_width
  );

  ( $minimum_width, $natural_width)
}

sub gtk_widget_get_preferred_width_for_height (
  N-GObject $widget, gint $height, gint $minimum_width is rw, gint $natural_width is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-realized:
=begin pod
=head2 get-realized

Determines whether I<widget> is realized.

Returns: C<True> if I<widget> is realized, C<False> otherwise

  method get-realized ( --> Bool )

=end pod

method get-realized ( --> Bool ) {
  gtk_widget_get_realized(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_realized (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-receives-default:
=begin pod
=head2 get-receives-default

Determines whether I<widget> is always treated as the default widget within its toplevel when it has the focus, even if another widget is the default.

See C<set-receives-default()>.

Returns: C<True> if I<widget> acts as the default widget when focused, C<False> otherwise

  method get-receives-default ( --> Bool )

=end pod

method get-receives-default ( --> Bool ) {
  gtk_widget_get_receives_default(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_receives_default (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-request-mode:
=begin pod
=head2 get-request-mode

Gets whether the widget prefers a height-for-width layout or a width-for-height layout.

GtkBin widgets generally propagate the preference of their child, container widgets need to request something either in context of their children or in context of their allocation capabilities.

  method get-request-mode ( --> GtkSizeRequestMode )

=end pod

method get-request-mode ( --> GtkSizeRequestMode ) {
  GtkSizeRequestMode(gtk_widget_get_request_mode(self._f('GtkWidget')))
}

sub gtk_widget_get_request_mode (
  N-GObject $widget --> GEnum
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-scale-factor:
=begin pod
=head2 get-scale-factor

Retrieves the internal scale factor that maps from window coordinates to the actual device pixels. On traditional systems this is 1, on high density outputs, it can be a higher value (typically 2).

See C<gdk-window-get-scale-factor()>.

Returns: the scale factor for I<widget>

  method get-scale-factor ( --> Int )

=end pod

method get-scale-factor ( --> Int ) {
  gtk_widget_get_scale_factor(self._f('GtkWidget'))
}

sub gtk_widget_get_scale_factor (
  N-GObject $widget --> gint
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-screen:
#TM:1:get-screen-rk:
=begin pod
=head2 get-screen, get-screen-rk

Get the B<Gnome::Gdk3::Screen> from the toplevel window associated with this widget. This function can only be called after the widget has been added to a widget hierarchy with a B<Gnome::Gdk3::Window> at the top.

In general, you should only create screen specific resources when a widget has been realized, and you should free those resources when the widget is unrealized.

Returns: the B<Gnome::Gdk3::Screen> for the toplevel for this widget.

  method get-screen-rk ( --> Gnome::Gdk3::Screen )
  method get-screen ( --> N-GObject )

=end pod

method get-screen-rk ( --> Gnome::Gdk3::Screen ) {
  Gnome::Gdk3::Screen.new(
    :native-object(gtk_widget_get_screen(self._f('GtkWidget')))
  )
}

method get-screen ( --> N-GObject ) {
  gtk_widget_get_screen(self._f('GtkWidget'))
}

sub gtk_widget_get_screen (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-sensitive:
=begin pod
=head2 get-sensitive

Returns the widget’s sensitivity (in the sense of returning the value that has been set using C<set-sensitive()>).

The effective sensitivity of a widget is however determined by both its own and its parent widget’s sensitivity. See C<is-sensitive()>.

Returns: C<True> if the widget is sensitive

  method get-sensitive ( --> Bool )

=end pod

method get-sensitive ( --> Bool ) {
  gtk_widget_get_sensitive(self._f('GtkWidget')).Bool
}

sub gtk_widget_get_sensitive (
  N-GObject $widget --> gboolean
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#`{{
#TM:0:get-settings:
=begin pod
=head2 get-settings

Gets the settings object holding the settings used for this widget.

Note that this function can only be called when the B<Gnome::Gtk3::Widget> is attached to a toplevel, since the settings object is specific to a particular B<Gnome::Gdk3::Screen>.

Returns: the relevant B<Gnome::Gtk3::Settings> object

  method get-settings ( --> N-GObject )

=end pod

method get-settings ( --> N-GObject ) {

  gtk_widget_get_settings(
    self._f('GtkWidget'),
  )
}

sub gtk_widget_get_settings (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }
}}

#-------------------------------------------------------------------------------
#TM:1:get-size-request:
=begin pod
=head2 get-size-request

Gets the size request that was explicitly set for the widget using C<set-size-request()>. A value of -1 stored in I<width> or I<height> indicates that that dimension has not been set explicitly and the natural requisition of the widget will be used instead. See C<set-size-request()>. To get the size a widget will actually request, call C<get-preferred-size()> instead of this function.

  method get-size-request ( --> List )

Returned List holds;
=item Int width; return location for width, or C<undefined>
=item Int height; return location for height, or C<undefined>

=end pod

method get-size-request ( --> List ) {
  my gint $width;
  my gint $height;
  gtk_widget_get_size_request(self._f('GtkWidget'), $width, $height);
  ( $width, $height)
}

sub gtk_widget_get_size_request (
  N-GObject $widget, gint $width is rw, gint $height is rw
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-state-flags:
=begin pod
=head2 get-state-flags

Returns the widget state as a flag set. It is worth mentioning that the effective C<GTK-STATE-FLAG-INSENSITIVE> state will be returned, that is, also based on parent insensitivity, even if I<widget> itself is sensitive.

Also note that if you are looking for a way to obtain the B<Gnome::Gtk3::StateFlags> to pass to a B<Gnome::Gtk3::StyleContext> method, you should look at C<Gnome::Gtk3::StyleContext.get-state()>.

Returns: The state flags for widget. Flags are defined by GtkStateFlags.

  method get-state-flags ( --> UInt )

=end pod

method get-state-flags ( --> UInt ) {
  gtk_widget_get_state_flags(self._f('GtkWidget'))
}

sub gtk_widget_get_state_flags (
  N-GObject $widget --> GFlag
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-style-context:
#TM:1:get-style-context-rk:
=begin pod
=head2 get-style-context, get-style-context-rk

Returns the style context associated to I<widget>. The returned object is guaranteed to be the same for the lifetime of I<widget>.

Returns: a B<Gnome::Gtk3::StyleContext>. This memory is owned by I<widget> and must not be freed.

  method get-style-context ( --> N-GObject )
  method get-style-context-rk ( --> Gnome::Gtk3::StyleContext )

=end pod

method get-style-context-rk ( --> Gnome::GObject::Object ) {
  self._wrap-native-type-from-no(
    gtk_widget_get_style_context(self._f('GtkWidget'))
  )
}

method get-style-context ( --> N-GObject ) {
  gtk_widget_get_style_context(self._f('GtkWidget'))
}

sub gtk_widget_get_style_context (
  N-GObject $widget --> N-GObject
) is native(&gtk-lib)
  { * }

#-------------------------------------------------------------------------------
#TM:1:get-support-multidevice:
=begin pod
=head2 get-support-multidevice

Returns C<True> if I<widget> is multiple pointer aware. See C<set-support-multidevice()> for more information.

Returns: C<True> if I<widget> is multidevice aware.

  method get-support-multidevice ( --> Bool )

=end pod

method