Browse files

Fixed #82. Made the partitioner conservative, meaning no attempt is …

…made to be

smart about partitioning changes: it always assumes partitioning has changed. Should be ok
for relatively small documents as the worksheet is using.
  • Loading branch information...
dragos committed Sep 17, 2012
1 parent 693b47b commit 1d1d4a79a842959356cfeed3f4d81efe27f9efc9
@@ -16,7 +16,10 @@ class ScriptDocumentProvider extends FileDocumentProvider {
doc match {
case docExt: IDocumentExtension3 =>
- val partitioner = new ScalaDocumentPartitioner
+ // TODO: maybe it's not necessary to be conservative. This makes the partitioner
+ // always return 'true' when asked about changed partitioning. Fixes #82, that
+ // lost colorization when entering a new line between an expression and its result
+ val partitioner = new ScalaDocumentPartitioner(conservative=true)
docExt.setDocumentPartitioner(ScalaPartitioning.SCALA_PARTITIONING, partitioner)

0 comments on commit 1d1d4a7

Please sign in to comment.