<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
</head><body>
<p style="margin: 0;"><span><span></span></span></p>
<p style="margin: 0px; "></p>
<div style="margin: 5px 0px 5px 0px;">
<br/>Graeme Geldenhuys <graemeg.lists@gmail.com> hat am 18. Juli 2012 um 19:53 geschrieben:
<br/>
<br/>> Hi,
<br/>>
<br/>>
<br/>> > I think Reinier and I are saying that the need in the current case is how to
<br/>> > intercept F1 and recover an associated keyword, and how to pass that keyword
<br/>> > to lhelp.
<br/>>
<br/>> Surely the "capturing of the F1 key press" functionality already
<br/>> exists in LCL? I also see TControl.HelpType, TControl.HelpContext,
<br/>> TControl.HelpKeyword and Application.HelpFile properties... Are they
<br/>> just for show (not functional yet)?
</div>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">They do work.</p>
<p style="margin: 0px;">See here an example with HTML pages:</p>
<p style="margin: 0px;">http://wiki.lazarus.freepascal.org/Add_Help_to_Your_Application</p>
<p style="margin: 0px;"> </p>
<div style="margin: 5px 0px 5px 0px;">
>
<br/>> Another problem I spotted was with the Application.HelpCommand()
<br/>> signature. It's got the signature designed by Borland Delphi v1
<br/>> (somewhere around then) for the use with the very old WinHelp help
<br/>> viewer and the long discontinued .HLP files.
</div>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">There are:</p>
<p>function HelpCommand(Command: Word; Data: PtrInt): Boolean;<br/> function HelpContext(Context: THelpContext): Boolean;<br/> function HelpKeyword(const Keyword: String): Boolean;</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">The Keyword can be an arbitrary string. In the HTML viewer it is the path behind the BaseURL.</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;"> </p>
<div style="margin: 5px 0px 5px 0px;">
> I've already raised this> issue some years back, but received my usual answer that it will not
<br/>> be changed - go figure. Anyway, a more sane signature for
<br/>> Application.HelpCommand() would be like Delphi & Kylix defined it for
<br/>> the CLX framework. As a matter of fact, the help system for CLX was
<br/>> designed to be cross-platform and uses Interfaces to be very flexible.
<br/>> It is probably the cleanest help system design I have ever seen, and
<br/>> it supports multiple help viewers too. Kylix even came with two
<br/>> reference implementations - a Man Page viewer and a HyperHelp viewer.
</div>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">The current help system knows viewers and databases (= sources). It's not clx compatible though.</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">Mattias</p>
<p style="margin: 0px;"> </p>
</body></html>