[Lazarus] lHelp improvements

Marco van de Voort fpc at pascalprogramming.org
Mon Dec 28 13:41:29 CET 2020

Op 12/28/2020 om 2:03 AM schreef Mattias Gaertner via lazarus:
>> - When I press F1 for the lHelp enabled for context searching, then
>> Lazarus send group of command as
>>      got BeginUpdate
>>      got BeginUpdate
>>      got rturl, filename M:\lazarus\docs\chm\fcl.chm, url /index.html
>>      got rturl, filename M:\lazarus\docs\chm\fclres.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\fpdoc.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\ideintf.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\lazutils.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\lcl.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\prog.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\ref.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\rtl.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\toc.chm,
>> url /index.html got rturl, filename M:\lazarus\docs\chm\user.chm,
>> url /index.html got EndUpdate
>>      got rturl, filename M:\lazarus\docs\chm\ref.chm,
>> url /ref/refse92.html#keyword_function got EndUpdate
>>      got rtmisc/mrShow
>>      Lazarus sends commands for opening all chm files and the last
>> command is for performing contex search. As result hh.exe always does
>> it more faster then lHelp. I think behavior have to be same, only a
>> perform of context seaching. On second request lHelp can open next
>> file and index and so on.

Afaik most of the binary indexes (index, FTS) can be mergesorted 
together rather cheaply and then stored on disk. Using these rather than 
converting everything to text and then parse that again would make it 
very fast. This is what HH does.

Even faster is caching the result of the merge on disk (which HH also 
does, but only in case of "merged" chm files, which doesn't work with 
FPC generated CHM files yet), these are then stored as CHW.

But to invalidate the cache, it should be stored which CHMs were used to 
generate it. So that the cache can be invalided.

I'll look into the various fpdoc and chm stuff from tomorrow, when I get 
home again

More information about the lazarus mailing list