<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On 29 September 2013 20:53, Pavel Roschin <span dir="ltr"><<a href="mailto:rpg89@post.ru" target="_blank">rpg89@post.ru</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">> Well, the costly part is the rendering, which happens from a delayed GTK<br>
> idle callback inside scintilla.  As Matthew said when the text is inserted<br>
> into the buffer the cursor is at the end, getting it back to the start<br>
> before the rendering is important, the less of the text Scintilla renders<br>
> the better, and if the position is set at zero it *should* only render the<br>
> start of the text, not the whole file, which would happen if the position<br>
> was still at the end.<br>
<br>
</div>I didn't noticed that somewhere cursor placed at end of file. </blockquote><div><br></div><div>When the file is loaded the text is set in the Scintilla buffer, which is an insert, and the cursor is always after any insert, ie at the end.  Its not an explicit set position command.</div>
<div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Geany calls<br>
set_cursor_position several times. But actually goto isn't bottleneck, only<br>
SCI_ENSUREVISIBLE slows things down.<br></blockquote><div><br></div><div>Hmmm, bearing in mind we are now talking about the internals of the scintilla implementation of (one of) its backends.  It sort of makes sense that an "ensure visible" operation requires the lexer to be run to find the fold points so it can check that they are unfolded, and it is conceivable that checking visibility might require rendering as well (for the purpose of measuring what text fits on the screen, not actual display). And those then have to be done immediately, not delayed.  All of which adds to the the overhead.</div>
<div><br></div><div>Cheers</div><div>Lex</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
P.S. I hope now all messages are correct? I had a troubles with my mail filters.<br></blockquote><div><br></div><div>Sadly no, it still cced me directly, that means the default reply to is to you, not the list, thats because the list message arrives second and is hidden since its a copy.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5"><br>
--<br>
Best regards,<br>
Pavel Roschin aka RPG<br>
</div></div></blockquote></div><br></div></div>