Skip to content

Delayed match-highlight causes bad partial reparses #3787

Closed
@mtaran-google

Description

Repro steps:

  1. Replace CodeMirror/mode/markdown/index.html with the attached index.html
  2. Open that index.html
  3. Paste in the contents of aaaa.txt (sorry I couldn't make up a small repro case)
  4. In the console run editor.setCursor({line: 485, ch: 28, xRel: 1})

Expected:
Editor scrolls to the indicated position

Actual:
Editor scrolls to the indicated position, and then the highlighting gets messed up, flipping code-style and normal-style text. I'm pretty sure this is because of a reparse/redraw that doesn't start very far up above the upper edge of the viewport.

repro.zip

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions