Re: cairo pdf
Hendrik Boom <[email protected]>
| Newsgroups | gmane.comp.lang.ocaml.beginners |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Apr 22, 2014 at 08:38:22PM +0200, Christophe Troestler wrote: > On Tue, 22 Apr 2014 13:50:28 -0400, Hendrik Boom wrote: > > > Yes, for a program, I forgot: you need to add -linkpkg (otherwise the > package is only used to compile, not to link). > > > open cairo > > > > at the start of my code, right? > > I would not. Doing so only allows to write “x” instead of “Cairo.x”. > (You do not need to declare a module in OCaml befor eusing it.) > “Cairo” is not that long, so the latter is fine and makes it clearer > what the origin of the function “x” is. If it is too long for you, > use “module C = Cairo”. Then you can write “C.x”. > > > [...] Could something be wrong with get_target? > > No, you need to write “Cairo.get_target”. > > Best, > C. Thanks! It all works beautifully now. -- hendrik