case TEXT_SETCURSOR:
DrawEditorElement(last_sx, last_sy, Feld[lx][ly]);
DrawAreaBorder(sx, sy, sx, sy);
+ StartTextInput(SX + sx * ed_tilesize, SY + sy * ed_tilesize,
+ ed_tilesize, ed_tilesize);
last_sx = sx;
last_sy = sy;
break;
break;
case TEXT_NEWLINE:
- if (sy + 1 < ed_fieldy - 1 && ly + 1 < lev_fieldy - 1)
+ if (sy + 1 < ed_fieldy && ly + 1 < lev_fieldy)
DrawLevelText(start_sx, sy + 1, 0, TEXT_SETCURSOR);
else
DrawLevelText(0, 0, 0, TEXT_END);
case TEXT_END:
CopyLevelToUndoBuffer(UNDO_IMMEDIATE);
DrawEditorElement(sx, sy, Feld[lx][ly]);
+ StopTextInput();
typing = FALSE;
break;