codemirror / codemirror5

In-browser code editor (version 5, legacy)
http://codemirror.net/5/
MIT License
26.81k stars 4.96k forks source link

The default combination of search and matchesonscrollbar extensions doesn't work #5919

Open Leonya opened 5 years ago

Leonya commented 5 years ago

Search matches are supposed to be highlighted on the scrollbar once the corresponding add-ons are loaded, without any configuration. Alas, it doesn't work anymore: https://codemirror.net/demo/search.html

marijnh commented 5 years ago

It does in both Firefox and Chrome Linux, so it'd be helpful if you include some information on the platform you are testing with.

Leonya commented 5 years ago

I have tried Chrome, Firefox, Safari on Mac: neither of them shows the markers

Screenshot 2019-06-27 at 22 51 41
Leonya commented 5 years ago

I have investigated the matter a bit more: the bug is caused by Mac's default "invisible scrollbars" behaviour. If I turn on the "Always show scrollbars" setting, the markers are shown.

marijnh commented 5 years ago

Right, it's basing the area where the markers can be shown on actual platform scrollbar width, so when the scrollbar isn't there, it doesn't show markers. I haven't looked into what other software that shows markers like this does in such a case.

Leonya commented 5 years ago

The thing is, this used to work before.

marijnh commented 5 years ago

In which version?

Leonya commented 5 years ago

I can't say for sure, but it did, 100%