-
-
Notifications
You must be signed in to change notification settings - Fork 82
[BUG] Mouse selection highlights wrong text #182
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't workingupstreamSomething not possible or wrong with mathjax (math), obsidian or codemirror 6 (editor)Something not possible or wrong with mathjax (math), obsidian or codemirror 6 (editor)
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingupstreamSomething not possible or wrong with mathjax (math), obsidian or codemirror 6 (editor)Something not possible or wrong with mathjax (math), obsidian or codemirror 6 (editor)
Write the following inline equation in Obsidian (this is just an example):
Now try to select this equation, by clicking on the right end (just before the ending
$) and dragging the mouse (with the click held) to the left, until the beginning (just after the first$). Do not include the$'s in the selection. Then, you will see the following gets highlighted as the selection:which is wrong of course because we wanted to select the full equation, not just this portion. Apparently the concealment confuses the selection highlight logic. In fact, in reality the full equation is selected, as you can check by doing Ctrl+C and Ctrl+V somewhere, the full equation gets pasted.
So the bug is only visual, the selected "highlighted" text does not correspond to the actual selected text. I think it's related to how concealment expands those greek letters when selected.