ToplevelImpl

data class ToplevelImpl(val gdkToplevelPointer: <Error class: unknown class><<Error class: unknown class>>) : Surface, Toplevel

The ToplevelImpl type represents a native instance of the Toplevel interface.

Constructors

Link copied to clipboard
constructor(gdkToplevelPointer: <Error class: unknown class><<Error class: unknown class>>)

Creates a new instance of Toplevel for the provided CPointer.

Properties

Link copied to clipboard
open var cursor: Cursor?

The mouse pointer for the GdkSurface.

Link copied to clipboard
open val display: Display

The GdkDisplay connection of the surface.

Link copied to clipboard

The GdkFrameClock of the surface.

Link copied to clipboard
val gdkSurfacePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open override val gdkToplevelPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open val height: <Error class: unknown class>

The height of the surface, in pixels.

Link copied to clipboard
open val mapped: Boolean

Whether the surface is mapped.

Link copied to clipboard
open val scale: <Error class: unknown class>

The scale of the surface.

Link copied to clipboard
open val scaleFactor: <Error class: unknown class>

The scale factor of the surface.

Link copied to clipboard

The state of the toplevel.

Link copied to clipboard
open val width: <Error class: unknown class>

The width of the surface in pixels.

Functions

Link copied to clipboard
open fun beep()

Emits a short beep associated to @surface.

Link copied to clipboard
open fun beginMove(device: Device, button: <Error class: unknown class>, x: <Error class: unknown class>, y: <Error class: unknown class>, timestamp: <Error class: unknown class>)

Begins an interactive move operation.

Link copied to clipboard
open fun beginResize(edge: SurfaceEdge, device: Device? = null, button: <Error class: unknown class>, x: <Error class: unknown class>, y: <Error class: unknown class>, timestamp: <Error class: unknown class>)

Begins an interactive resize operation.

Link copied to clipboard

Creates a new GdkCairoContext for rendering on @surface.

Link copied to clipboard
open fun createGlContext(): <Error class: unknown class><GlContext>

Creates a new GdkGLContext for the GdkSurface.

Link copied to clipboard
open fun createSimilarSurface(content: <Error class: unknown class>, width: <Error class: unknown class>, height: <Error class: unknown class>): <Error class: unknown class>

Create a new Cairo surface that is as compatible as possible with the given @surface.

Link copied to clipboard
open fun createVulkanContext(): <Error class: unknown class><VulkanContext>

Sets an error and returns null.

Link copied to clipboard
open fun destroy()

Destroys the window system resources associated with @surface and decrements @surface's reference count.

Link copied to clipboard

Emits the "enter-monitor" signal. See onEnterMonitor.

Link copied to clipboard
fun emitLayout(width: <Error class: unknown class>, height: <Error class: unknown class>)

Emits the "layout" signal. See onLayout.

Link copied to clipboard

Emits the "leave-monitor" signal. See onLeaveMonitor.

Link copied to clipboard
open fun focus(timestamp: <Error class: unknown class>)

Sets keyboard focus to @surface.

Link copied to clipboard
open fun getDeviceCursor(device: Device): Cursor?

Retrieves a GdkCursor pointer for the @device currently set on the specified GdkSurface.

Link copied to clipboard

Gets the bitwise or of the currently active surface state flags, from the GdkToplevelState enumeration.

Link copied to clipboard
open fun hide()

Hide the surface.

Link copied to clipboard
open fun inhibitSystemShortcuts(event: Event? = null)

Requests that the @toplevel inhibit the system shortcuts.

Link copied to clipboard
open fun isDestroyed(): Boolean

Check to see if a surface is destroyed.

Link copied to clipboard
open fun lower(): Boolean

Asks to lower the @toplevel below other windows.

Link copied to clipboard
open fun minimize(): Boolean

Asks to minimize the @toplevel.

Link copied to clipboard
open fun onComputeSize(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (size: ToplevelSize) -> Unit): <Error class: unknown class>

Emitted when the size for the surface needs to be computed, when it is present.

Link copied to clipboard
fun onEnterMonitor(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (monitor: Monitor) -> Unit): <Error class: unknown class>

Emitted when @surface starts being present on the monitor.

Link copied to clipboard
fun onEvent(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (event: Event) -> Boolean): <Error class: unknown class>

Emitted when GDK receives an input event for @surface.

Link copied to clipboard
fun onLayout(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (<Error class: unknown class>, <Error class: unknown class>) -> Unit): <Error class: unknown class>

Emitted when the size of @surface is changed, or when relayout should be performed.

Link copied to clipboard
fun onLeaveMonitor(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (monitor: Monitor) -> Unit): <Error class: unknown class>

Emitted when @surface stops being present on the monitor.

Link copied to clipboard
fun onRender(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (<Error class: unknown class>) -> Boolean): <Error class: unknown class>

Emitted when part of the surface needs to be redrawn.

Link copied to clipboard
open fun present(layout: ToplevelLayout)

Present @toplevel after having processed the GdkToplevelLayout rules.

Link copied to clipboard
open fun queueRender()

Forces a signal@Gdk.Surface::render signal emission for @surface to be scheduled.

Link copied to clipboard
open fun requestLayout()

Request a layout phase from the surface's frame clock.

Link copied to clipboard

Restore default system keyboard shortcuts which were previously inhibited.

Link copied to clipboard
open fun setDecorated(decorated: Boolean)

Sets the toplevel to be decorated.

Link copied to clipboard
open fun setDeletable(deletable: Boolean)

Sets the toplevel to be deletable.

Link copied to clipboard
open fun setDeviceCursor(device: Device, cursor: Cursor)

Sets a specific GdkCursor for a given device when it gets inside @surface.

Link copied to clipboard
open fun setIconList(surfaces: <Error class: unknown class>)

Sets a list of icons for the surface.

Link copied to clipboard
open fun setInputRegion(region: <Error class: unknown class>)

Apply the region to the surface for the purpose of event handling.

Link copied to clipboard
open fun setModal(modal: Boolean)

Sets the toplevel to be modal.

Link copied to clipboard
open fun setOpaqueRegion(region: <Error class: unknown class>? = null)

Marks a region of the GdkSurface as opaque.

Link copied to clipboard
open fun setStartupId(startupId: String)

Sets the startup notification ID.

Link copied to clipboard
open fun setTitle(title: String)

Sets the title of a toplevel surface.

Link copied to clipboard
open fun setTransientFor(parent: Surface)

Sets a transient-for parent.

Link copied to clipboard
open fun showWindowMenu(event: Event): Boolean

Asks the windowing system to show the window menu.

Link copied to clipboard

Returns whether the desktop environment supports tiled window states.

Link copied to clipboard

Performs a title bar gesture.