Sign in Join

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

Mailing lists / lazarus / 2008-06

Package Images4Lazaurs does not compile anymore

18 messages · 6 people · –

Reply by email Subscribe to this list Your subscription

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

Lord Satan

Hi all,

as the subject says.

lazpng.pas(33,20) Error: There is no method in an ancestor class to be overridden: "class TPNGImage.GetDefaultFPReader:Class Of TFPCustomImageReader"
lazpng.pas(34,20) Error: There is no method in an ancestor class to be overridden: "class TPNGImage.GetDefaultFPWriter:Class Of TFPCustomImageWriter"
lazpng.pas(43,1) Fatal: There were 2 errors compiling module, stopping

Ubuntu 8.04 64 bit
FPC 2.3.1
Lazarus revision 15550

Marc Weustink
to Lord Satan
Lord Satan wrote 9 lines
Hi all, as the subject says. lazpng.pas(33,20) Error: There is no method in an ancestor class to be overridden: "class TPNGImage.GetDefaultFPReader:Class Of TFPCustomImageReader" lazpng.pas(34,20) Error: There is no method in an ancestor class to be overridden: "class TPNGImage.GetDefaultFPWriter:Class Of TFPCustomImageWriter" lazpng.pas(43,1) Fatal: There were 2 errors compiling module, stopping

Most image formats are now supported by lazarus natively. Is there a reason you need the package ?

Marc

Marc Weustink
to Mattias Gärtner
Mattias G?rtner wrote 19 lines
Zitat von Marc Weustink : > Lord Satan wrote: >> Hi all, >> >> as the subject says. >> >> lazpng.pas(33,20) Error: There is no method in an ancestor class to be > overridden: "class TPNGImage.GetDefaultFPReader:Class Of > TFPCustomImageReader" >> lazpng.pas(34,20) Error: There is no method in an ancestor class to be > overridden: "class TPNGImage.GetDefaultFPWriter:Class Of > TFPCustomImageWriter" >> lazpng.pas(43,1) Fatal: There were 2 errors compiling module, stopping > Most image formats are now supported by lazarus natively. Is there a > reason you need the package ? Either the package must be repaired or removed for 0.9.26. I suggest to keep the package and to only remove the LCL formats.

ok

This way experimental or future complex image formats like gif and svg can be added to the package. Marc, should I clean up the package?

if you will, please do.

(changing is mostly renaming GetDefaultFPReader/Writer -> GetReader/Writer)

Marc

Mattias Gärtner
to Marc Weustink

Zitat von Marc Weustink :

Show quoted text 31 lines
Mattias G?rtner wrote: > Zitat von Marc Weustink : > >> Lord Satan wrote: >>> Hi all, >>> >>> as the subject says. >>> >>> lazpng.pas(33,20) Error: There is no method in an ancestor class to be >> overridden: "class TPNGImage.GetDefaultFPReader:Class Of >> TFPCustomImageReader" >>> lazpng.pas(34,20) Error: There is no method in an ancestor class to be >> overridden: "class TPNGImage.GetDefaultFPWriter:Class Of >> TFPCustomImageWriter" >>> lazpng.pas(43,1) Fatal: There were 2 errors compiling module, stopping >> Most image formats are now supported by lazarus natively. Is there a >> reason you need the package ? > > Either the package must be repaired or removed for 0.9.26. > I suggest to keep the package and to only remove the LCL formats. ok > This way experimental or future complex image formats like gif and svg can be > added to the package. > Marc, should I clean up the package? if you will, please do. (changing is mostly renaming GetDefaultFPReader/Writer -> GetReader/Writer)

Done in r15560.

Mattias

Marc Weustink
to Lord Satan
Lord Satan wrote
Ok, Lazarus compiles. But what happened to GetFPImageReaderForFileExtension?

That will be replaced with a different system I think

Marc

Lord Satan
to Marc Weustink
Show quoted text 5 lines
Lord Satan wrote: > Ok, Lazarus compiles. > But what happened to GetFPImageReaderForFileExtension? That will be replaced with a different system I think

And what do I use now? My code does not compile because it relies on GetFPImageReaderForFileExtension. Are there any other options than to revert to an old Lazarus version and stay there until this system is finished?

Marc Weustink
to Mattias Gärtner
Mattias G?rtner wrote 8 lines
Zitat von Marc Weustink : > Lord Satan wrote: >> Ok, Lazarus compiles. >> But what happened to GetFPImageReaderForFileExtension? > That will be replaced with a different system I think Where are all these changes documented?

Not. Maybe I'll write them after the bigger picture of the changes is clear. Point is that we now have 2 or 3 different format registration systems mixed. IMO this is suboptimal. So I'm thinking of one new way.

Marc

Marc Weustink
to Lord Satan: On Tue, 24 Jun 2008 15:54:54 +0200 And what do I use now? My code does not compile…
Lord Satan wrote 9 lines
On Tue, 24 Jun 2008 15:54:54 +0200 Marc Weustink wrote: > Lord Satan wrote: >> Ok, Lazarus compiles. >> But what happened to GetFPImageReaderForFileExtension? > That will be replaced with a different system I think And what do I use now? My code does not compile because it relies on GetFPImageReaderForFileExtension. Are there any other options than to revert to an old Lazarus version and stay there until this system is finished?

I fear that GetFPImageReaderForFileExtension won't come back. It simply doesn't work with the current model. There will be a system which returns the graphic class you can use to read an image.

Marc

Lord Satan
to Marc Weustink
I fear that GetFPImageReaderForFileExtension won't come back. It simply doesn't work with the current model. There will be a system which returns the graphic class you can use to read an image.

This means at the moment there is nothing and you do not know when a replacement system will be in place. Correct? I need to support as many image formats as possible. My image class is derived from TLazIntfImage and my loading routine uses GetFPImageReaderForFileExtension. What is my replacement now?
What is the workaround?
I don't like to be stuck on revision 15471. There is a reason that I use the lazarus svn version. I understand that there are some big changes going on, but this worked for years and I need a replacement now. What are your suggestions?

tia

Marc Weustink
to Lord Satan
Lord Satan wrote 13 lines
On Tue, 24 Jun 2008 23:32:59 +0200 Marc Weustink wrote: > I fear that GetFPImageReaderForFileExtension won't come back. It simply > doesn't work with the current model. There will be a system which > returns the graphic class you can use to read an image. This means at the moment there is nothing and you do not know when a replacement system will be in place. Correct? I need to support as many image formats as possible. My image class is derived from TLazIntfImage and my loading routine uses GetFPImageReaderForFileExtension. What is my replacement now? What is the workaround? I don't like to be stuck on revision 15471. There is a reason that I use the lazarus svn version. I understand that there are some big changes going on, but this worked for years and I need a replacement now. What are your suggestions?

Use ImageHandlers in the unit FPImage

Marc

Lord Satan
to Marc Weustink
Use ImageHandlers in the unit FPImage

Either TImageHandlersManager is much more sophisticated than I think (and I don't understand anything) or you are telling me to implement the replacement for GetFPImageReaderForFileExtension myself, because I don't see that ImageHandlers has the functionality I want. Namely getting the correct ImageReader/Writer for a given extensions, although it can be used to write such a function.

But you did not use ImageHandlers to replace GetFPImageReaderForFileExtension yourself, so where is the catch?

thanks for your help

OsvaldoTCF
to Mattias Gaertner

Save Lazarus on Linux:

http://lazarus-dev.blogspot.com/

a comment:
"I agree with henry, great article. However I think that the trayicon example is not quite fair since windows and qt have "native" traywidgets gtk (current bindings) does not. The Gtk1 and Gtk2 implementations are really X11 implementations which is inherently horrible and clumsy to use :)
There is now a gtk trayicon widget in newer version of Gtk2 but the bindings don't yet exist for freepascal."

What do we do? Claim all users of Lazarus on Linux! GTK2 is the way possible for a widgetset on Linux in six months?

Thanks, sorry my english.

Felipe Monteiro de Carvalho
to OsvaldoTCF

Please answer in the blog instead so that we can keep the discussion (and the controversy it seams =P ) in 1 place.

thanks,

Felipe Monteiro de Carvalho