Package org.gnome.gdk
Class TimeCoord
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.gnome.gdk.TimeCoord
- All Implemented Interfaces:
Proxy
A
GdkTimeCoord
stores a single event in a motion history.
To check whether an axis is present, check whether the corresponding
flag from the Gdk.AxisFlags
enumeration is set in the flags
To access individual axis values, use the values of the values of
the Gdk.AxisUse
enumerations as indices.
-
Constructor Summary
ConstructorDescriptionAllocate a new TimeCoord.Allocate a new TimeCoord with the fields set to the provided values.Allocate a new TimeCoord with the fields set to the provided values.Allocate a new TimeCoord.TimeCoord
(MemorySegment address) Create a TimeCoord proxy instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemoryLayout
The memory layout of the native struct.double[]
readAxes()
Read the value of the fieldaxes
.Read the value of the fieldflags
.int
readTime()
Read the value of the fieldtime
.void
Write a value in the fieldaxes
.void
writeFlags
(Set<AxisFlags> flags) Write a value in the fieldflags
.void
writeTime
(int time) Write a value in the fieldtime
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
TimeCoord
Create a TimeCoord proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
TimeCoord
Allocate a new TimeCoord.- Parameters:
arena
- to control the memory allocation scope
-
TimeCoord
public TimeCoord()Allocate a new TimeCoord. The memory is allocated withArena.ofAuto()
. -
TimeCoord
Allocate a new TimeCoord with the fields set to the provided values.- Parameters:
time
- value for the fieldtime
flags
- value for the fieldflags
axes
- value for the fieldaxes
arena
- to control the memory allocation scope
-
TimeCoord
Allocate a new TimeCoord with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
time
- value for the fieldtime
flags
- value for the fieldflags
axes
- value for the fieldaxes
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readTime
public int readTime()Read the value of the fieldtime
.- Returns:
- The value of the field
time
-
writeTime
public void writeTime(int time) Write a value in the fieldtime
.- Parameters:
time
- The new value for the fieldtime
-
readFlags
-
writeFlags
-
readAxes
public double[] readAxes()Read the value of the fieldaxes
.- Returns:
- The value of the field
axes
-
writeAxes
Write a value in the fieldaxes
.- Parameters:
axes
- The new value for the fieldaxes
_arena
- to control the memory allocation scope
-