[Kst] Re: Some details to improve

Peter Kümmel syntheticpp at gmx.net
Sun Jan 30 16:44:32 CET 2011


> Apart from these new points, there is something we have already
> discussed. I thought Barth had solved it, but I actually believe it is
> still there. The problem is the first page of the datawizard, which
> sometimes freezes for a few seconds. 
> 
> To test it, just create a directory with a number of very large ASCII
> files with names beginning with a common string, and try to select them
> in a new kst session (that is, when we don't already have a datasource
> object that only gets reused). Below is my analysis of what happens (not
> cross-checked with breakpoints in the debugger, I must confess).
> 
> When I select a huge ASCII file (>2 million points), before I even have
> a chance to click "configure..." it gets parsed, which freezes the UI
> for a few long seconds. I suspect the whole file gets parsed already,
> which does not make sense at that point. We should wait until the user
> clicks "Next". We should only detect the type, which I believe should be
> faster than it is. I thought Barth had introduced some mechanism for
> that, but I'm not sure it prevents parsing the whole file. I haven't
> tested again right now, but I think if you have a couple of large files
> in the same directory and scroll through them in the popup that appears
> as you type the beginning of the name in the lineedit (assuming you type
> it) or as you hover the item in the file dialog (assuming you use the
> dialog through the button on the right), each time one gets selected it
> triggers the textChanged() signal, which triggers the validate() slot,
> which parses the whole file.

This should be better now, it only reads the first block of the file
which is fast. Could you test if it is usable now.

Peter


More information about the Kst mailing list