How to reproduce:

- Have a big node with @killcolor on first line
- Edit the lines in the beginning (after @killcolor). Observe the slowness
- Press ctrl+c a lot on the terminal where you started leo. You will
node tracebacks like:

http://pastebin.com/m67dd39a8

Note how you can find stuff like @python_rule21 in the traceback
(which signifies we are doing way too much work).

Also, there should probably be a very fast @killcolor check to see
whether there is @killcolor on the first line of document. This would
avoid the need to do getAllText one extra time. The rest of @killcolor
checks should be done as well, but here it's probably fruitful to
optimize for the common case (remember that getAllText is expensive as
hell).

You can probably use

QTextDocument QTextEdit::document ()
QTextBlock QTextDocument::begin ()
QString QTextBlock::text ()

-- 
Ville M. Vainio
http://tinyurl.com/vainio

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/leo-editor?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to