iink SDK on Device

Join gesture recognition error

After breaking two lines of text through the Insert gesture, the Item ID Array of 'after' cannot be recognized through the Join gesture

image

The following figure shows the method of synchronizing with OffScreenEditor by using the Insert gesture to break two lines of text, replacing the old Brush with a new one.

image

I don't know if I'm doing this correctly, how can I correctly let OffScreenEditor know that I changed the position of the Brush so that they can accurately recognize other gestures next time

1 Comment

Hello,


Thank you for contacting us.


When using the OffScreenEditor, your application is responsible of the ink model and must keep iink SDK informed of any changes.

So if you want to use insert gestures to break two lines of text, your application is responsible for computing the new location of the "after" strokes, once moved by the insert gesture.

It must then inform the OffScreenEditor of the changes, so that iink SDM updates it model, either by:

  •  using the replaceStrokes with "after" strokes, and the replacing strokes pointer events corresponding to the new coordinates of the "after" strokes that your application has computed
  • or using the transform method with after" strokes and the transform that correspond to the strokes shift you want to apply on the insert gestures. Please note that you can use the getTransformStatus before calling the trasnform method, to make sure that the transform you intend to apply is allowed, before actually applying it.


Best regards,


Gwenaëlle

Login or Signup to post a comment