struct @extern Eina.File; [[Eina file data structure]]
+struct @extern Eina.Vector2 {
+ [[A simple 2D vector type using floating point values.]]
+ x: double; [[X coordinate.]]
+ y: double; [[Y coordinate.]]
+}
+
struct @extern Eina.Matrix3 {
[[Eina 3x3 Matrix]]
xx: double; [[XX matrix value]]
}
EOLIAN static void
+_efl_input_pointer_precise_position_set(Eo *obj EINA_UNUSED, Efl_Input_Pointer_Data *pd, Eina_Vector2 pos)
+{
+ _efl_input_value_mark(pd, EFL_INPUT_VALUE_X);
+ _efl_input_value_mark(pd, EFL_INPUT_VALUE_Y);
+ pd->cur = pos;
+}
+
+EOLIAN static Eina_Vector2
+_efl_input_pointer_precise_position_get(Eo *obj EINA_UNUSED, Efl_Input_Pointer_Data *pd)
+{
+ return pd->cur;
+}
+
+EOLIAN static void
_efl_input_pointer_previous_position_set(Eo *obj EINA_UNUSED, Efl_Input_Pointer_Data *pd, Eina_Position2D pos)
{
_efl_input_value_mark(pd, EFL_INPUT_VALUE_PREVIOUS_X);
@property position {
[[Position where the event happened, relative to the window.
- This position, in integers, is an approximation of
- @.value.get($x), @.value.get($y). Use @.position if you need
- simple pixel positions, but prefer the generic interface
- if you need precise coordinates.
+ See @.precise_position for floating point precision (subpixel
+ location).
]]
values {
pos: Eina.Position2D; [[The position of the event, in pixels.]]
}
}
+ @property precise_position {
+ [[Position where the event happened, relative to the window.
+
+ This position is in floating point values, for more precise
+ coordinates, in subpixels. Note that many input devices are unable
+ to give better precision than a single pixel, so this may be
+ equal to @.position.
+
+ See also @.position.
+ ]]
+ values {
+ pos: Eina.Vector2; [[The position of the event, in pixels.]]
+ }
+ }
@property previous_position {
[[Position of the previous event, valid for move events.