Page 1 of 1

problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 09:58
by lashkevi
On the overleaf.com site (online LaTeX editor) in the editor field the cursor position does not match character, which makes editing very boring. You never knows, which character will be erased or where in the line you will insert new text. There is no such problem in Firefox or Google Chrome. It seems, that Pale Moon does not calculate width of characters correctly.

On the attached screenshot you can see that the cursor (gray vertical line), which is set to the end of the line, is shifted to the right of the last letter. In fact this displacement increases while moving the cursor from the beginning along a line.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 10:07
by Moonchild
And why is this a browser problem?
if they use custom styling to fake text editing, instead of standard elements or htmleditables, then the display bugs with it are theirs to solve.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 10:13
by lashkevi
Moonchild wrote:
2020-03-24, 10:07
And why is this a browser problem?
Because there is no such problem in other browsers. By the way, the look of the font used in the Pale Moon differs from that used in other browsers. Maybe something could be done by tuning fonts in Settings, but, as far as I tried, they change absolutely nothing.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 10:18
by Moonchild
lashkevi wrote:
2020-03-24, 10:13
Because there is no such problem in other browsers.
That's no argument. We aren't other browsers. We don't have the same rendering quirks as they might have, and our engine won't render everything exactly the same either. You can't expect us to toss out our rendering engine just because a site miscalculates metrics.
lashkevi wrote:
2020-03-24, 10:13
the look of the font used in the Pale Moon differs from that used in other browsers
The that is probably at the root of this problem -- they explicitly assume the font has certain glyph sizes and calculate the "cursor" position based on that.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 12:01
by lashkevi
The Overleaf support service was helpful. They recommended me to set the browser monospace font to Fira Mono, which saved the situation.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 12:17
by lashkevi
Default "monospace" also works. I formerly set it to Noto Sans, since it looked better in other application. Mia culpa.

Re: problem in overleaf.com editor: cursor does not match characters

Posted: 2020-03-24, 13:16
by Moonchild
lashkevi wrote:
2020-03-24, 12:17
Default "monospace" also works. I formerly set it to Noto Sans, since it looked better in other application. Mia culpa.
Well, there you have it then. I don't think Noto Sans is a monospaced font.