org.gnome.gtk

## Class Requisition

- Object
- - org.freedesktop.bindings.Pointer
  - - org.gnome.glib.Boxed
    - - org.gnome.gtk.Requisition

-     public final class Requisition
      extends Boxed

  The size that will be (is being) requested by a Widget. You get the Requisition object for a given Widget by calling that its `getRequisition()` method.

  As a general principle across GTK programming, we encourage people to leave Widgets alone to work out their own needs. You will not be able to forecast the impact of a user's fonts, accessibility settings, and theme engine, not to mention the actual implementation of the Containers you are packing your Widget into. The great part is that you don't need to; the GNOME libraries are really good at Doing The Right Thing (tm) and you will do well by them.

  When an occasion does arise where you need to force one or both dimensions, you can either:

  - directly influence the size of an individual Widget using `setSizeRequest()`;
  - use a `SizeGroup` to influence a set of related Widgets to have a dimension in common; or
  - if all you're trying to do is add padding, call Container's `setBorderWidth()`.

  GTK's box packing model works on a size-request/size-allocation process. Each Widget is asked by it's parent Container how much space it wants on the screen, in pixels. These requests are aggregated and in turn represented up the tree until the top-level Window is reached. The Window then negotiates with the window manager and with the X server, with the result being that the Window is allocated. The Containers start divvying up the allocation they were given amongst their children according to whatever algorithms and settings are in place. Eventually your Widget will be told how much space it has been given in it's `Allocation` object, and it will have to then carry on accordingly. The important point to note here is that requests are just that; a Widget must be able to cope with any size down to `1x1`. Ideally it will degrade gracefully, although that's not always easy.

  Since:
    4.0.6
  Author:
    Andrew Cowie

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getHeight()` The height that has been requested.
    `int` | `getWidth()` The width that has been requested.
    `String` | `toString()`

    - ### Methods inherited from class Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Method Detail

    - #### getHeight

          public int getHeight()

      The height that has been requested.

    - #### getWidth

          public int getWidth()

      The width that has been requested.

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `org.freedesktop.bindings.Pointer`