mwieder / glx2ScriptEditor

glx2ScriptEditor is an alternative script editor for the LiveCode IDE
MIT License
6 stars 3 forks source link

in new script - after typing for example "on m" cursor jumps into new line... #2

Closed matthiasrebbe closed 4 years ago

matthiasrebbe commented 4 years ago

when editing a new script the cursor jumps into a new line after typing for example "on m". after that, the cursor jumps after each character into a new line.

Recipe

  1. create new stack
  2. edit stack or card script in GLX2
  3. type on mouse or function whatever or command whatever

expected behavior: the text should be written into the current line

observed behavior: only the control structure keyword and the first character of the message/function/command are written into the current line. The other characters are written each into a separate line.

This only happens with control structure keywords. When typing just text or comments beginning with --,##,// or /* this does not happen.

mwieder commented 4 years ago

Thanks. Well... that took some doing.

That cursor jumping thing is something I thought I had quashed a couple of weeks ago.. Just spent a few hours pulling out what's left of my hair tracking that one down. Turns out it's an engine bug... if you set the script of an object and it reports an error code (as when you're entering a new handler) then when you start typing the name of the handler the engine reports a line number 1 greater than the line you're on. Plus the error reported is 173, which is "drag: bad end point expression". So I've got my workaround in place now to step around the engine bug.