@girs/gdk-3.0
Version:
GJS TypeScript type definitions for Gdk-3.0, generated from library version 3.24.50
1,876 lines (1,801 loc) • 514 kB
TypeScript
/**
* Type Definitions for Gjs (https://gjs.guide/)
*
* These type definitions are automatically generated, do not edit them by hand.
* If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
*
* The based EJS template file is used for the generated .d.ts file of each GIR module like Gtk-4.0, GObject-2.0, ...
*/
import '@girs/gjs';
// Module dependencies
import type cairo from 'cairo';
import type GObject from '@girs/gobject-2.0';
import type GLib from '@girs/glib-2.0';
import type Pango from '@girs/pango-1.0';
import type HarfBuzz from '@girs/harfbuzz-0.0';
import type freetype2 from '@girs/freetype2-2.0';
import type Gio from '@girs/gio-2.0';
import type GModule from '@girs/gmodule-2.0';
import type GdkPixbuf from '@girs/gdkpixbuf-2.0';
export namespace Gdk {
/**
* Gdk-3.0
*/
/**
* An enumeration describing the way in which a device
* axis (valuator) maps onto the predefined valuator
* types that GTK+ understands.
*
* Note that the X and Y axes are not really needed; pointer devices
* report their location via the x/y members of events regardless. Whether
* X and Y are present as axes depends on the GDK backend.
*/
/**
* An enumeration describing the way in which a device
* axis (valuator) maps onto the predefined valuator
* types that GTK+ understands.
*
* Note that the X and Y axes are not really needed; pointer devices
* report their location via the x/y members of events regardless. Whether
* X and Y are present as axes depends on the GDK backend.
*/
export namespace AxisUse {
export const $gtype: GObject.GType<AxisUse>;
}
enum AxisUse {
/**
* the axis is ignored.
*/
IGNORE,
/**
* the axis is used as the x axis.
*/
X,
/**
* the axis is used as the y axis.
*/
Y,
/**
* the axis is used for pressure information.
*/
PRESSURE,
/**
* the axis is used for x tilt information.
*/
XTILT,
/**
* the axis is used for y tilt information.
*/
YTILT,
/**
* the axis is used for wheel information.
*/
WHEEL,
/**
* the axis is used for pen/tablet distance information. (Since: 3.22)
*/
DISTANCE,
/**
* the axis is used for pen rotation information. (Since: 3.22)
*/
ROTATION,
/**
* the axis is used for pen slider information. (Since: 3.22)
*/
SLIDER,
/**
* a constant equal to the numerically highest axis value.
*/
LAST,
}
/**
* A set of values describing the possible byte-orders
* for storing pixel values in memory.
*/
/**
* A set of values describing the possible byte-orders
* for storing pixel values in memory.
*/
export namespace ByteOrder {
export const $gtype: GObject.GType<ByteOrder>;
}
enum ByteOrder {
/**
* The values are stored with the least-significant byte
* first. For instance, the 32-bit value 0xffeecc would be stored
* in memory as 0xcc, 0xee, 0xff, 0x00.
*/
LSB_FIRST,
/**
* The values are stored with the most-significant byte
* first. For instance, the 32-bit value 0xffeecc would be stored
* in memory as 0x00, 0xff, 0xee, 0xcc.
*/
MSB_FIRST,
}
/**
* Specifies the crossing mode for #GdkEventCrossing.
*/
/**
* Specifies the crossing mode for #GdkEventCrossing.
*/
export namespace CrossingMode {
export const $gtype: GObject.GType<CrossingMode>;
}
enum CrossingMode {
/**
* crossing because of pointer motion.
*/
NORMAL,
/**
* crossing because a grab is activated.
*/
GRAB,
/**
* crossing because a grab is deactivated.
*/
UNGRAB,
/**
* crossing because a GTK+ grab is activated.
*/
GTK_GRAB,
/**
* crossing because a GTK+ grab is deactivated.
*/
GTK_UNGRAB,
/**
* crossing because a GTK+ widget changed
* state (e.g. sensitivity).
*/
STATE_CHANGED,
/**
* crossing because a touch sequence has begun,
* this event is synthetic as the pointer might have not left the window.
*/
TOUCH_BEGIN,
/**
* crossing because a touch sequence has ended,
* this event is synthetic as the pointer might have not left the window.
*/
TOUCH_END,
/**
* crossing because of a device switch (i.e.
* a mouse taking control of the pointer after a touch device), this event
* is synthetic as the pointer didn’t leave the window.
*/
DEVICE_SWITCH,
}
/**
* Predefined cursors.
*
* Note that these IDs are directly taken from the X cursor font, and many
* of these cursors are either not useful, or are not available on other platforms.
*
* The recommended way to create cursors is to use gdk_cursor_new_from_name().
*/
/**
* Predefined cursors.
*
* Note that these IDs are directly taken from the X cursor font, and many
* of these cursors are either not useful, or are not available on other platforms.
*
* The recommended way to create cursors is to use gdk_cursor_new_from_name().
*/
export namespace CursorType {
export const $gtype: GObject.GType<CursorType>;
}
enum CursorType {
/**
* 
*/
X_CURSOR,
/**
* 
*/
ARROW,
/**
* 
*/
BASED_ARROW_DOWN,
/**
* 
*/
BASED_ARROW_UP,
/**
* 
*/
BOAT,
/**
* 
*/
BOGOSITY,
/**
* 
*/
BOTTOM_LEFT_CORNER,
/**
* 
*/
BOTTOM_RIGHT_CORNER,
/**
* 
*/
BOTTOM_SIDE,
/**
* 
*/
BOTTOM_TEE,
/**
* 
*/
BOX_SPIRAL,
/**
* 
*/
CENTER_PTR,
/**
* 
*/
CIRCLE,
/**
* 
*/
CLOCK,
/**
* 
*/
COFFEE_MUG,
/**
* 
*/
CROSS,
/**
* 
*/
CROSS_REVERSE,
/**
* 
*/
CROSSHAIR,
/**
* 
*/
DIAMOND_CROSS,
/**
* 
*/
DOT,
/**
* 
*/
DOTBOX,
/**
* 
*/
DOUBLE_ARROW,
/**
* 
*/
DRAFT_LARGE,
/**
* 
*/
DRAFT_SMALL,
/**
* 
*/
DRAPED_BOX,
/**
* 
*/
EXCHANGE,
/**
* 
*/
FLEUR,
/**
* 
*/
GOBBLER,
/**
* 
*/
GUMBY,
/**
* 
*/
HAND1,
/**
* 
*/
HAND2,
/**
* 
*/
HEART,
/**
* 
*/
ICON,
/**
* 
*/
IRON_CROSS,
/**
* 
*/
LEFT_PTR,
/**
* 
*/
LEFT_SIDE,
/**
* 
*/
LEFT_TEE,
/**
* 
*/
LEFTBUTTON,
/**
* 
*/
LL_ANGLE,
/**
* 
*/
LR_ANGLE,
/**
* 
*/
MAN,
/**
* 
*/
MIDDLEBUTTON,
/**
* 
*/
MOUSE,
/**
* 
*/
PENCIL,
/**
* 
*/
PIRATE,
/**
* 
*/
PLUS,
/**
* 
*/
QUESTION_ARROW,
/**
* 
*/
RIGHT_PTR,
/**
* 
*/
RIGHT_SIDE,
/**
* 
*/
RIGHT_TEE,
/**
* 
*/
RIGHTBUTTON,
/**
* 
*/
RTL_LOGO,
/**
* 
*/
SAILBOAT,
/**
* 
*/
SB_DOWN_ARROW,
/**
* 
*/
SB_H_DOUBLE_ARROW,
/**
* 
*/
SB_LEFT_ARROW,
/**
* 
*/
SB_RIGHT_ARROW,
/**
* 
*/
SB_UP_ARROW,
/**
* 
*/
SB_V_DOUBLE_ARROW,
/**
* 
*/
SHUTTLE,
/**
* 
*/
SIZING,
/**
* 
*/
SPIDER,
/**
* 
*/
SPRAYCAN,
/**
* 
*/
STAR,
/**
* 
*/
TARGET,
/**
* 
*/
TCROSS,
/**
* 
*/
TOP_LEFT_ARROW,
/**
* 
*/
TOP_LEFT_CORNER,
/**
* 
*/
TOP_RIGHT_CORNER,
/**
* 
*/
TOP_SIDE,
/**
* 
*/
TOP_TEE,
/**
* 
*/
TREK,
/**
* 
*/
UL_ANGLE,
/**
* 
*/
UMBRELLA,
/**
* 
*/
UR_ANGLE,
/**
* 
*/
WATCH,
/**
* 
*/
XTERM,
/**
* last cursor type
*/
LAST_CURSOR,
/**
* Blank cursor. Since 2.16
*/
BLANK_CURSOR,
/**
* type of cursors constructed with
* gdk_cursor_new_from_pixbuf()
*/
CURSOR_IS_PIXMAP,
}
/**
* A pad feature.
*/
/**
* A pad feature.
*/
export namespace DevicePadFeature {
export const $gtype: GObject.GType<DevicePadFeature>;
}
enum DevicePadFeature {
/**
* a button
*/
BUTTON,
/**
* a ring-shaped interactive area
*/
RING,
/**
* a straight interactive area
*/
STRIP,
}
/**
* Indicates the specific type of tool being used being a tablet. Such as an
* airbrush, pencil, etc.
*/
/**
* Indicates the specific type of tool being used being a tablet. Such as an
* airbrush, pencil, etc.
*/
export namespace DeviceToolType {
export const $gtype: GObject.GType<DeviceToolType>;
}
enum DeviceToolType {
/**
* Tool is of an unknown type.
*/
UNKNOWN,
/**
* Tool is a standard tablet stylus.
*/
PEN,
/**
* Tool is standard tablet eraser.
*/
ERASER,
/**
* Tool is a brush stylus.
*/
BRUSH,
/**
* Tool is a pencil stylus.
*/
PENCIL,
/**
* Tool is an airbrush stylus.
*/
AIRBRUSH,
/**
* Tool is a mouse.
*/
MOUSE,
/**
* Tool is a lens cursor.
*/
LENS,
}
/**
* Indicates the device type. See [above][GdkDeviceManager.description]
* for more information about the meaning of these device types.
*/
/**
* Indicates the device type. See [above][GdkDeviceManager.description]
* for more information about the meaning of these device types.
*/
export namespace DeviceType {
export const $gtype: GObject.GType<DeviceType>;
}
enum DeviceType {
/**
* Device is a master (or virtual) device. There will
* be an associated focus indicator on the screen.
*/
MASTER,
/**
* Device is a slave (or physical) device.
*/
SLAVE,
/**
* Device is a physical device, currently not attached to
* any virtual device.
*/
FLOATING,
}
/**
* Used in #GdkDragContext to the reason of a cancelled DND operation.
*/
/**
* Used in #GdkDragContext to the reason of a cancelled DND operation.
*/
export namespace DragCancelReason {
export const $gtype: GObject.GType<DragCancelReason>;
}
enum DragCancelReason {
/**
* There is no suitable drop target.
*/
NO_TARGET,
/**
* Drag cancelled by the user
*/
USER_CANCELLED,
/**
* Unspecified error.
*/
ERROR,
}
/**
* Used in #GdkDragContext to indicate the protocol according to
* which DND is done.
*/
/**
* Used in #GdkDragContext to indicate the protocol according to
* which DND is done.
*/
export namespace DragProtocol {
export const $gtype: GObject.GType<DragProtocol>;
}
enum DragProtocol {
/**
* no protocol.
*/
NONE,
/**
* The Motif DND protocol. No longer supported
*/
MOTIF,
/**
* The Xdnd protocol.
*/
XDND,
/**
* An extension to the Xdnd protocol for
* unclaimed root window drops.
*/
ROOTWIN,
/**
* The simple WM_DROPFILES protocol.
*/
WIN32_DROPFILES,
/**
* The complex OLE2 DND protocol (not implemented).
*/
OLE2,
/**
* Intra-application DND.
*/
LOCAL,
/**
* Wayland DND protocol.
*/
WAYLAND,
}
/**
* Specifies the type of the event.
*
* Do not confuse these events with the signals that GTK+ widgets emit.
* Although many of these events result in corresponding signals being emitted,
* the events are often transformed or filtered along the way.
*
* In some language bindings, the values %GDK_2BUTTON_PRESS and
* %GDK_3BUTTON_PRESS would translate into something syntactically
* invalid (eg `Gdk.EventType.2ButtonPress`, where a
* symbol is not allowed to start with a number). In that case, the
* aliases %GDK_DOUBLE_BUTTON_PRESS and %GDK_TRIPLE_BUTTON_PRESS can
* be used instead.
*/
/**
* Specifies the type of the event.
*
* Do not confuse these events with the signals that GTK+ widgets emit.
* Although many of these events result in corresponding signals being emitted,
* the events are often transformed or filtered along the way.
*
* In some language bindings, the values %GDK_2BUTTON_PRESS and
* %GDK_3BUTTON_PRESS would translate into something syntactically
* invalid (eg `Gdk.EventType.2ButtonPress`, where a
* symbol is not allowed to start with a number). In that case, the
* aliases %GDK_DOUBLE_BUTTON_PRESS and %GDK_TRIPLE_BUTTON_PRESS can
* be used instead.
*/
export namespace EventType {
export const $gtype: GObject.GType<EventType>;
}
enum EventType {
/**
* a special code to indicate a null event.
*/
NOTHING,
/**
* the window manager has requested that the toplevel window be
* hidden or destroyed, usually when the user clicks on a special icon in the
* title bar.
*/
DELETE,
/**
* the window has been destroyed.
*/
DESTROY,
/**
* all or part of the window has become visible and needs to be
* redrawn.
*/
EXPOSE,
/**
* the pointer (usually a mouse) has moved.
*/
MOTION_NOTIFY,
/**
* a mouse button has been pressed.
*/
BUTTON_PRESS,
/**
* a mouse button has been double-clicked (clicked twice
* within a short period of time). Note that each click also generates a
* %GDK_BUTTON_PRESS event.
*/
'2BUTTON_PRESS',
/**
* alias for %GDK_2BUTTON_PRESS, added in 3.6.
*/
DOUBLE_BUTTON_PRESS,
/**
* a mouse button has been clicked 3 times in a short period
* of time. Note that each click also generates a %GDK_BUTTON_PRESS event.
*/
'3BUTTON_PRESS',
/**
* alias for %GDK_3BUTTON_PRESS, added in 3.6.
*/
TRIPLE_BUTTON_PRESS,
/**
* a mouse button has been released.
*/
BUTTON_RELEASE,
/**
* a key has been pressed.
*/
KEY_PRESS,
/**
* a key has been released.
*/
KEY_RELEASE,
/**
* the pointer has entered the window.
*/
ENTER_NOTIFY,
/**
* the pointer has left the window.
*/
LEAVE_NOTIFY,
/**
* the keyboard focus has entered or left the window.
*/
FOCUS_CHANGE,
/**
* the size, position or stacking order of the window has changed.
* Note that GTK+ discards these events for %GDK_WINDOW_CHILD windows.
*/
CONFIGURE,
/**
* the window has been mapped.
*/
MAP,
/**
* the window has been unmapped.
*/
UNMAP,
/**
* a property on the window has been changed or deleted.
*/
PROPERTY_NOTIFY,
/**
* the application has lost ownership of a selection.
*/
SELECTION_CLEAR,
/**
* another application has requested a selection.
*/
SELECTION_REQUEST,
/**
* a selection has been received.
*/
SELECTION_NOTIFY,
/**
* an input device has moved into contact with a sensing
* surface (e.g. a touchscreen or graphics tablet).
*/
PROXIMITY_IN,
/**
* an input device has moved out of contact with a sensing
* surface.
*/
PROXIMITY_OUT,
/**
* the mouse has entered the window while a drag is in progress.
*/
DRAG_ENTER,
/**
* the mouse has left the window while a drag is in progress.
*/
DRAG_LEAVE,
/**
* the mouse has moved in the window while a drag is in
* progress.
*/
DRAG_MOTION,
/**
* the status of the drag operation initiated by the window
* has changed.
*/
DRAG_STATUS,
/**
* a drop operation onto the window has started.
*/
DROP_START,
/**
* the drop operation initiated by the window has completed.
*/
DROP_FINISHED,
/**
* a message has been received from another application.
*/
CLIENT_EVENT,
/**
* the window visibility status has changed.
*/
VISIBILITY_NOTIFY,
/**
* the scroll wheel was turned
*/
SCROLL,
/**
* the state of a window has changed. See #GdkWindowState
* for the possible window states
*/
WINDOW_STATE,
/**
* a setting has been modified.
*/
SETTING,
/**
* the owner of a selection has changed. This event type
* was added in 2.6
*/
OWNER_CHANGE,
/**
* a pointer or keyboard grab was broken. This event type
* was added in 2.8.
*/
GRAB_BROKEN,
/**
* the content of the window has been changed. This event type
* was added in 2.14.
*/
DAMAGE,
/**
* A new touch event sequence has just started. This event
* type was added in 3.4.
*/
TOUCH_BEGIN,
/**
* A touch event sequence has been updated. This event type
* was added in 3.4.
*/
TOUCH_UPDATE,
/**
* A touch event sequence has finished. This event type
* was added in 3.4.
*/
TOUCH_END,
/**
* A touch event sequence has been canceled. This event type
* was added in 3.4.
*/
TOUCH_CANCEL,
/**
* A touchpad swipe gesture event, the current state
* is determined by its phase field. This event type was added in 3.18.
*/
TOUCHPAD_SWIPE,
/**
* A touchpad pinch gesture event, the current state
* is determined by its phase field. This event type was added in 3.18.
*/
TOUCHPAD_PINCH,
/**
* A tablet pad button press event. This event type
* was added in 3.22.
*/
PAD_BUTTON_PRESS,
/**
* A tablet pad button release event. This event type
* was added in 3.22.
*/
PAD_BUTTON_RELEASE,
/**
* A tablet pad axis event from a "ring". This event type was
* added in 3.22.
*/
PAD_RING,
/**
* A tablet pad axis event from a "strip". This event type was
* added in 3.22.
*/
PAD_STRIP,
/**
* A tablet pad group mode change. This event type was
* added in 3.22.
*/
PAD_GROUP_MODE,
/**
* marks the end of the GdkEventType enumeration. Added in 2.18
*/
EVENT_LAST,
}
/**
* Specifies the result of applying a #GdkFilterFunc to a native event.
*/
/**
* Specifies the result of applying a #GdkFilterFunc to a native event.
*/
export namespace FilterReturn {
export const $gtype: GObject.GType<FilterReturn>;
}
enum FilterReturn {
/**
* event not handled, continue processing.
*/
CONTINUE,
/**
* native event translated into a GDK event and stored
* in the `event` structure that was passed in.
*/
TRANSLATE,
/**
* event handled, terminate processing.
*/
REMOVE,
}
/**
* Indicates which monitor (in a multi-head setup) a window should span over
* when in fullscreen mode.
*/
/**
* Indicates which monitor (in a multi-head setup) a window should span over
* when in fullscreen mode.
*/
export namespace FullscreenMode {
export const $gtype: GObject.GType<FullscreenMode>;
}
enum FullscreenMode {
/**
* Fullscreen on current monitor only.
*/
CURRENT_MONITOR,
/**
* Span across all monitors when fullscreen.
*/
ALL_MONITORS,
}
/**
* Error enumeration for #GdkGLContext.
*/
class GLError extends GLib.Error {
static $gtype: GObject.GType<GLError>;
// Static fields
/**
* OpenGL support is not available
*/
static NOT_AVAILABLE: number;
/**
* The requested visual format is not supported
*/
static UNSUPPORTED_FORMAT: number;
/**
* The requested profile is not supported
*/
static UNSUPPORTED_PROFILE: number;
// Constructors
constructor(options: { message: string; code: number });
_init(...args: any[]): void;
// Static methods
static quark(): GLib.Quark;
}
/**
* Defines how device grabs interact with other devices.
*/
/**
* Defines how device grabs interact with other devices.
*/
export namespace GrabOwnership {
export const $gtype: GObject.GType<GrabOwnership>;
}
enum GrabOwnership {
/**
* All other devices’ events are allowed.
*/
NONE,
/**
* Other devices’ events are blocked for the grab window.
*/
WINDOW,
/**
* Other devices’ events are blocked for the whole application.
*/
APPLICATION,
}
/**
* Returned by gdk_device_grab(), gdk_pointer_grab() and gdk_keyboard_grab() to
* indicate success or the reason for the failure of the grab attempt.
*/
/**
* Returned by gdk_device_grab(), gdk_pointer_grab() and gdk_keyboard_grab() to
* indicate success or the reason for the failure of the grab attempt.
*/
export namespace GrabStatus {
export const $gtype: GObject.GType<GrabStatus>;
}
enum GrabStatus {
/**
* the resource was successfully grabbed.
*/
SUCCESS,
/**
* the resource is actively grabbed by another client.
*/
ALREADY_GRABBED,
/**
* the resource was grabbed more recently than the
* specified time.
*/
INVALID_TIME,
/**
* the grab window or the `confine_to` window are not
* viewable.
*/
NOT_VIEWABLE,
/**
* the resource is frozen by an active grab of another client.
*/
FROZEN,
/**
* the grab failed for some other reason. Since 3.16
*/
FAILED,
}
/**
* Defines the reference point of a window and the meaning of coordinates
* passed to gtk_window_move(). See gtk_window_move() and the "implementation
* notes" section of the
* [Extended Window Manager Hints](http://www.freedesktop.org/Standards/wm-spec)
* specification for more details.
*/
/**
* Defines the reference point of a window and the meaning of coordinates
* passed to gtk_window_move(). See gtk_window_move() and the "implementation
* notes" section of the
* [Extended Window Manager Hints](http://www.freedesktop.org/Standards/wm-spec)
* specification for more details.
*/
export namespace Gravity {
export const $gtype: GObject.GType<Gravity>;
}
enum Gravity {
/**
* the reference point is at the top left corner.
*/
NORTH_WEST,
/**
* the reference point is in the middle of the top edge.
*/
NORTH,
/**
* the reference point is at the top right corner.
*/
NORTH_EAST,
/**
* the reference point is at the middle of the left edge.
*/
WEST,
/**
* the reference point is at the center of the window.
*/
CENTER,
/**
* the reference point is at the middle of the right edge.
*/
EAST,
/**
* the reference point is at the lower left corner.
*/
SOUTH_WEST,
/**
* the reference point is at the middle of the lower edge.
*/
SOUTH,
/**
* the reference point is at the lower right corner.
*/
SOUTH_EAST,
/**
* the reference point is at the top left corner of the
* window itself, ignoring window manager decorations.
*/
STATIC,
}
/**
* An enumeration that describes the mode of an input device.
*/
/**
* An enumeration that describes the mode of an input device.
*/
export namespace InputMode {
export const $gtype: GObject.GType<InputMode>;
}
enum InputMode {
/**
* the device is disabled and will not report any events.
*/
DISABLED,
/**
* the device is enabled. The device’s coordinate space
* maps to the entire screen.
*/
SCREEN,
/**
* the device is enabled. The device’s coordinate space
* is mapped to a single window. The manner in which this window
* is chosen is undefined, but it will typically be the same
* way in which the focus window for key events is determined.
*/
WINDOW,
}
/**
* An enumeration describing the type of an input device in general terms.
*/
/**
* An enumeration describing the type of an input device in general terms.
*/
export namespace InputSource {
export const $gtype: GObject.GType<InputSource>;
}
enum InputSource {
/**
* the device is a mouse. (This will be reported for the core
* pointer, even if it is something else, such as a trackball.)
*/
MOUSE,
/**
* the device is a stylus of a graphics tablet or similar device.
*/
PEN,
/**
* the device is an eraser. Typically, this would be the other end
* of a stylus on a graphics tablet.
*/
ERASER,
/**
* the device is a graphics tablet “puck” or similar device.
*/
CURSOR,
/**
* the device is a keyboard.
*/
KEYBOARD,
/**
* the device is a direct-input touch device, such
* as a touchscreen or tablet. This device type has been added in 3.4.
*/
TOUCHSCREEN,
/**
* the device is an indirect touch device, such
* as a touchpad. This device type has been added in 3.4.
*/
TOUCHPAD,
/**
* the device is a trackpoint. This device type has been
* added in 3.22
*/
TRACKPOINT,
/**
* the device is a "pad", a collection of buttons,
* rings and strips found in drawing tablets. This device type has been
* added in 3.22.
*/
TABLET_PAD,
}
/**
* This enum is used with gdk_keymap_get_modifier_mask()
* in order to determine what modifiers the
* currently used windowing system backend uses for particular
* purposes. For example, on X11/Windows, the Control key is used for
* invoking menu shortcuts (accelerators), whereas on Apple computers
* it’s the Command key (which correspond to %GDK_CONTROL_MASK and
* %GDK_MOD2_MASK, respectively).
*/
/**
* This enum is used with gdk_keymap_get_modifier_mask()
* in order to determine what modifiers the
* currently used windowing system backend uses for particular
* purposes. For example, on X11/Windows, the Control key is used for
* invoking menu shortcuts (accelerators), whereas on Apple computers
* it’s the Command key (which correspond to %GDK_CONTROL_MASK and
* %GDK_MOD2_MASK, respectively).
*/
export namespace ModifierIntent {
export const $gtype: GObject.GType<ModifierIntent>;
}
enum ModifierIntent {
/**
* the primary modifier used to invoke
* menu accelerators.
*/
PRIMARY_ACCELERATOR,
/**
* the modifier used to invoke context menus.
* Note that mouse button 3 always triggers context menus. When this modifier
* is not 0, it additionally triggers context menus when used with mouse button 1.
*/
CONTEXT_MENU,
/**
* the modifier used to extend selections
* using `modifier`-click or `modifier`-cursor-key
*/
EXTEND_SELECTION,
/**
* the modifier used to modify selections,
* which in most cases means toggling the clicked item into or out of the selection.
*/
MODIFY_SELECTION,
/**
* when any of these modifiers is pressed, the
* key event cannot produce a symbol directly. This is meant to be used for
* input methods, and for use cases like typeahead search.
*/
NO_TEXT_INPUT,
/**
* the modifier that switches between keyboard
* groups (AltGr on X11/Windows and Option/Alt on OS X).
*/
SHIFT_GROUP,
/**
* The set of modifier masks accepted
* as modifiers in accelerators. Needed because Command is mapped to MOD2 on
* OSX, which is widely used, but on X11 MOD2 is NumLock and using that for a
* mod key is problematic at best.
* Ref: https://bugzilla.gnome.org/show_bug.cgi?id=736125.
*/
DEFAULT_MOD_MASK,
}
/**
* Specifies the kind of crossing for #GdkEventCrossing.
*
* See the X11 protocol specification of LeaveNotify for
* full details of crossing event generation.
*/
/**
* Specifies the kind of crossing for #GdkEventCrossing.
*
* See the X11 protocol specification of LeaveNotify for
* full details of crossing event generation.
*/
export namespace NotifyType {
export const $gtype: GObject.GType<NotifyType>;
}
enum NotifyType {
/**
* the window is entered from an ancestor or
* left towards an ancestor.
*/
ANCESTOR,
/**
* the pointer moves between an ancestor and an
* inferior of the window.
*/
VIRTUAL,
/**
* the window is entered from an inferior or
* left towards an inferior.
*/
INFERIOR,
/**
* the window is entered from or left towards
* a window which is neither an ancestor nor an inferior.
*/
NONLINEAR,
/**
* the pointer moves between two windows
* which are not ancestors of each other and the window is part of
* the ancestor chain between one of these windows and their least
* common ancestor.
*/
NONLINEAR_VIRTUAL,
/**
* an unknown type of enter/leave event occurred.
*/
UNKNOWN,
}
/**
* Specifies why a selection ownership was changed.
*/
/**
* Specifies why a selection ownership was changed.
*/
export namespace OwnerChange {
export const $gtype: GObject.GType<OwnerChange>;
}
enum OwnerChange {
/**
* some other app claimed the ownership
*/
NEW_OWNER,
/**
* the window was destroyed
*/
DESTROY,
/**
* the client was closed
*/
CLOSE,
}
/**
* Describes how existing data is combined with new data when
* using gdk_property_change().
*/
/**
* Describes how existing data is combined with new data when
* using gdk_property_change().
*/
export namespace PropMode {
export const $gtype: GObject.GType<PropMode>;
}
enum PropMode {
/**
* the new data replaces the existing data.
*/
REPLACE,
/**
* the new data is prepended to the existing data.
*/
PREPEND,
/**
* the new data is appended to the existing data.
*/
APPEND,
}
/**
* Specifies the type of a property change for a #GdkEventProperty.
*/
/**
* Specifies the type of a property change for a #GdkEventProperty.
*/
export namespace PropertyState {
export const $gtype: GObject.GType<PropertyState>;
}
enum PropertyState {
/**
* the property value was changed.
*/
NEW_VALUE,
/**
* the property was deleted.
*/
DELETE,
}
/**
* Specifies the direction for #GdkEventScroll.
*/
/**
* Specifies the direction for #GdkEventScroll.
*/
export namespace ScrollDirection {
export const $gtype: GObject.GType<ScrollDirection>;
}
enum ScrollDirection {
/**
* the window is scrolled up.
*/
UP,
/**
* the window is scrolled down.
*/
DOWN,
/**
* the window is scrolled to the left.
*/
LEFT,
/**
* the window is scrolled to the right.
*/
RIGHT,
/**
* the scrolling is determined by the delta values
* in #GdkEventScroll. See gdk_event_get_scroll_deltas(). Since: 3.4
*/
SMOOTH,
}
/**
* Specifies the kind of modification applied to a setting in a
* #GdkEventSetting.
*/
/**
* Specifies the kind of modification applied to a setting in a
* #GdkEventSetting.
*/
export namespace SettingAction {
export const $gtype: GObject.GType<SettingAction>;
}
enum SettingAction {
/**
* a setting was added.
*/
NEW,
/**
* a setting was changed.
*/
CHANGED,
/**
* a setting was deleted.
*/
DELETED,
}
export namespace Status {
export const $gtype: GObject.GType<Status>;
}
enum Status {
OK,
ERROR,
ERROR_PARAM,
ERROR_FILE,
ERROR_MEM,
}
/**
* This enumeration describes how the red, green and blue components
* of physical pixels on an output device are laid out.
*/
/**
* This enumeration describes how the red, green and blue components
* of physical pixels on an output device are laid out.
*/
export namespace SubpixelLayout {
export const $gtype: GObject.GType<SubpixelLayout>;
}
enum SubpixelLayout {
/**
* The layout is not known
*/
UNKNOWN,
/**
* Not organized in this way
*/
NONE,
/**
* The layout is horizontal, the order is RGB
*/
HORIZONTAL_RGB,
/**
* The layout is horizontal, the order is BGR
*/
HORIZONTAL_BGR,
/**
* The layout is vertical, the order is RGB
*/
VERTICAL_RGB,
/**
* The layout is vertical, the order is BGR
*/
VERTICAL_BGR,
}
/**
* Specifies the current state of a touchpad gesture. All gestures are
* guaranteed to begin with an event with phase %GDK_TOUCHPAD_GESTURE_PHASE_BEGIN,
* followed by 0 or several events with phase %GDK_TOUCHPAD_GESTURE_PHASE_UPDATE.
*
* A finished gesture may have 2 possible outcomes, an event with phase
* %GDK_TOUCHPAD_GESTURE_PHASE_END will be emitted when the gesture is
* considered successful, this should be used as the hint to perform any
* permanent changes.
*
* Cancelled gestures may be so for a variety of reasons, due to hardware
* or the compositor, or due to the gesture recognition layers hinting the
* gesture did not finish resolutely (eg. a 3rd finger being added during
* a pinch gesture). In these cases, the last event will report the phase
* %GDK_TOUCHPAD_GESTURE_PHASE_CANCEL, this should be used as a hint
* to undo any visible/permanent changes that were done throughout the
* progress of the gesture.
*
* See also #GdkEventTouchpadSwipe and #GdkEventTouchpadPinch.
*/
/**
* Specifies the current state of a touchpad gesture. All gestures are
* guaranteed to begin with an event with phase %GDK_TOUCHPAD_GESTURE_PHASE_BEGIN,
* followed by 0 or several events with phase %GDK_TOUCHPAD_GESTURE_PHASE_UPDATE.
*
* A finished gesture may have 2 possible outcomes, an event with phase
* %GDK_TOUCHPAD_GESTURE_PHASE_END will be emitted when the gesture is
* considered successful, this should be used as the hint to perform any
* permanent changes.
*
* Cancelled gestures may be so for a variety of reasons, due to hardware
* or the compositor, or due to the gesture recognition layers hinting the
* gesture did not finish resolutely (eg. a 3rd finger being added during
* a pinch gesture). In these cases, the last event will report the phase
* %GDK_TOUCHPAD_GESTURE_PHASE_CANCEL, this should be used as a hint
* to undo any visible/permanent changes that were done throughout the
* progress of the gesture.
*
* See also #GdkEventTouchpadSwipe and #GdkEventTouchpadPinch.
*/
export namespace TouchpadGesturePhase {
export const $gtype: GObject.GType<TouchpadGesturePhase>;
}
enum TouchpadGesturePhase {
/**
* The gesture has begun.
*/
BEGIN,
/**
* The gesture has been updated.
*/
UPDATE,
/**
* The gesture was finished, changes
* should be permanently applied.
*/
END,
/**
* The gesture was cancelled, all
* changes should be undone.
*/
CANCEL,
}
/**
* Specifies the visiblity status of a window for a #GdkEventVisibility.
*/
/**
* Specifies the visiblity status of a window for a #GdkEventVisibility.
*/
export namespace VisibilityState {
export const $gtype: GObject.GType<VisibilityState>;
}
enum VisibilityState {
/**
* the window is completely visible.
*/
UNOBSCURED,
/**
* the window is partially visible.
*/
PARTIAL,
/**
* the window is not visible at all.
*/
FULLY_OBSCURED,
}
/**
* A set of values that describe the manner in which the pixel values
* for a visual are converted into RGB values for display.
*/
/**
* A set of values that describe the manner in which the pixel values
* for a visual are converted into RGB values for display.
*/
export namespace VisualType {
export const $gtype: GObject.GType<VisualType>;
}
enum VisualType {
/**
* Each pixel value indexes a grayscale value
* directly.
*/
STATIC_GRAY,
/**
* Each pixel is an index into a color map that
* maps pixel values into grayscale values. The color map can be
* changed by an application.
*/
GRAYSCALE,
/**
* Each pixel value is an index into a predefined,
* unmodifiable color map that maps pixel values into RGB values.
*/
STATIC_COLOR,
/**
* Each pixel is an index into a color map that
* maps pixel values into rgb values. The color map can be changed by
* an application.
*/
PSEUDO_COLOR,
/**
* Each pixel value directly contains red, green,
* and blue components. Use gdk_visual_get_red_pixel_details(), etc,
* to obtain information about how the components are assembled into
* a pixel value.
*/
TRUE_COLOR,
/**
* Each pixel value contains red, green, and blue
* components as for %GDK_VISUAL_TRUE_COLOR, but the components are
* mapped via a color table into the final output table instead of
* being converted directly.
*/
DIRECT_COLOR,
}
/**
* Determines a window edge or corner.
*/
/**
* Determines a window edge or corner.
*/
export namespace WindowEdge {
export const $gtype: GObject.GType<WindowEdge>;
}
enum WindowEdge {
/**
* the top left corner.
*/
NORTH_WEST,
/**
* the top edge.
*/
NORTH,
/**
* the top right corner.
*/
NORTH_EAST,
/**
* the left edge.
*/
WEST,
/**
* the right edge.
*/
EAST,
/**
* the lower left corner.
*/
SOUTH_WEST,
/**
* the lower edge.
*/
SOUTH,
/**
* the lower right corner.
*/
SOUTH_EAST,
}
/**
* Describes the kind of window.
*/
/**
* Describes the kind of window.
*/
export namespace WindowType {
export const $gtype: GObject.GType<WindowType>;
}
enum WindowType {
/**
* root window; this window has no parent, covers the entire
* screen, and is created by the window system
*/
ROOT,
/**
* toplevel window (used to implement #GtkWindow)
*/
TOPLEVEL,
/**
* child window (used to implement e.g. #GtkEntry)
*/
CHILD,
/**
* override redirect temporary window (used to implement
* #GtkMenu)
*/
TEMP,
/**
* foreign window (see gdk_window_foreign_new())
*/
FOREIGN,
/**
* offscreen window (see
* [Offscreen Windows][OFFSCREEN-WINDOWS]). Since 2.18
*/
OFFSCREEN,
/**
* subsurface-based window; This window is visually
* tied to a toplevel, and is moved/stacked with it. Currently this window
* type is only implemented in Wayland. Since 3.14
*/
SUBSURFACE,
}
/**
* These are hints for the window manager that indicate what type of function
* the window has. The window manager can use this when determining decoration
* and behaviour of the window. The hint must be set before mapping the window.
*
* See the [Extended Window Manager Hints](http://www.freedesktop.org/Standards/wm-spec)
* specification for more details about window types.
*/
/**
* These are hints for the window manager that indicate what type of function
* the window has. The window manager can use this when determining decoration
* and behaviour of the window. The hint must be set before mapping the window.
*
* See the [Extended Window Manager Hints](http://www.freedesktop.org/Standards/wm-spec)
* specification for more details about window types.
*/
export namespace WindowTypeHint {
export const $gtype: GObject.GType<WindowTypeHint>;
}
enum WindowTypeHint {
/**
* Normal toplevel window.
*/
NORMAL,
/**
* Dialog window.
*/
DIALOG,
/**
* Window used to implement a menu; GTK+ uses
* this hint only for torn-off menus, see #GtkTearoffMenuItem.
*/
MENU,
/**
* Window used to implement toolbars.
*/
TOOLBAR,
/**
* Window used to display a splash
* screen during application startup.
*/
SPLASHSCREEN,
/**
* Utility windows which are not detached
* toolbars or dialogs.
*/
UTILITY,
/**
* Used for creating dock or panel windows.
*/
DOCK,
/**
* Used for creating the desktop background
* window.
*/
DESKTOP,
/**
* A menu that belongs to a menubar.
*/
DROPDOWN_MENU,
/**
* A menu that does not belong to a menubar,
* e.g. a context menu.
*/
POPUP_MENU,
/**
* A tooltip.
*/
TOOLTIP,
/**
* A notification - typically a “bubble”
* that belongs to a status icon.
*/
NOTIFICATION,
/**
* A popup from a combo box.
*/
COMBO,
/**
* A window that is used to implement a DND cursor.
*/
DND,
}
/**
* `GDK_INPUT_OUTPUT` windows are the standard kind of window you might expect.
* Such windows receive events and are also displayed on screen.
* `GDK_INPUT_ONLY` windows are invisible; they are usually placed above other
* windows in order to trap or filter the events. You can’t draw on
* `GD