Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-09

lhelp application fails to compile

5 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Howard Page-Clark

Compiling the lhelp project (lazarus\components\chmhelp\help\lhelp.lpi) fails because there are two different lhelpcontrol.pas files, identically named. One is in the lhelp application folder, the other in a chmhelp\packages\help subdirectory used for compiling the lhelpcontrolpkg package which is a project requirement. Changing the lhelp\lhelpcontrol.pas file to be identical in content as well as in name with the file needed to compile the lhelpconrolpkg.pkg then produces the compiler parser error:

Identifier not found "GetFPImageReaderForFileExtension"

Indeed this function is not in any of the graphics units given in the project's uses clause. I cannot find it anywhere else either. Can anyone shed any light?

[I'm using Lazarus SVN 14813 FPC 2.2.2 Windows XP SP3 (or is it now 4?)]

thanks in advance

Howard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.lazarus.freepascal.org/pipermail/lazarus/attachments/20080913/095ad222/attachment.html

Reply by email

Lord Satan
to Howard Page-Clark
Show quoted text 5 lines
Identifier not found "GetFPImageReaderForFileExtension" Indeed this function is not in any of the graphics units given in the project's uses clause. > I cannot find it anywhere else either. Can anyone shed any light?

This function was removed. There was talk about a replacement system for it but I don't know the actual status. I think the easiest way would be to just write a similar function yourself. This is what I did after the removal. But I also changed my code from using TLazIntfImage to using TFPCustomImage. I don't know if this is an option for lhelp. Here is my more than simple function:

function GetFPImageReaderForFileExtension(const FileExt: string
  ): TFPCustomImageReaderClass;
begin
  if FileExt='.bmp' then Result:=TFPReaderBMP;
  if (FileExt='.jpg') or (FileExt='.jpeg') then Result:=TFPReaderJPEG;
  if FileExt='.png' then Result:=TFPReaderPNG;
  if FileExt='.tga' then Result:=TFPReaderTarga;
  if FileExt='.xpm' then Result:=TFPReaderXPM;
end;

hope it helps

Reply by email

Howard Page-Clark
to Lord Satan

Many thanks, it works a treat (I commented out the TPFReaderTarga line, since that function seems to have disappeared as well). The Readme.txt for the project says:

From the Help menu choose "Configure Help"
Change to the "Viewers" tab and select "CHM Help Viewer"

The "CHM Help Viewer" line is no longer present in current Lazarus versions. Any idea how to reinstate this correctly?

Howard

Earlier message 41 lines
----- Original Message ----- From: "Lord Satan" To: Sent: Sunday, September 14, 2008 2:37 PM Subject: Re: [Lazarus] lhelp application fails to compile > On Sat, 13 Sep 2008 22:44:40 +0100 > "Howard Page-Clark" wrote: > >> Identifier not found "GetFPImageReaderForFileExtension" >> >> Indeed this function is not in any of the graphics units given in the >> project's uses clause. > I cannot find it anywhere else either. >> Can anyone shed any light? >> > > This function was removed. There was talk about a replacement system for > it but I don't know the actual status. I think the easiest way would be to > just write a similar function yourself. This is what I did after the > removal. But I also changed my code from using TLazIntfImage to using > TFPCustomImage. I don't know if this is an option for lhelp. > Here is my more than simple function: > > function GetFPImageReaderForFileExtension(const FileExt: string > ): TFPCustomImageReaderClass; > begin > if FileExt='.bmp' then Result:=TFPReaderBMP; > if (FileExt='.jpg') or (FileExt='.jpeg') then Result:=TFPReaderJPEG; > if FileExt='.png' then Result:=TFPReaderPNG; > if FileExt='.tga' then Result:=TFPReaderTarga; > if FileExt='.xpm' then Result:=TFPReaderXPM; > end; > > hope it helps > > > _______________________________________________ > Lazarus mailing list > > http://www.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply by email

Lord Satan
to Howard Page-Clark
Many thanks, it works a treat (I commented out the TPFReaderTarga line, since that function seems to have disappeared as well).

No, it hasn't. But TLazIntfImage does not seem to support tga in contrast to TFPCustomImage which I use.

A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail?

Reply by email

Howard Page-Clark
to Lord Satan
A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail?

Point taken.

Howard

Reply by email