| Top | Description | Object Hierarchy | Properties | Signals |
struct MetaBarrier; struct MetaBarrierClass; gboolean meta_barrier_is_active (MetaBarrier *barrier); void meta_barrier_destroy (MetaBarrier *barrier); void meta_barrier_release (MetaBarrier *barrier,MetaBarrierEvent *event); enum MetaBarrierDirection; struct MetaBarrierEvent;
"directions" MetaBarrierDirection : Read / Write / Construct Only "display" MetaDisplay* : Read / Write / Construct Only "x1" gint : Read / Write / Construct Only "x2" gint : Read / Write / Construct Only "y1" gint : Read / Write / Construct Only "y2" gint : Read / Write / Construct Only
struct MetaBarrier;
The MetaBarrier structure contains only private data and should be accessed using the provided API
struct MetaBarrierClass {
};
The MetaBarrierClass structure contains only private data.
void meta_barrier_release (MetaBarrier *barrier,MetaBarrierEvent *event);
In XI2.3, pointer barriers provide a feature where they can be temporarily released so that the pointer goes through them. Pass a MetaBarrierEvent to release the barrier for this event sequence.
|
The barrier to release |
|
The event to release the pointer for |
typedef enum {
META_BARRIER_DIRECTION_POSITIVE_X = 1 << 0,
META_BARRIER_DIRECTION_POSITIVE_Y = 1 << 1,
META_BARRIER_DIRECTION_NEGATIVE_X = 1 << 2,
META_BARRIER_DIRECTION_NEGATIVE_Y = 1 << 3,
} MetaBarrierDirection;
struct MetaBarrierEvent {
int event_id;
int dt;
guint32 time;
double x;
double y;
double dx;
double dy;
gboolean released;
gboolean grabbed;
};
| A unique integer ID identifying a consecutive series of motions at or along the barrier | |
| Server time, in milliseconds, since the last event sent for this barrier | |
| Server time, in milliseconds | |
| The cursor X position in screen coordinates | |
| The cursor Y position in screen coordinates. | |
| If the cursor hadn't been constrained, the delta of X movement past the barrier, in screen coordinates | |
| If the cursor hadn't been constrained, the delta of X movement past the barrier, in screen coordinates | |
A boolean flag, TRUE if this event generated
by the pointer leaving the barrier as a result of a client
calling meta_barrier_release() (will be set only for
MetaBarrier::leave signals) |
|
A boolean flag, TRUE if the pointer was grabbed
at the time this event was sent |
"directions" property"directions" MetaBarrierDirection : Read / Write / Construct Only
A set of directions to let the pointer through.
"display" property"display" MetaDisplay* : Read / Write / Construct Only
The display to construct the pointer barrier on.
"x1" property "x1" gint : Read / Write / Construct Only
The first X coordinate of the barrier.
Allowed values: [0,32767]
Default value: 0
"x2" property "x2" gint : Read / Write / Construct Only
The second X coordinate of the barrier.
Allowed values: [0,32767]
Default value: 32767
"y1" property "y1" gint : Read / Write / Construct Only
The first Y coordinate of the barrier.
Allowed values: [0,32767]
Default value: 0
"hit" signalvoid user_function (MetaBarrier *barrier,
MetaBarrierEvent *event,
gpointer user_data) : Run First
When a pointer barrier is hit, this will trigger. This requires an XI2-enabled server.
|
The MetaBarrier that was hit |
|
A MetaBarrierEvent that has the details of how the barrier was hit. |
|
user data set when the signal handler was connected. |
"left" signalvoid user_function (MetaBarrier *barrier,
MetaBarrierEvent *event,
gpointer user_data) : Run First
When a pointer barrier hitbox was left, this will trigger. This requires an XI2-enabled server.
|
The MetaBarrier that was left |
|
A MetaBarrierEvent that has the details of how the barrier was left. |
|
user data set when the signal handler was connected. |