Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-28 Thread Martin Friebe
Flávio Etrusco wrote: > On Wed, Mar 4, 2009 at 11:27 AM, Martin Friebe wrote: > >> Hi, >> >> To take the discussion of the bug tracker. >> >> My current intention on this issue would be to solve the additional >> issues, such as double scan on Paste, or ensuring LoadFromFile only does >> a sing

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Waldenburg
Martin Friebe schrieb: > Martin Friebe wrote: > >> Martin Waldenburg wrote: >> >>> Martin Friebe schrieb: >>> >>> It is still way faster than a person can ever type. >>> if one does things more complicated as needed one will also >>> likely introduce mo

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Martin Friebe wrote: > Martin Waldenburg wrote: >> Martin Friebe schrieb: >> >>> It is still way faster than a person can ever type. >>> >> if one does things more complicated as needed one will also >> likely introduce more bugs. >> A few minutes more thinking often saves hours of work, >>

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Martin Waldenburg wrote: > Martin Friebe schrieb: > >> It is still way faster than a person can ever >> type. >> > if one does things more complicated as needed one will also > likely introduce more bugs. > A few minutes more thinking often saves hours of work, > in my experience. > > Mart

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Waldenburg
Martin Friebe schrieb: > It is still way faster than a person can ever > type. if one does things more complicated as needed one will also likely introduce more bugs. A few minutes more thinking often saves hours of work, in my experience. Martin ___ L

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Martin Waldenburg wrote: > Martin Friebe schrieb: > >> Some of the highlighting (actually folding) added (by me) needed more >> complexity. >> > I doubt, that more complexity is needed. > Actually you are right. The problem lies in the folding module. But anyway, even on a low power co

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Waldenburg
Martin Friebe schrieb: > Some of the highlighting (actually folding) added (by me) needed more > complexity. I doubt, that more complexity is needed. > The cost on normal operation can be ignored. A highlighter should be lightning fast even on an underpowered netbook, as it was designed to work

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Flávio Etrusco wrote: > On Wed, Mar 4, 2009 at 8:04 PM, Martin Friebe wrote: > >> To avoid any misunderstanding: >> >> *If* / *Once* BeginUpdate works, then you can insert a batch of say 100 >> lines (with Lines.Add or Lines.Insert). It will scan 101 lines (because >> yes, 1 line needs to be re

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Martin Waldenburg wrote: > Hans-Peter Diettrich schrieb: > >> I found it sufficient when the highlighter only parses the current >> line(s) while painting the text. >> > > By the original design the highlighter parses only more than one line if > the Range > is changed by typing. > There i

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Waldenburg
Hans-Peter Diettrich schrieb: > I found it sufficient when the highlighter only parses the current > line(s) while painting the text. By the original design the highlighter parses only more than one line if the Range is changed by typing. There is no logical reason to change this behavior, foldin

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Flávio Etrusco
> Sorry, I meant when you paste _at EOL_. Dang, I meant _EOF_. I should have made it clear before that the problem as I see only/always involves the last line/EOF. Best regards, Flávio ___ Lazarus mailing list Lazarus@lazarus.freepascal.org http://www.

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Flávio Etrusco
> > Do you refer to paste, as done by SynEdit internally (not by externally > calling lines.Insert) ? > > Because the current paste (if you press ctrl-v in the IDE, having 10 > lines in the Clipboard) isn't affected by this bug. (I looked at it in > the debugger) > It is affected by 2 other things:

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Flávio Etrusco wrote: >>> *If* BeginUpdate works, then the content of my original mail should be >>> applicable >> To avoid any misunderstanding: >> >> *If* / *Once* BeginUpdate works, then you can insert a batch of say 100 >> lines (with Lines.Add or Lines.Insert). It will scan 101 lines (because

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Martin Friebe
Hans-Peter Diettrich wrote: > Flávio Etrusco schrieb: > > >> Calling BeginUpdate is not enough, they must disable/unset the >> highlighter to avoid the double parse. >> > > I found it sufficient when the highlighter only parses the current > line(s) while painting the text. When the highli

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-05 Thread Hans-Peter Diettrich
Flávio Etrusco schrieb: > Calling BeginUpdate is not enough, they must disable/unset the > highlighter to avoid the double parse. I found it sufficient when the highlighter only parses the current line(s) while painting the text. When the highlighter information is reduced to a flag, indicating

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Flávio Etrusco
On Wed, Mar 4, 2009 at 8:04 PM, Martin Friebe wrote: > Martin Friebe wrote: >> Flávio Etrusco wrote: >> >>> On Wed, Mar 4, 2009 at 11:27 AM, Martin Friebe wrote: >>> This would mean the only Problem remaining is: If a user writes his own code, calling Lines.Add (or even Lines.Insert) >>

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Martin Friebe
Martin Friebe wrote: > Flávio Etrusco wrote: > >> On Wed, Mar 4, 2009 at 11:27 AM, Martin Friebe wrote: >> >>> This would mean the only Problem remaining is: >>> If a user writes his own code, calling Lines.Add (or even Lines.Insert) >>> in a loop. And does so without calling Lines.Begin

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Martin Friebe
Flávio Etrusco wrote: > On Wed, Mar 4, 2009 at 11:27 AM, Martin Friebe wrote: > >> Hi, >> >> To take the discussion of the bug tracker. >> >> My current intention on this issue would be to solve the additional >> issues, such as double scan on Paste, or ensuring LoadFromFile only does >> a sing

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Flávio Etrusco
On Wed, Mar 4, 2009 at 11:27 AM, Martin Friebe wrote: > Hi, > > To take the discussion of the bug tracker. > > My current intention on this issue would be to solve the additional > issues, such as double scan on Paste, or ensuring LoadFromFile only does > a single scan for all lines in one go) > >

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Paul Ishenin
Vincent Snijders wrote: > IMHO, if the user does not call Lines.BeginUpdate before doing > Lines.Add or Lines.Insert, then the performance penality is his own > fault, not something that must be fixed. > Absolutely agree. Best regards, Paul Ishenin. _

Re: [Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Vincent Snijders
2009/3/4 Martin Friebe : > Hi, > > To take the discussion of the bug tracker. > > My current intention on this issue would be to solve the additional > issues, such as double scan on Paste, or ensuring LoadFromFile only does > a single scan for all lines in one go) > > This would mean the only Prob

[Lazarus] About 0013268: SynEdit parses every li ne twice on load or paste (Attn: Flávio)

2009-03-04 Thread Martin Friebe
Hi, To take the discussion of the bug tracker. My current intention on this issue would be to solve the additional issues, such as double scan on Paste, or ensuring LoadFromFile only does a single scan for all lines in one go) This would mean the only Problem remaining is: If a user writes his