Delivered-To: garrigue at math.nagoya-u.ac.jp Authentication-Results: mailhost.math.nagoya-u.ac.jp sender=lablgtk-bounces at yquem.inria.fr; domainkey=neutral (no query protocol specified; no policy for yquem.inria.fr) Delivered-To: lablgtk at yquem.inria.fr DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=u7h1Yf/4gMRce86GmQ2PEKKMrarMqBIJ0E+KkZCi+qY=; b=UM5HCcwTgdp7WBi6LSekwc2kUXEKrcklZPXhtDyb8+ORk2wSLoNqFfrdqBTRPT//zk Uki0tCKpCpDmq9U+W6k65JFtDRUL1E8Bj48QgDQwzwYmobuU/oObvANahDIXJE7NnXy3 TUMDNrN6uAQeOmrWvObeAiHx4fObNPAsi8IZM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=PEwEUjDeEro48BYBBY7EN+0MteFMhQWZ20RcEDzbxc59rroOEZjt6/+/w3oIPUxyk0 vH6FseRH1betzZK8LYkLEYv88vLFpUHIYj/vIlJkjzY7eyiGlk2ZXN8A5vvj7nRE/Bgy 3tmNyd/Pw3uZt09fVQCc7haIsJ4Wc246K45zI= MIME-Version: 1.0 In-Reply-To: References: Date: Sat, 4 Sep 2010 12:37:04 +0200 Message-ID: Subject: Re: [Lablgtk] entry completion for hundreds of thousands of items From: Adrien To: yoann padioleau Content-Type: text/plain; charset=ISO-8859-1 Cc: lablgtk at yquem.inria.fr Status: U Hi, I've only taken a very quick look at your code but I think that what you need is described in the treeview tutorial[1]. Also, I've experienced such issues with pretty short lists or trees. No need to have 1000 elements, something like 50 or 100 may be enough to notice a slowdown. Hope this helps. [1] http://plus.kaist.ac.kr/~shoh/ocaml/lablgtk2/treeview-tutorial/ch03s03.html#sec-treestore-adding-many-rows -- Adrien Nader On 04/09/2010, yoann padioleau wrote: > Hi, > > I want to provide some completion for text where the corpus of items is > above 100000. I've tried to build a GTree.list_store with those 100000 items > but it takes a too long time to build the model. I've then tried to > split those 100 000 iterms > in chunk of 1000 based on common prefix. Then as the user start to > type a string, I build a model > with only the relevant 1000 items. But even building a model with only > 1000 items takes more than 2 seconds > which makes the whole application look slow. Is there a way to > accelerate the insertion of items > in a list_store ? > > I've attached my modification of src/examples/entrycompletion.ml > showing how slow it is. > _______________________________________________ Lablgtk mailing list Lablgtk@yquem.inria.fr http://yquem.inria.fr/cgi-bin/mailman/listinfo/lablgtk