[Lazarus] PascalMagick MagickCommandGenesis

Bernd prof7bit at googlemail.com
Tue Jun 19 00:15:33 CEST 2012

2012/6/18 Felipe Monteiro de Carvalho <felipemonteiro.carvalho at gmail.com>:
> On Mon, Jun 18, 2012 at 9:44 AM, Esmond Bridgeman
> <esmondbridge at gmail.com> wrote:
>> Where can I find a good tutorial or tips on translating C headers? (probably
>> an unhill struggle as I've minimal C experience)
> This page has some info:
> http://wiki.freepascal.org/Creating_bindings_for_C_libraries#Manual_conversion_of_C_headers_to_Pascal
> I like the manual method

the chelper package for Lazarus is quite helpful for
semi-automatically translating one expression at a time. Copy&paste
the C definition into the source editor, place the cursor at the
begining of it and press Ctrl+B. Often the resulting translations
don't even need manual adjustments anymore (and chelper can learn the
type names you want to use). It saves a lot of time. I'm translating
only relatively simple things with it, enums, relatively simple
structs and function declarations and no obscure macros and other deep
black magic C stuff, so for me the chelper is a great help.

More information about the Lazarus mailing list