### Class

# WPEPlatform Toplevel

#### Description

    class WPEPlatform.Toplevel : GObject.Object
    {
      WPEToplevelPrivate* priv
    }

No description available.

#### Ancestors

- GObject

#### Instance methods

###### wpe_toplevel_closed

Set `toplevel` as closed if not already closed.

###### wpe_toplevel_foreach_view

Call `func` for each `WPEView` of `toplevel`.

###### wpe_toplevel_fullscreen

Request that the `toplevel` goes into a fullscreen state.

###### wpe_toplevel_get_display

Get the `WPEDisplay` of `toplevel`.

###### wpe_toplevel_get_max_views

Get the maximum number of `WPEView` that `toplevel` can contain.

###### wpe_toplevel_get_n_views

Get the number of `WPEView` contained by `toplevel`.

###### wpe_toplevel_get_preferred_dma_buf_formats

Get the list of preferred DMA-BUF buffer formats for `toplevel`.

###### wpe_toplevel_get_scale

Get the `toplevel` scale.

###### wpe_toplevel_get_screen

Get current `WPEScreen` of `toplevel`.

###### wpe_toplevel_get_size

Get the `vtoplevel` size in logical coordinates.

###### wpe_toplevel_get_state

Get the current state of `toplevel`.

###### wpe_toplevel_maximize

Request that the `toplevel` is maximized. If the toplevel is already maximized this function does nothing.

###### wpe_toplevel_minimize

Request that the `toplevel` is minimized.

###### wpe_toplevel_preferred_dma_buf_formats_changed

Notify that `toplevel` preferred DMA-BUF formats have changed.

###### wpe_toplevel_resize

Request that the `toplevel` is resized at `width` x `height`.

###### wpe_toplevel_resized

Update `toplevel` size.

###### wpe_toplevel_scale_changed

Update the `toplevel` scale.

###### wpe_toplevel_screen_changed

Notify that `toplevel` screen has changed.

###### wpe_toplevel_set_title

Set the `toplevel` title.

###### wpe_toplevel_state_changed

Update the current state of `toplevel`.

###### wpe_toplevel_unfullscreen

Request that the `toplevel` leaves a fullscreen state.

###### wpe_toplevel_unmaximize

Request that the `toplevel` is unmaximized. If the toplevel is not maximized this function does nothing.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### WPEPlatform.Toplevel:display

The `WPEDisplay` of the toplevel.

#### Signals

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct WPEPlatformToplevelClass {
      GObjectClass parent_class;
      void (* set_title) (
        WPEToplevel* toplevel,
        const char* title
      );
      guint (* get_max_views) (
        WPEToplevel* toplevel
      );
      WPEScreen* (* get_screen) (
        WPEToplevel* toplevel
      );
      gboolean (* resize) (
        WPEToplevel* toplevel,
        int width,
        int height
      );
      gboolean (* set_fullscreen) (
        WPEToplevel* toplevel,
        gboolean fullscreen
      );
      gboolean (* set_maximized) (
        WPEToplevel* toplevel,
        gboolean maximized
      );
      gboolean (* set_minimized) (
        WPEToplevel* toplevel
      );
      WPEBufferDMABufFormats* (* get_preferred_dma_buf_formats) (
        WPEToplevel* toplevel
      );
      gpointer padding;

    }

No description available.

###### Class members

`parent_class: GObjectClass`

  No description available.

`set_title: void (* set_title) ( WPEToplevel* toplevel, const char* title )`

  No description available.

`get_max_views: guint (* get_max_views) ( WPEToplevel* toplevel )`

  No description available.

`get_screen: WPEScreen* (* get_screen) ( WPEToplevel* toplevel )`

  No description available.

`resize: gboolean (* resize) ( WPEToplevel* toplevel, int width, int height )`

  No description available.

`set_fullscreen: gboolean (* set_fullscreen) ( WPEToplevel* toplevel, gboolean fullscreen )`

  No description available.

`set_maximized: gboolean (* set_maximized) ( WPEToplevel* toplevel, gboolean maximized )`

  No description available.

`set_minimized: gboolean (* set_minimized) ( WPEToplevel* toplevel )`

  No description available.

`get_preferred_dma_buf_formats: WPEBufferDMABufFormats* (* get_preferred_dma_buf_formats) ( WPEToplevel* toplevel )`

  No description available.

`padding: gpointer`

  No description available.

#### Virtual methods

###### WPEPlatform.ToplevelClass.get_max_views

Get the maximum number of `WPEView` that `toplevel` can contain.

###### WPEPlatform.ToplevelClass.get_preferred_dma_buf_formats

Get the list of preferred DMA-BUF buffer formats for `toplevel`.

###### WPEPlatform.ToplevelClass.get_screen

Get current `WPEScreen` of `toplevel`.

###### WPEPlatform.ToplevelClass.resize

Request that the `toplevel` is resized at `width` x `height`.

###### WPEPlatform.ToplevelClass.set_fullscreen

No description available.

###### WPEPlatform.ToplevelClass.set_maximized

No description available.

###### WPEPlatform.ToplevelClass.set_minimized

No description available.

###### WPEPlatform.ToplevelClass.set_title

Set the `toplevel` title.