Re: wxEditor v0.2 released

new topic     » goto parent     » topic index » view thread      » older message » newer message
Greg Haberek said...

Weird. :/ On my 2.8Ghz w/HT, 2GB Windows XP Pro box computer at work, it runs flawlessly, with no flicker whatsoever both translated and interpreted. On my 2.4Ghz w/HT 1.5 GB Ubuntu 8.04 box at home, it runs like crap. I think it has to do with two factors: how big the file is (I load it as one sequence per line), and that I refresh the entire screen on each action. Therefore, I need at least two things to get it to work a lot faster:

Ok, loaded a big file, and then it was pretty slow. Actually, the easiest way to speed it up is to not redraw all the lines. In wxSyntax.e:redraw_line() I just did a naive cutoff of 100 lines (so it's drawing too many, but I figure it's unlikely to be showing more than that), and it performs much better:

    -- redraw lines 
    bottom = length( text ) 
    if bottom - top > 100 then 
    	bottom = top + 100 
    end if 
    for line = top to bottom do 
        redraw_line( this, line ) 
    end for 

Matt

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu