InputEventWithModifiers

package
v0.0.0-...-80877a9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 8, 2025 License: MIT Imports: 22 Imported by: 0

Documentation

Overview

Package InputEventWithModifiers provides methods for working with InputEventWithModifiers object instances.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Advanced

type Advanced = class

Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.

type Any

type Any interface {
	gd.IsClass
	AsInputEventWithModifiers() Instance
}

type Instance

type Instance [1]gdclass.InputEventWithModifiers

Stores information about mouse, keyboard, and touch gesture input events. This includes information about which modifier keys are pressed, such as [kbd]Shift[/kbd] or [kbd]Alt[/kbd]. See [method Node._input].

var Nil Instance

Nil is a nil/null instance of the class. Equivalent to the zero value.

func New

func New() Instance

func (Instance) AltPressed

func (self Instance) AltPressed() bool

func (Instance) AsInputEvent

func (self Instance) AsInputEvent() InputEvent.Instance

func (Instance) AsInputEventFromWindow

func (self Instance) AsInputEventFromWindow() InputEventFromWindow.Instance

func (Instance) AsInputEventWithModifiers

func (self Instance) AsInputEventWithModifiers() Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) AsRefCounted

func (self Instance) AsRefCounted() [1]gd.RefCounted

func (Instance) AsResource

func (self Instance) AsResource() Resource.Instance

func (Instance) CommandOrControlAutoremap

func (self Instance) CommandOrControlAutoremap() bool

func (Instance) CtrlPressed

func (self Instance) CtrlPressed() bool

func (Instance) GetModifiersMask

func (self Instance) GetModifiersMask() KeyModifierMask

Returns the keycode combination of modifier keys.

func (Instance) IsCommandOrControlPressed

func (self Instance) IsCommandOrControlPressed() bool

On macOS, returns [code]true[/code] if [kbd]Meta[/kbd] ([kbd]Cmd[/kbd]) is pressed. On other platforms, returns [code]true[/code] if [kbd]Ctrl[/kbd] is pressed.

func (Instance) MetaPressed

func (self Instance) MetaPressed() bool

func (Instance) SetAltPressed

func (self Instance) SetAltPressed(value bool)

func (Instance) SetCommandOrControlAutoremap

func (self Instance) SetCommandOrControlAutoremap(value bool)

func (Instance) SetCtrlPressed

func (self Instance) SetCtrlPressed(value bool)

func (Instance) SetMetaPressed

func (self Instance) SetMetaPressed(value bool)

func (Instance) SetShiftPressed

func (self Instance) SetShiftPressed(value bool)

func (Instance) ShiftPressed

func (self Instance) ShiftPressed() bool

func (*Instance) UnsafePointer

func (self *Instance) UnsafePointer() unsafe.Pointer

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type KeyModifierMask

type KeyModifierMask int
const (
	/*Key Code mask.*/
	KeyCodeMask KeyModifierMask = 8388607
	/*Modifier key mask.*/
	KeyModifierMaskDefault KeyModifierMask = 532676608
	/*Automatically remapped to [constant KEY_META] on macOS and [constant KEY_CTRL] on other platforms, this mask is never set in the actual events, and should be used for key mapping only.*/
	KeyMaskCmdOrCtrl KeyModifierMask = 16777216
	/*Shift key mask.*/
	KeyMaskShift KeyModifierMask = 33554432
	/*Alt or Option (on macOS) key mask.*/
	KeyMaskAlt KeyModifierMask = 67108864
	/*Command (on macOS) or Meta/Windows key mask.*/
	KeyMaskMeta KeyModifierMask = 134217728
	/*Control key mask.*/
	KeyMaskCtrl KeyModifierMask = 268435456
	/*Keypad key mask.*/
	KeyMaskKpad KeyModifierMask = 536870912
	/*Group Switch key mask.*/
	KeyMaskGroupSwitch KeyModifierMask = 1073741824
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL