Recent

Author Topic: convert Sebran delphi(4) code to lazarus  (Read 92496 times)

Vincent Snijders

  • Administrator
  • Hero Member
  • *
  • Posts: 2661
    • My Lazarus wiki user page
Re: convert Sebran delphi(4) code to lazarus
« Reply #75 on: February 17, 2009, 11:59:35 am »
Can be a lot of things, for example:
You didn't include the unit in which TfrmOvMemory and frmOvMemory are declared in the uses clause of HMENY.PAS.

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #76 on: February 17, 2009, 12:13:44 pm »


Hi Vincent

first of all Tanx a lot for your help.

At the begining I had to change one file name Memory to Memoryy
because it has colidate with a unit of compiler with the same name.
could it be the problem ?
what could I do now ?
 

Vincent Snijders

  • Administrator
  • Hero Member
  • *
  • Posts: 2661
    • My Lazarus wiki user page
Re: convert Sebran delphi(4) code to lazarus
« Reply #77 on: February 17, 2009, 12:33:40 pm »
Find places where you previously used a unit called Memory. Make sure you use a unit called Memoryy now.

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #78 on: February 17, 2009, 02:03:29 pm »

I have change the filename from Memory to MMemory because the memoryy was used as a parameter.
and I think I came another step forward.
The compiler is standing at another place by the end of Font;
       { Draw the text }
       Canvas.Font.Name := Font;
what can I do now ?

and  compiler deliver the folowing message.


Hint: Start of reading config file D:\lazarus\fpc\2.2.2\bin\i386-win32\fpc.cfg
Hint: End of reading config file D:\lazarus\fpc\2.2.2\bin\i386-win32\fpc.cfg
Free Pascal Compiler version 2.2.2 [2008/10/05] for i386
Copyright (c) 1993-2008 by Florian Klaempfl
Target OS: Win32 for i386
Compiling package01.pas
Compiling D:\delphi\consts.pas
Writing Resource String Table file: consts.rst
Compiling MPlayer.pas
D:\Temp\MPlayer.pas(101,15) Warning: An inherited method is hidden by "TMediaPlayer.SetVisible(TButtonSet)"
D:\Temp\MPlayer.pas(283,52) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(434,42) Hint: Parameter "Color" not used
D:\Temp\MPlayer.pas(104,33) Hint: Parameter "YPos" not used
D:\Temp\MPlayer.pas(123,23) Hint: Parameter "Button" not used
D:\Temp\MPlayer.pas(124,27) Hint: Parameter "Button" not used
D:\Temp\MPlayer.pas(111,31) Hint: Parameter "Message" not used
D:\Temp\MPlayer.pas(113,30) Hint: Parameter "Message" not used
D:\Temp\MPlayer.pas(115,31) Hint: Parameter "Message" not used
D:\Temp\MPlayer.pas(149,38) Hint: Parameter "Shift" not used
D:\Temp\MPlayer.pas(859,49) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(909,60) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(954,57) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(989,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1011,57) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1041,58) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1061,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1121,57) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1179,57) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1207,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1251,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1278,60) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1299,60) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1325,57) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1335,47) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1346,49) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1357,49) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1384,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1428,58) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1442,61) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1476,61) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1498,58) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1512,60) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1529,53) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1534,53) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1539,53) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1544,53) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1549,53) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1558,58) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1571,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1582,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1593,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1603,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1613,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1624,59) Hint: Conversion between ordinals and pointers is not portable
D:\Temp\MPlayer.pas(1705,36) Hint: Converting the operands to "Int64" before doing the add could prevent overflow errors.
D:\Temp\MPlayer.pas(1705,36) Hint: Converting the operands to "Int64" before doing the multiply could prevent overflow errors.
D:\Temp\MPlayer.pas(1706,18) Hint: Converting the operands to "Int64" before doing the multiply could prevent overflow errors.
D:\Temp\MPlayer.pas(242,3) Hint: Local const "mci_Back" is not used
Compiling .\sebran\Delphi4\FILEREAD.PAS
D:\Temp\sebran\Delphi4\FILEREAD.PAS(161,3) Note: Local variable "b" not used
D:\Temp\sebran\Delphi4\FILEREAD.PAS(161,6) Note: Local variable "b2" not used
D:\Temp\sebran\Delphi4\FILEREAD.PAS(163,3) Note: Local variable "code" not used
D:\Temp\sebran\Delphi4\FILEREAD.PAS(226,52) Hint: Local variable "TempBufSize" does not seem to be initialized
D:\Temp\sebran\Delphi4\FILEREAD.PAS(237,5) Note: Local variable "i" not used
D:\Temp\sebran\Delphi4\FILEREAD.PAS(238,5) Note: Local variable "NyStr" not used
Compiling .\sebran\Delphi4\GENERELL.PAS
Compiling .\sebran\Delphi4\MESSAGE.PAS
MESSAGE.PAS(41,30) Hint: Parameter "Sender" not used
MESSAGE.PAS(42,30) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\MESSAGE.PAS(32,20) Hint: Unit "windows" not used in Message
D:\Temp\sebran\Delphi4\MESSAGE.PAS(32,30) Hint: Unit "messages" not used in Message
Compiling .\sebran\Delphi4\HMENY.PAS
Compiling .\sebran\Delphi4\HURMAN.PAS
Compiling .\sebran\Delphi4\HMENY.PAS
Compiling .\sebran\Delphi4\MMEMORY.PAS
Compiling .\sebran\Delphi4\HMENY.PAS
Compiling .\sebran\Delphi4\HANGMAN.PAS
Compiling .\sebran\Delphi4\HMENY.PAS
Compiling .\sebran\Delphi4\REGN.PAS
Compiling .\sebran\Delphi4\HMENY.PAS
Compiling .\sebran\Delphi4\ABOUT.PAS
Compiling .\sebran\Delphi4\HMENY.PAS
D:\Temp\sebran\Delphi4\HMENY.PAS(206,34) Warning: unreachable code
HMENY.PAS(89,24) Hint: Parameter "Sender" not used
HMENY.PAS(90,29) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HMENY.PAS(90,46) Hint: Parameter "Button" not used
D:\Temp\sebran\Delphi4\HMENY.PAS(91,7) Hint: Parameter "Shift" not used
HMENY.PAS(92,26) Hint: Parameter "Sender" not used
HMENY.PAS(93,27) Hint: Parameter "Sender" not used
HMENY.PAS(94,28) Hint: Parameter "Sender" not used
HMENY.PAS(101,27) Hint: Parameter "Sender" not used
HMENY.PAS(112,27) Hint: Parameter "Sender" not used
HMENY.PAS(149,28) Hint: Parameter "Sender" not used
HMENY.PAS(150,30) Hint: Parameter "Sender" not used
HMENY.PAS(151,28) Hint: Parameter "Sender" not used
HMENY.PAS(152,29) Hint: Parameter "Sender" not used
HMENY.PAS(154,30) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HMENY.PAS(31,30) Hint: Unit "messages" not used in Hmeny
ABOUT.PAS(60,24) Hint: Parameter "Sender" not used
ABOUT.PAS(61,28) Hint: Parameter "Sender" not used
ABOUT.PAS(62,26) Hint: Parameter "Sender" not used
ABOUT.PAS(64,31) Hint: Parameter "Sender" not used
ABOUT.PAS(66,37) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\ABOUT.PAS(31,30) Hint: Unit "messages" not used in About
D:\Temp\sebran\Delphi4\ABOUT.PAS(79,11) Hint: Unit "Hmeny" not used in About
D:\Temp\sebran\Delphi4\REGN.PAS(117,4) Note: Local variable "X1" not used
D:\Temp\sebran\Delphi4\REGN.PAS(117,7) Note: Local variable "X2" not used
D:\Temp\sebran\Delphi4\REGN.PAS(117,10) Note: Local variable "Y1" not used
D:\Temp\sebran\Delphi4\REGN.PAS(117,13) Note: Local variable "Y2" not used
REGN.PAS(45,26) Hint: Parameter "Sender" not used
REGN.PAS(46,24) Hint: Parameter "Sender" not used
REGN.PAS(47,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\REGN.PAS(188,4) Note: Local variable "Rectt" not used
REGN.PAS(48,27) Hint: Parameter "Sender" not used
REGN.PAS(49,28) Hint: Parameter "Sender" not used
REGN.PAS(50,29) Hint: Parameter "Sender" not used
REGN.PAS(51,25) Hint: Parameter "Sender" not used
REGN.PAS(52,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\REGN.PAS(31,30) Hint: Unit "messages" not used in Regn
D:\Temp\sebran\Delphi4\REGN.PAS(32,46) Hint: Unit "Message" not used in Regn
D:\Temp\sebran\Delphi4\REGN.PAS(32,65) Hint: Unit "MPlayer" not used in Regn
D:\Temp\sebran\Delphi4\REGN.PAS(83,10) Hint: Unit "Hmeny" not used in Regn
HANGMAN.PAS(57,26) Hint: Parameter "Sender" not used
HANGMAN.PAS(58,24) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(200,6) Hint: Local const "Cols" is not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(201,6) Hint: Local const "Rows" is not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(203,4) Note: Local variable "i" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(203,6) Note: Local variable "j" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(204,4) Note: Local variable "X" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(204,6) Note: Local variable "Y" not used
HANGMAN.PAS(59,28) Hint: Parameter "Sender" not used
HANGMAN.PAS(60,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(262,6) Note: Local variable "j" not used
HANGMAN.PAS(61,33) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(61,50) Hint: Parameter "Button" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(62,7) Hint: Parameter "Shift" not used
HANGMAN.PAS(63,29) Hint: Parameter "Sender" not used
HANGMAN.PAS(64,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HANGMAN.PAS(32,20) Hint: Unit "windows" not used in Hangman
D:\Temp\sebran\Delphi4\HANGMAN.PAS(32,30) Hint: Unit "messages" not used in Hangman
D:\Temp\sebran\Delphi4\HANGMAN.PAS(33,56) Hint: Unit "Message" not used in Hangman
D:\Temp\sebran\Delphi4\HANGMAN.PAS(98,10) Hint: Unit "Hmeny" not used in Hangman
MMEMORY.PAS(57,26) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(154,4) Note: Local variable "DX" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(154,7) Note: Local variable "DY" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(263,23) Warning: Function result does not seem to be set
D:\Temp\sebran\Delphi4\MMEMORY.PAS(74,28) Hint: Parameter "X" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(74,30) Hint: Parameter "Y" not used
MMEMORY.PAS(58,24) Hint: Parameter "Sender" not used
MMEMORY.PAS(59,29) Hint: Parameter "Sender" not used
MMEMORY.PAS(60,31) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(60,48) Hint: Parameter "Button" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(61,7) Hint: Parameter "Shift" not used
MMEMORY.PAS(62,28) Hint: Parameter "Sender" not used
MMEMORY.PAS(64,30) Hint: Parameter "Sender" not used
MMEMORY.PAS(65,30) Hint: Parameter "Sender" not used
MMEMORY.PAS(66,30) Hint: Parameter "Sender" not used
MMEMORY.PAS(67,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\MMEMORY.PAS(31,20) Hint: Unit "windows" not used in MMemory
D:\Temp\sebran\Delphi4\MMEMORY.PAS(31,30) Hint: Unit "messages" not used in MMemory
D:\Temp\sebran\Delphi4\MMEMORY.PAS(32,56) Hint: Unit "MPlayer" not used in MMemory
D:\Temp\sebran\Delphi4\MMEMORY.PAS(96,10) Hint: Unit "Hmeny" not used in MMemory
D:\Temp\sebran\Delphi4\HURMAN.PAS(209,50) Hint: Converting the operands to "Int64" before doing the multiply could prevent overflow errors.
D:\Temp\sebran\Delphi4\HURMAN.PAS(186,4) Note: Local variable "r" not used
D:\Temp\sebran\Delphi4\HURMAN.PAS(186,6) Note: Local variable "g" not used
D:\Temp\sebran\Delphi4\HURMAN.PAS(186,8) Note: Local variable "b" not used
D:\Temp\sebran\Delphi4\HURMAN.PAS(381,4) Note: Local variable "i" not used
HURMAN.PAS(56,29) Hint: Parameter "Sender" not used
HURMAN.PAS(57,26) Hint: Parameter "Sender" not used
HURMAN.PAS(62,27) Hint: Parameter "Sender" not used
HURMAN.PAS(63,24) Hint: Parameter "Sender" not used
HURMAN.PAS(64,28) Hint: Parameter "Sender" not used
HURMAN.PAS(65,28) Hint: Parameter "Sender" not used
HURMAN.PAS(66,28) Hint: Parameter "Sender" not used
HURMAN.PAS(67,28) Hint: Parameter "Sender" not used
HURMAN.PAS(68,28) Hint: Parameter "Sender" not used
D:\Temp\sebran\Delphi4\HURMAN.PAS(33,20) Hint: Unit "windows" not used in Hurman
D:\Temp\sebran\Delphi4\HURMAN.PAS(33,30) Hint: Unit "messages" not used in Hurman
D:\Temp\sebran\Delphi4\HURMAN.PAS(34,74) Hint: Unit "MPlayer" not used in Hurman
D:\Temp\sebran\Delphi4\HURMAN.PAS(89,10) Hint: Unit "Hmeny" not used in Hurman
D:\Temp\sebran\Delphi4\GENERELL.PAS(189,28) Warning: Symbol "Handle" is deprecated
D:\Temp\sebran\Delphi4\GENERELL.PAS(191,18) Warning: Symbol "Handle" is deprecated
D:\Temp\sebran\Delphi4\GENERELL.PAS(184,4) Note: Local variable "wtext" not used
D:\Temp\sebran\Delphi4\GENERELL.PAS(235,32) Error: Incompatible type for arg no. 1: Got "TFont", expected "AnsiString"
Hint: Found declaration: TFont.SetName(AnsiString)
D:\Temp\sebran\Delphi4\GENERELL.PAS(243,42) Error: Incompatible type for arg no. 6: Got "TFont", expected "AnsiString"
D:\Temp\sebran\Delphi4\GENERELL.PAS(181,11) Hint: Found declaration: DrawChar(LongInt, LongInt, TImage, AnsiString, LongInt, AnsiString, LongInt)
D:\Temp\sebran\Delphi4\GENERELL.PAS(301,31) Hint: Local variable "strTempSingular" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(302,31) Hint: Local variable "strTempPlural" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(370,31) Hint: Local variable "strTemp" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(426,39) Hint: Local variable "strDummy" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(505) Fatal: There were 2 errors compiling module, stopping





von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #79 on: February 17, 2009, 03:41:16 pm »
I have replaced the Font with AnsiString but it did not help.

The compiler deliver another Error message

D:\Temp\sebran\Delphi4\GENERELL.PAS(241,38) Error: type identifier not allowed here
D:\Temp\sebran\Delphi4\GENERELL.PAS(249,48) Error: type identifier not allowed here
D:\Temp\sebran\Delphi4\GENERELL.PAS(307,31) Hint: Local variable "strTempSingular" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(308,31) Hint: Local variable "strTempPlural" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(376,31) Hint: Local variable "strTemp" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(432,39) Hint: Local variable "strDummy" does not seem to be initialized
D:\Temp\sebran\Delphi4\GENERELL.PAS(511) Fatal: There were 2 errors compiling module, stopping

Vincent Snijders

  • Administrator
  • Hero Member
  • *
  • Posts: 2661
    • My Lazarus wiki user page
Re: convert Sebran delphi(4) code to lazarus
« Reply #80 on: February 17, 2009, 03:50:45 pm »
Sometimes, I wonder if you know what you are doing ...

No idea why it works in Delphi though.

Where is that font variable declared?

try
Code: [Select]
Canvas.Font := Font;

Maybe that compiles (and changes functionality at the same time).

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #81 on: February 17, 2009, 04:05:03 pm »


Font is declaired in
Procedure DrawButton(Im: TImage; Text: String; Col: Longint; Font: String; FSize: Integer; PCent: Integer; BStyle: Integer);

that is very smal routine for drwing charakter

and now the compiler is standing at the end of Font by this line
with the same error message like before.

DrawChar(X, Y, Im, Text, Col, Font, FSize);

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #82 on: February 17, 2009, 04:51:42 pm »


I had a another look and I have seen four procedures
have declaired Font as String
how could it imported to lazarus ?

Procedure DrawCharCenter(X,Y: Longint; Im: TImage; Text: String; Col: Longint; Font: String; FSize: Integer);
Procedure DrawChar(X,Y: Longint;  Im: TImage; Text: String; Col: Longint; Font: String; FSize: Integer);
Procedure DrawButton(Im: TImage; Text: String; Col: Longint; Font: String; FSize: Integer; PCent: Integer; BStyle: Integer);
Function FontSize(Pixels: Integer; Font: String; Canv: TCanvas): integer;

theo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1890

Vincent Snijders

  • Administrator
  • Hero Member
  • *
  • Posts: 2661
    • My Lazarus wiki user page
Re: convert Sebran delphi(4) code to lazarus
« Reply #84 on: February 17, 2009, 07:06:35 pm »
:D

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #85 on: February 17, 2009, 08:05:42 pm »


I just want to modify sebran for my little son using lazarus.
and thought you were also intersted to find out the bugs of lazarus.
I still needs help for workaround .
please help me.


theo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1890
Re: convert Sebran delphi(4) code to lazarus
« Reply #86 on: February 17, 2009, 08:59:29 pm »
Why do you want to port it to Lazarus anyway?

Porting complete Delphi applications with Graphics, Mediaplayer, Databases to Lazarus is not a begginers task.
You need experience from both worlds (Delphi and Lazarus) to do that.

Why not compile it with Delphi?
There are even free versions afaik: http://www.turboexplorer.com/delphi

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #87 on: February 18, 2009, 01:48:31 pm »

tanx a lot for the link,
certainly I will try it with turbodelphi too. But as long as I get help I will go on with porting sebran to lazarus too.

von_ks

  • Jr. Member
  • **
  • Posts: 57
Re: convert Sebran delphi(4) code to lazarus
« Reply #88 on: February 19, 2009, 02:36:38 pm »


I have tried to chand the Variable Font but the compiler does not like it. I have raplaced the name Font in FontN in Procedures and calls and else wehre it was definde as variable but the compiler delivers only few lines and stops very quickly.
like this   DrawChar(X, Y, Im, Text, Col, FontN, FSize);
It seems copmliler of lazarus want see there a Variable String ,
but Font is not recognized as a variable string but as TFont.
Is that normal ?

Hint: Start of reading config file D:\lazarus\fpc\2.2.2\bin\i386-win32\fpc.cfg
Hint: End of reading config file D:\lazarus\fpc\2.2.2\bin\i386-win32\fpc.cfg
Free Pascal Compiler version 2.2.2 [2008/10/05] for i386
Copyright (c) 1993-2008 by Florian Klaempfl
Target OS: Win32 for i386
Compiling package01.pas
package01.pas(11,9) Hint: Unit "Consts" not used in package01
package01.pas(11,18) Hint: Unit "MPlayer" not used in package01
package01.pas(11,28) Hint: Unit "Fileread" not used in package01
package01.pas(11,45) Hint: Unit "Hmeny" not used in package01
package01.pas(11,52) Hint: Unit "About" not used in package01
package01.pas(11,75) Hint: Unit "Regn" not used in package01
package01.pas(12,10) Hint: Unit "Message" not used in package01
22 lines compiled, 0.5 sec
9 hint(s) issued
"Compiling package package01 0.0" beendet
 

Leledumbo

  • Hero Member
  • *****
  • Posts: 8141
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: convert Sebran delphi(4) code to lazarus
« Reply #89 on: February 20, 2009, 05:17:38 am »
Quote
have raplaced the name Font in FontN in Procedures and calls and else wehre it was definde as variable but the compiler delivers only few lines and stops very quickly.
If the compiler messages you post is that "few lines" you mentioned, then the package is compiled. Your porting is done.
Quote
It seems copmliler of lazarus want see there a Variable String ,
but Font is not recognized as a variable string but as TFont.
Is that normal ?
Assuming the class has Font property, it depends on the compiler switch. Delphi allows method parameters to have the same name with class properties, but ObjFPC doesn't. This is to avoid ambiguity in usage, whether to access the parameter or the property. I think in this case Delphi choose the parameter.