Forum > KOL
KOL-CE with FPC - Bugs found
br_klaus:
I tried to compile and install KOL-CE in Lazarus with FPC 3.1.1. But there were some problems:
The official “latest” version of KOL-CE I found on the KOL-CE homepage (kol-ce.net): KOL 3.22 with MCK 3.23 (which is equal to 3.20).
But these are versions without (in MCK) mentioning FPC.
So I downloaded the latest svn-version: https://kol-ce.svn.sourceforge.net/svnroot/kol-ce/trunk/: KOL 2.88 – MCK 2.87.
It seems that this version of KOL was for FPC 2.2x or 2.4x. But now I am using FPC 3.1.1 (coming with CodeTyphon). Since FPC 2.5x Lazarus/FPC made some changes, so I introduced a new define (ifdef _F25orHigher).
The changes are:
LazarusIDE.DoOpenEditorFile --> has one more parameter
SourceEditorWindow --> now use SourceEditorManagerIntf
GetLookupRootForComponent --> now in unit PropEditUtils
(The changes made in KOL and MCK are in the attached file KOLcorr.txt)
With these changes made, I finally succeeded in compiling the MirrorKOLPackage.lpk
Then I installed, also OK
But now running a simple test with only one form with a Button, I had some problems.
1) I got the error message: “KOLUnit1.pas(56,2) Fatal: It is not possible to include a file that starts with an UTF-8 BOM in a module that uses a different code page”
I had to delete the BOM at the beginning of unit1_1.inc manually.
Therfore I deleted the insertion of Utf8BOM in the procedure TKOLFormGenerateINC, where the source code said SL.Add ({$IFDEF FPC} Utf8BOM + {$ENDIF} Signature )
2) The caption `Übung` was not shown correctly, I had to write in NewForm1 function the button caption as Utf8Decode(´Übung´), now it was OK.
3) But now there are many problems with the Object manager and Codetolols etc.
Clicking on an event in the object manager does not create the correspondent procedure in the source window, Clicking on the form or the button does not produce any effect in the object manager, but is always creating error (cannot find mewthod etc.)
It seems that there must be some bug in TKOLObjectEditor. I found there a real define mismatch!
The interface part (in MIRROR.PAS) looks like this:
(ifdef FPC)
TKOLObjectCompEditor = …
.Edit
(else Delphi)
TKOLObjectCompEditor = …
(ifdef _D6orHigher) CountEvents .CheckEdit .EditProperty
(else) CountEvents ChekEdit
(ifdef FPC) EditProperty <-- can never be compiled!
(else) EditProperty
(endif)
(endif)
Edit
(endif FPC)
TKOLEveentPropEditor = … <--- nothing if FPC!
(ifdef _D2) GetTrimmedEventName GetFormMethodName
(endif)
(ifndef FPC) Edit
(endif)
(_D2) is only defined if Delphi (Ver90), therefore undefined if FPC.
If the Compiler is FPC then it will never be able to read the second Ifdef FPC-part in TKOLObjectCompEditor, because this is in the else-part. This means that it never will read that there is a procedure Editproperty (and the same happened in the implementation part).
And then the Ifndef FPC in TKOLOnEventPropEditor would also be useless.
But the register procedures (in MIRROR and MCKObjs) include TKOLOnEventPropEditor too, with or without FPC.
And the implementation part looks like this:
TKOLObjectCompEditor
(idfef FPC) Edit; begin … end;
(else Delphi)
(ifdef _D6orHigher) CheckEdit
(else) CheckEdit
(endif)
begin … if Continue then (ifndef FPC) … <--- useless
(endif)
end;
CountEvents begin … end;
Edit begin .. end;
(ifdef _D6orHigher) EditProperty
(else)
(ifdef FPC) EditProperty <--- can never be compiled
(else) EditProperty
(endif)
(endif)
ReplaceBest
begin … (ifndef FPC) ….. (endif) <--- useless
end;
begin … (ifndef FPC) … (endif) <--- useless
end;
(endif FPC)
(ifdef _D2)
TKOLOnEventPropEditor
GetFromMethodName
begin … (ifdef _D2) … <--- useless
(else _D3orHigher) <--- will never be compiled
(endif)
end;
GetTrimmedEventname begin end;
(endif)
In Lazarus TdefaultComponentEditor has both procedures, Edit and EditProperty, but here the component would be only with Edit.
I hope this bug can be solved.
Thanks
Leledumbo:
Mmm...shouldn't you report to KOL-CE maintainer?
br_klaus:
--- Quote from: Leledumbo on February 03, 2015, 02:12:30 am ---Mmm...shouldn't you report to KOL-CE maintainer?
--- End quote ---
Where can I do this?
It is said:
Report bugs, submit patches and ask questions at project's page at SourceForge: http://sourceforge.net/projects/kol-ce/
But there I cannot find any possibility to send a bug. What is going wrong?
Awkward:
You can try to report here: http://www.delphimaster.ru/cgi-bin/forum.pl?n=10
br_klaus:
--- Quote from: Awkward on February 03, 2015, 01:42:56 pm ---You can try to report here: http://www.delphimaster.ru/cgi-bin/forum.pl?n=10
--- End quote ---
Unfortunately this is all in russian. I do not know how to send there my bug report. Is there no english page? Is there no possibility to contact directly Yury Sidorov who brought KOL-CE to Lazarus?
Navigation
[0] Message Index
[#] Next page