[lazarus] gtk port questions
Mike Z.
mike at msodata.com
Fri Apr 23 03:07:28 EDT 1999
Well, I've started the port and as anticipated I've got some questions.
Please be patient with me - I'm a quick study and learn well by example.
By the time this is done I might even understand what I'm doing...
I'm working under Win32 (my linux box is running an FTP server on a 486-66
and I try to avoid using it for other purposes). Feel free to answer with
brevity, I'll let you know if I'm missing something. Thanks in advance!
1. The h2pas.exe (12/21/98 version) seems to do nothing. I've tried the
syntax: h2pas gtkbbox.h gtkbbox.pp and I'm just returned to the command
prompt. I downloaded h2pas from apparently the original author (6/9/95
version) and it works. Should I be using the version supplied with fpc and
any thoughts on why it doesn't work?
2. Regarding this code snippet from the .pp file:
{$ifndef gtk_include_files}
{$define read_interface}
{$define
read_implementation}
{$endif not gtk_include_files}
{$ifndef
gtk_include_files}
unit gtkbbox;
interface
[snip]
I see these directives in all the units. I'll assume they're necessary but
I'm not clear on when gtk_include_files would be defined.
3. Compiler directives in the C headers are ignored in the pp units. Correct?
4. A C struct is equivalent to a pascal record? The C typedef struct
statements aren't used in pascal?
5. Is there an easy way to determine what needs to be in the Uses clause of
the pp units?
6. These types seem frequently defined:
Type
PLongint = ^Longint;
PByte = ^Byte;
PWord =
^Word;
PINteger = ^Integer;
PCardinal = ^Cardinal;
PReal =
^Real;
PDouble = ^Double;
while PWord isn't used, for example, in gtkbbox.pp. In this case, PWord
doesn't need to be typed, correct? You're just throwing them all in for
convenience?
Thanks again for any tips. Once I get rolling I won't be quite the
irritant :)
Mike Z.
More information about the Lazarus
mailing list