rihakd / textAnalytics

0 stars 0 forks source link

!! Editable + Highlightable text #10

Open rihakd opened 9 years ago

rihakd commented 9 years ago

LINKS:

rihakd commented 9 years ago

To make sure that the program flow is satisfied when working with the editable window, on each click check the position of the cursor relative to its parent Node. If the parent is the div => we are outside a word. If parent is span => we are inside word, so this should be the easy case. Although what about the case when we click on index one inside a span.

rihakd commented 9 years ago

In this comment I want discuss a few scenarios in the editable area:

  1. Click in a random place in text
    • Click in the beginning of a non-span
    • Click at the end of a non-span
    • Click in the middle of a non-span text, which is only possible when multiple " "
  2. Press key
    • Press any normal key after " "
    • Press any normal key after a normal char
    • ... to be continued