XusinboyBekchanov / VisualFBEditor

IDE for FreeBasic
Other
167 stars 39 forks source link

Code editor get slow if the amount of lines increases #57

Open rexxitall opened 4 years ago

rexxitall commented 4 years ago

If the amount of lines exceeds a "special" amount of lines - code gets long for example 2000 lines, the movement with mouse or keyboard gets slower and slower. I have the glue that it might be a problem with the syntax highlight engine. This problem is common. Usually it appears when all the time the whole code is recalculated. The usual solution is to prepare the highlight only for the code which is shown to the user currently and maybe for speed reasons, some lines above and upon (pgup pgdown). And 2000 Lines in a module are not a big chunk :) Notepad++ does not care about big files he still is all the time very fast. Just a one example of such a editor. Codemirror is the same even he lives inside a browser window. He also uses the trick just to prepare the lines which are visible.

rexxitall commented 4 years ago

hm i comented a lot of things out - fact a whole large module. on comented lines it was fast. I have not a C64 breadbox as a computer. smile But nearly nothing is more annoying then to see the cursor jump and wait and jump and wait :) Last times i saw such a thing was around 1980 as we have had dos computers hanging on a 2300 baud modem and a mailbox. Or on computers and terminals which have had same connection speed by a com line . For sure good old feelings and a small time travel but :)

XusinboyBekchanov commented 4 years ago

This fixed. Due to some change in EditControl, the speed dropped in 64-bit mode. Returned previous speed. https://github.com/XusinboyBekchanov/VisualFBEditor/commit/6e4b01313ca5952cfd312bf3a8f414bbb6910036

rexxitall commented 4 years ago

No, sorry it is still slow.