forked from scala-ide/scala-worksheet
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix scala-ide#25 - Caret is kept at the same position after evaluation
* Empty lines are no longer stripped, the reasons are: + Keep correct indentation of empty lines. + Correct handling of caret position (i.e., if the caret is in the middle of an empty line, it should stay there after evaluation). * The new caret position can never be after the old caret position (this should motivate the change in Mixer.scala) This fixes the issue with correctly updating the caret position in most of the situations, but not all of them. Honestly, I don't think we should spend more time with trying to improve this, because messing with the user's document is just wrong. Instead, we should split the editor into two views: a left one used by the user to write code, and a right to show the evaluation result (scala-ide#70).
- Loading branch information
Showing
3 changed files
with
11 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters