Crate gdk

Source
Expand description

§Rust GDK 3 bindings

This project is UNMAINTAINED. Please take a look at gtk4-rs instead!

Project site is here.

Rust bindings and wrappers for GDK 3, part of gtk3-rs.

GDK 3.22 is the lowest supported version for the underlying library.

§Minimum supported Rust version

Currently, the minimum supported Rust version is 1.70.0.

§Documentation

§Using

We recommend using crates from crates.io, as demonstrated here.

If you want to track the bleeding edge, use the git dependency instead:

[dependencies]
gdk = { git = "https://github.com/gtk-rs/gtk3-rs.git", package = "gdk" }

Avoid mixing versioned and git crates like this:

# This will not compile
[dependencies]
gdk = "0.13"
gdk = { git = "https://github.com/gtk-rs/gtk3-rs.git", package = "gdk" }

§See Also

§License

gdk is available under the MIT License, please refer to it.

Re-exports§

pub use cairo;
pub use ffi;
pub use gdk_pixbuf;
pub use gio;
pub use glib;
pub use pango;

Modules§

keys
prelude
Traits intended for blanket imports.

Structs§

AnchorHints
AppLaunchContext
Atom
AxisFlags
Color
Cursor
Device
DeviceManager
DevicePad
DeviceTool
Display
DisplayManager
DragAction
DragContext
DrawingContext
Event
A generic GDK event.
EventButton
EventConfigure
EventCrossing
EventDND
EventExpose
EventFocus
EventGrabBroken
EventKey
EventMask
EventMotion
EventOwnerChange
EventPadAxis
EventPadButton
EventPadGroupMode
EventProperty
EventProximity
EventScroll
EventSelection
EventSequence
EventSetting
EventTouch
EventTouchpadPinch
EventTouchpadSwipe
EventVisibility
EventWindowState
FrameClock
FrameClockPhase
FrameTimings
GLContext
GRange
Geometry
Keymap
KeymapKey
ModifierType
Monitor
RGBA
Rectangle
Screen
Seat
SeatCapabilities
TimeCoord
Visual
WMDecoration
WMFunction
Window
WindowAttr
WindowHints
WindowState

Enums§

AxisUse
Backend
ByteOrder
ChangeData
CrossingMode
CursorType
DevicePadFeature
DeviceToolType
DeviceType
DragCancelReason
DragProtocol
EventType
FullscreenMode
GLError
GrabOwnership
GrabStatus
Gravity
InputMode
InputSource
ModifierIntent
NotifyType
OwnerChange
PropMode
PropertyState
ScrollDirection
SettingAction
SubpixelLayout
VisibilityState
VisualType
WindowEdge
WindowType
WindowTypeHint
WindowWindowClass

Constants§

ATOM_NONE
BUTTON_MIDDLE
The middle button.
BUTTON_PRIMARY
The primary button. This is typically the left mouse button, or the right button in a left-handed setup.
BUTTON_SECONDARY
The secondary button. This is typically the right mouse button, or the left button in a left-handed setup.
EVENT_PROPAGATE
EVENT_STOP
SELECTION_CLIPBOARD
SELECTION_PRIMARY
SELECTION_SECONDARY
SELECTION_TYPE_ATOM
SELECTION_TYPE_BITMAP
SELECTION_TYPE_COLORMAP
SELECTION_TYPE_DRAWABLE
SELECTION_TYPE_INTEGER
SELECTION_TYPE_PIXMAP
SELECTION_TYPE_STRING
SELECTION_TYPE_WINDOW
TARGET_BITMAP
TARGET_COLORMAP
TARGET_DRAWABLE
TARGET_PIXMAP
TARGET_STRING

Traits§

FromEvent
A helper trait implemented by all event subtypes.

Functions§

beep
display_arg_name
error_trap_pop
error_trap_pop_ignored
error_trap_push
events_get_angle
events_get_center
events_get_distance
events_pending
flush
init
notify_startup_complete
notify_startup_complete_with_id
pango_context_get
pango_context_get_for_display
pango_context_get_for_screen
pango_layout_get_clip_region
pango_layout_line_get_clip_region
pixbuf_get_from_surface
program_class
property_change
property_delete
property_get
selection_convert
selection_owner_get
selection_owner_get_for_display
selection_owner_set
selection_owner_set_for_display
selection_send_notify
selection_send_notify_for_display
set_allowed_backends
set_double_click_time
set_initialized
Informs this crate that GDK has been initialized and the current thread is the main one.
set_program_class
set_show_events
setting_get
shows_events
synthesize_window_state
test_render_sync
test_simulate_button
test_simulate_key
text_property_to_utf8_list_for_display
utf8_to_string_target

Type Aliases§

key