Re: [PATCH (GIT-GUI,GITK) 6/8] gitk: Port new encoding logic from git-gui.
- From
Alexander Gavrilov <angavrilov@gmail.com>
- Date
- Sep 22, 2008, 10:18 UTC
- Message-ID
- <bb6f213e0809220318k7e505281n53a3948540869894@mail.gmail.com>
- In-Reply-To
- <48D762EC.2030009@viscovery.net>
On Mon, Sep 22, 2008 at 1:18 PM, Johannes Sixt <j.sixt@viscovery.net> wrote:
Show 6 quoted lines
> Alexander Gavrilov schrieb: >> You can also try applying this patch (originally made for git-gui). It may save >> additional 0.3 sec, especially for obscure legacy encodings. > > Is this about startup time? Personally, I don't care about 0.3 sec startup > time. I close my primary gitk and git-gui Windows only once a week. ;-)
As encoding lookups are currently cached, all this discussion is about the first viewing.
This patch addresses the time necessary to convert an arbitrary encoding name to a name that is known to Tcl, or determine that it is not supported. Without the patch it is done using a linear search through a large table of aliases. In git-gui it caused a noticeable delay before the Encoding submenu, which lists all available encodings, was displayed.
Alexander