backspaces / agentscript

An Agent Based Modeling system (ABM)
http://backspaces.github.io/agentscript/
GNU General Public License v3.0
107 stars 14 forks source link

code mirror in IDE may need a refresh() #46

Closed stephenguerin closed 3 years ago

stephenguerin commented 3 years ago

script text and line numbers aren't fully rendering on Chrome. Tested on two windows 10, Android chrome and chromebook:

image

backspaces commented 3 years ago

@stephenguerin Could you post either the html file or pebble so we could recreate the issue?

stephenguerin commented 3 years ago

I am just using the example pebbles. I see the same behavior on Edge.

As I play with the bug, on any of the pages with an issue, if I reduce patchSize or Width in the view and toggle back into Model tab it renders fine. And if I increase patchSize or Width over some threshold, I can bring back the rendering bug.

Do you see the same issue?

I suspect it has to do with the code mirror text area resize event (even though the text area width appears constant) and maybe needing a code-mirror.refresh()

backspaces commented 3 years ago

I'm closing this. Lets move it to the editor repo if it is still important